科学网

 找回密码
  注册

tag 标签: Grid

相关帖子

版块 作者 回复/查看 最后发表

没有相关内容

相关日志

修改MatLab子图的Grid
DanYangpeng 2020-6-26 10:54
MatLab中已经绘好包含若干个子图的figure,如果要调整每个子图的Grid,可以尝试这样做: figure(1),h1=get(gcf); %获得当前figure的句柄 set(h1.Children(8),'XGrid','on', YGrid','on' ); %假设有4个子图,这里是打开('on',关闭'off')第1个(左上角)子图的网格 set(h1.Children(6),'XGrid','on', YGrid','on' ); %打开第3个(左下角)子图的网格 set(h1.Children(4),'XGrid','on', YGrid','on' ); % 打开第2个(右上角)子图的网格 set(h1.Children(2),'XGrid','on', YGrid','on' ); % 打开第4个(右下角)子图的网格
个人分类: MatLab|2054 次阅读|0 个评论
格子乘法、Napier grid、熙圆指算
热度 1 lytlsnwy 2017-12-2 00:22
格子乘法、Napier grid 与熙圆指算 摘要:格子乘法原名叫 lattice multiplication、 是印度人十二世纪发明、阿拉伯首先加以传播的,十三世纪初由意大利数学家斐波那契将它与阿拉伯数字一起传入欧洲但未得到普及,十七世纪才被爱丁堡数学家以纳皮尔以Napier grid 发表并在西方被普遍接受。在美国因熙圆指型研究而遇到 Napier grid 这个名字被我们关注。同意百度将其叫做格子乘法的名字。 先摘一段维基上的陈述: Historically the grid calculation tweaked slightly was the basis of a method called lattice multiplication,which was the standard method of multiple-digit multiplication developed inmedieval Arabic and Hindu mathematics. Lattice multiplication was introducedinto Europe by Fibonacci at the start of thethirteenth century along with the so-called Arabic numerals themselves;although, like the numerals also, the ways he suggested to calculate with themwere initially slow to catch on. Napier's bones were a calculating helpintroduced by the Scot John Napier in 1617 to assist lattice methodcalculations. Napier grid 其实就是 lattice multiplication。该 方法应该是意大利数学家 斐波那契 十三世纪初 (1202) 引进阿拉伯 - 印度发明的数字符号时同时引进欧州的,但均未被欧洲普遍认知和接受。十七世界初,苏格兰愛丁堡数学家约翰 纳皮尔 (1550~1617) 臨死前 介绍的这个方法如今还是英国和苏格兰学校的 (照片引自维基) 标准方法 ( 可搜索百度 Napier grid)。 以下叙述,是我自己的理解和学习它的总结。我的做法省地方,全部例子和照片都出自本人。 优点 :整齐,简便,只要会一位数乘法(九九表),行列对齐了,把结果写进去,再会 加法,按斜线把和数写下来。 它的格式以行与列为准,条理分明,便于捡查;错在那位数,一看便知,所以不容易出错。尤其在位数较大时,它反而省地方:全部计算都在以被乘数 数位+2 为宽度、乘数位数+2为高度所决定的那个方块里面。 具体方法与步骤 : 1 ,被乘数由左向右写在顶部,每数占一格,乘数写在右侧,从上往下每数占一格,小数点不占格子,仅在两格之间的线上点一下。 2 ,每个格子右上角与左下角之间划一条对角线,各个格子的对角线互相连接着。 3 ,被乘数与乘数的各位之数相乘。不必考虑什么位,只管每个位上的一位数。也可不限先后,乘积 肯定 不会超过 81, 写进它们所在行与列对应的格子里,乘积若有十位数则写在格子斜线上方,乘积的个位数写在斜线下方 , 注意每个格子都必须都填上,没有填上肯定是遗漏了!写完后,仔细检查一遍。 4 ,从右下方开始,自右向左、自下而上地将同一条斜线下 / 上的数加起来。注意,都是一位数相加。不会心算的请用一双熙圆手计算或者帮助记住临时结果,将最后结果写在格子的下方或左侧,和数大于十的进位给左侧或上方,可以在左上那个位值上用点或数记一下。 5 ,最终答案是从左侧最上开始往下读到底部,然后续往右读到最右边。若有小数点,将被乘数小数点与乘数的小数点按行列的线到相交处,確定交叉点后再后沿着斜线走到底,那里就是答案的小数点。 先举个二位数乘法的例来说明: 74*69=5106 再举两个六位数的乘积,其结果是十二位数: 789654*425815=406246518010 这在计算器上,只能给出这样的结果: 计算器显然已经不管用了,我们再举一个可以用计算器验证的例子: 389*976548=379877172 再举个带小数点的题目: 98765.4*32.1=3170369.34 这个计算器也可以算出来。 只要结果超过十位,手机里的计算器就不管用了。请看下面这个带小数点的,真不如自巳算: 9 876.5*43210.6=426769490.90 而计算器则把 .90 给进位了。不如手算可靠。 我感觉,这个格子乘法(可参见百度),我们也别把纳皮尔这个名字加像美国人那样加在在前面了,因为发明人不是他。但是这个方法确实很好玩。 它把任何位数的乘法全部化简为一位数的乘法和加法。什么叫简约?这就是简约。 事实上,这比计算器可靠。而一位数的计算则最最重要。把这个搞熟练了,根本不要惧怕它。这个格子乘法对于克服对多位数的畏惧很有效。 由于熙圆手(Xi-Yuan hand)对于一位数计算全面有效,所以与它配套教孩子挺进多位数计算毫无困难。  ̄ LYT 20171130 于哈德森 li-yt@126.com
个人分类: 熙圆指型|11676 次阅读|2 个评论
Matlab: Conversion from GeoTiff Format to Arc/Info Grid
lixujeremy 2015-10-21 16:37
Summary 我在之前的帖子已经讨论过 Arc/Info Grid 或 IDRISI Grid 转换为 GeoTiff 格式文件的方法。此处,本帖讨论 Geotiff 文件转换为 Arc/Info Grid 文件的代码。 这里的方法只考虑到了像元经向、纬向空间分辨率一致的情况,对于这二者不一致的情况还没有做讨论,留待以后再考虑。 这一方法可以适用于任意投影的 Geotiff 文件。 GeoTiff2ArcGrid.rar References Matlab: Converison from Arc/Info Grid to GeoTiff Format . Matlab: Converison from IDRISI Grid to GeoTiff Format .
个人分类: Matlab|2640 次阅读|0 个评论
[转载]新发现-大脑负责GPS的网格细胞-全球定位系统
LongLeeLu 2013-4-30 08:37
新发现,大脑的网格细胞,负责GPS - 全球定位系统。 Note that this information is purely for education purpose. as the link may be shifted later, the full article, well written, is supplemented for my own convenience for study, for the completion of my own record of literature library. Some interesting stuff: He was researching physiology and they were interested in the intersection of behavior and physiology. But, she said, they wouldn’t take no for an answer. “We sat there for hours. He really couldn’t get us out of his office,” Dr. May-Britt Moser said. “Both of us come from nonacademic families and nonacademic places,” Edvard said. “The places where we grew up, there was no one with any university education, no one to ask. There was no recipe on how to do these things.” “And how to act politely,” May-Britt interjected. “It was just a way to get to the point where we wanted to be. But seen now, when I know the way people normally do it,” he said, smiling at the memory of his younger self, “I’m quite impressed.” PROFILES IN SCIENCEA Sense of Where You Are Brian Cliff Olguin for The New York Times May-Britt Moser with Thelma, one of the lab rats used in the research she and her husband, Edvard I. Moser, are conducting. By JAMES GORMAN Published: April 29, 2013 FACEBOOK TWITTER GOOGLE+ SAVE E-MAIL SHARE PRINT SINGLE PAGE REPRINTS TRONDHEIM, Norway — In 1988, two determined psychology students sat in the office of an internationally renowned neuroscientist in Oslo and explained to him why they had to study with him. Science Times Podcast Two Norwegian scientists on what a rat brain knows about location; new research into how some traveling primates take digestive cues from their hosts; demystifying talk of a cure for H.I.V./AIDS. 9:42 Your Brain’s GPS play max volume 9:41 6:31 Eating Like a Local (Monkey) play max volume 6:30 9:09 Weakness in AIDS’s Armor play max volume 9:08 Related Grid Cells: ‘Crystals of the Brain’ (April 30, 2013) Connect With Us on Social Media @nytimesscience on Twitter. Science Reporters and Editors on Twitter Like the science desk on Facebook. Enlarge This Image Unfortunately, the researcher, Per Oskar Andersen, was hesitant, May-Britt Moser said as she and her husband, Edvard I. Moser, now themselves internationally recognized neuroscientists , recalled the conversation recently. He was researching physiology and they were interested in the intersection of behavior and physiology. But, she said, they wouldn’t take no for an answer. “We sat there for hours. He really couldn’t get us out of his office,” Dr. May-Britt Moser said. “Both of us come from nonacademic families and nonacademic places,” Edvard said. “The places where we grew up, there was no one with any university education, no one to ask. There was no recipe on how to do these things.” “And how to act politely,” May-Britt interjected. “It was just a way to get to the point where we wanted to be. But seen now, when I know the way people normally do it,” he said, smiling at the memory of his younger self, “I’m quite impressed.” So, apparently, was Dr. Andersen. In the end, he yielded to the Mosers’ combination of furious curiosity and unwavering determination and took them on as graduate students. They have impressed more than a few people since. In 2005, they and their colleagues reported the discovery of cells in rats’ brains that function as a kind of built-in navigation system that is at the very heart of how animals know where they are, where they are going and where they have been. They called them grid cells. “I admire their work tremendously,” said Eric Kandel , the Nobel laureate neuroscientist who heads the Kavli Institute for Brain Science at Columbia and who has followed the Mosers’ careers since they were graduate students. John O’Keefe of University College London, whose discovery in the 1970s of so-called place cells in the brain that register specific places, like the corner deli or grandma’s house, and who was one of the Mosers’ mentors, said that the discovery of the grid cells was “incredibly significant.” The workings of the grid cells show that in the brain “you are constantly creating a map of the outside world,” said Cori Bargmann , of Rockefeller University, who is one of the two leaders of a committee set up to plan the National Institutes of Health’s contribution to President Obama’s recently announced neuroscience initiative. Often, the workings of billions of neurons that produce our thoughts are opaque. But electrical recordings of signals emitted by grid cells show a map “with a framework and coordinates that are completely intuitive,” Dr. Bargmann said. And to find such a straightforward system is, in its own way, “just mind-boggling.” What is the brain doing being so mysteriously unmysterious? The implications of the discovery are both practical and profound. The cells have been proved to exist in primates, and scientists think they will be found in all mammals, including humans. The area in the brain that contains the grid cell navigation system is often damaged early in Alzheimer’s disease , and one of the frequent early symptoms of Alzheimer’s patients is that they get lost. The Mosers do not work on humans, but any clues to understanding how memory and cognitive ability are lost are important. On the most profound level, Dr. O’Keefe, the Mosers and others speculate that the way the brain records and remembers movement in space may be the basis of all memory. This idea resonates with the memory palaces of the Renaissance, imagined buildings that used spatial cues as memory aids. The technique dates to the ancient Greeks . In this regard, neuroscience may be catching up with intuition. A Welcome Ambush Edvard, 51, and May-Britt Moser, 50, now direct the Kavli Institute for Systems Neuroscience and the Centre for the Biology of Memory at the Norwegian University of Science and Technology here in Trondheim. They have a steady stream of findings coming from their lab, and a slew of awards, the latest of which, the Perl-U.N.C. Neuroscience Prize , they received April 16 at the University of North Carolina. But they did not grow up in a center of academic ferment or intellectual competition. They were born and raised on islands off the coast of Norway a couple of hundred miles north of Bergen, part of an area known as Norway’s Bible Belt. They went to the same high school, but didn’t really get to know each other until they met again at the University of Oslo in the 1980s. May-Britt, who grew up on a farm, remembers an environment in which drinking, card playing and dancing were all frowned upon. When she called home from Oslo announcing that she had been to a bar and had her first beer, her mother said, “And what’s next?” The Mosers married in 1985 while still undergraduates. By the time they had finished their doctorates, in 1995, they had two daughters, but they were ready to see the world, to train in laboratories outside Norway. And they did spend time in England, with Dr. O’Keefe, and in Scotland, with Richard Morris at the University of Edinburgh. But the Mosers’ travels were cut short when they were ambushed by a job offer too good to refuse, from the university in Trondheim, where they have been ever since. http://www.nytimes.com/2013/04/30/science/may-britt-and-edvard-moser-explore-the-brains-gps.html?hpw_r=0 1 2 NEXT PAGE » A version of this article appeared in print on April 30, 2013, on page D 1 of the New York edition with the headline: A Sense of Where You Are .
个人分类: Science Discovery|2927 次阅读|0 个评论
谈谈gnuplot(十三):栅格以及方程数值解估算
yusufma 2011-10-26 03:18
我们现在来画一个 0 阶贝塞尔函数 J 0 (x) : gnuplot set term wxt enhanced gnuplot set xlabel "X" gnuplot set ylabel "Y" gnuplot set xrange gnuplot set xtics 0,1,10 gnuplot unset key gnuplot set title "0阶贝塞尔函数 J_0(x)" gnuplot plot besj0(x) 这里的 besj0(x) 就是 gnuplot 里面预定义的 0 阶贝塞尔函数。如果现在请您从这个图上估计出 内 J 0 (x) 的零点数值,也就是方程 J 0 (x)=0 的解,恐怕您很难说的准确。但是如果为这个图加上栅格( grid ),就容易多了: gnuplot set grid gnuplot replot 这时我们很容易估计出三个零点的数值: 2.4, 5.5, 8.6 。通过查表我们可以知道,这三个零点比较精确的数值分别为 2.4048, 5.5201, 8.6537 。这和我们的估计值差不太多。如果我们想更精确的估计数值,可以尝试改一下 xrange : gnuplot set xrange gnuplot set xtics 8,0.1,9 gnuplot replot 这相当于把图像在零点附近放大了。把鼠标放在画图区域,画图框左下角就会显示出鼠标所在位置的坐标。现在我们把鼠标放在函数图线和 X 轴的交叉点上,左下角显示的横坐标为 8.65243 ,这和我们查表所得的数值更接近了。 如果想进一步让结果精确一些,我们可以利用 gnuplot 的计算功能。我们可以通过尝试计算的方法获得方程的数值解: gnuplot print besj0(8.65) 0.00101216621937318 gnuplot print besj0(8.66) -0.0017019446057587 gnuplot print besj0(8.6537) 7.5770361108123e-06 gnuplot print besj0(8.6536) 3.47225104115535e-05 gnuplot print besj0(8.6538) -1.95681245811775e-05 所以在 8.6 附近, J 0 (x)=0 精确到小数点后 4 位的数值解为 8.6537 ,这和我们查表的结果一模一样。由于我们已经通过图像知道了数值解的大概位置,再加上合理利用线性插值,我们可以很快得到精确的结果。
个人分类: 开源软件|6952 次阅读|0 个评论
seminar 6 朱玉萍硕士
热度 1 gaobaozhong 2011-6-11 11:17
朱玉萍10硕士讲了最近读的两篇文章,一篇是刑长明07级博士写的教育资源网格的文章,另一篇是介绍Dobject系统的文章,一个p2p结合云实现的动态查询系统。 教育资源网格模型及副本创建策略 存在问题: 1. 目前,各地中小学都建立了自己的校园网络,并开发了大量的资源,包括教学案例,教学课件和教学视频等等,资源分布广泛,应用面普及,但存在的一个问题是这些资源都形成了一个个的信息孤岛,不同的学校之间很难实现共享,造成了资源的极大浪费,为了使现有资源得以充分利用,避免盲目的重复开发,利用网格技术共享资源是迫切需要解决的问题。 2. 在网格系统中,创建副本是提高系统的服务质量的有效手段。目前对副本创建策略的研究主要集中在以欧洲数据网格为代表的网格系统环境中,但在欧洲数据网格副本创建策略中没有考虑到节点的存储能力,当节点存储能力较小时,容易引起副本的频繁置换,造成较大的用户延迟。 主要工作: 1. 依据我们教育部门现行的资源组织模式(国家,省,市,县),提出层次式的教育资源网格模型,使节点依据其所属的层次来管理其辖域内的资源。 2. 针对教育资源网格的特点,分析了影响副本创建策略的关键因素。 ① 节点间的网络带宽 ② 文件大小 ③ 用户的访问模式 ④ 节点的存储能力 3. 基于层次式的教育资源网格模型引入网络带宽和文件大小两个参数,提出了 EDRS (包括 MEDRS 和 AEDRS )。 MEDRS 中的数学模型: 定义一:当用户对数据文件发出访问请求时,副本机制从该数据文件的多个副本中为用户选择一个响应时间最短的副本 BestFile 。 定义二:删除副本 PFN 的代价 PFN.cost 。 PFN.cost=PFN.size × PFN. freguency/bandwidth(site l,site2). 其中, bandwidth(site l,site2) 为节点 site1 和 site2 间传输线路的最小带宽。 定义三:新建 LFN 副本的收益 LFN.reward 。 LFN.reward=LFN.size × LFN.frequency/bandwidth(sitel,site2). 4. 利用数据网格模拟工具 OptorSim 构建教育资源网格虚拟环境进行仿真实验。 改进: 进一步完善数学模型,比如说可以增加权值来衡量 size,frequency 和 bandwidth 哪个更重要。 Dynamic Query Processing for P2P Data Services in the Cloud 1. 初步了解了云计算的三种服务模式: ① IS(EC2) ② PS(Google App Engine) ③ SS ( GMail by Google ) 2. 初步了解了最近的软件架构,如 map-reduce-merge 和 Hadoop ,支持在计算机集群中的大数据集上进行分布式的计算,也可启用云计算服务。 3. 初步了解了 DObjects 的当前实现是建立在一个资源共享平台 H 2 O 基础之上。 4. 查询迁移中的数学模型: 其中, DS 是要迁移的必要数据的大小(使用来自数据源的统计估计), bandwidthi , j 和 latencyi , j ,是节点 i 和节点 j 之间的网络带宽和延迟。 Loadj 是节点 j 的当前负载值。 是通信成本和计算成本之间的一个权重因子。考虑到它们之间潜在的巨大差异,这两个成本术语的值规范在 0 和 1 之间。
个人分类: seminar|1554 次阅读|1 个评论
hadoop在电力系统中的初步应用及其前景
qhhuangscut 2010-6-4 21:26
随着世界各主要国家在努力推动智能电网的发展,越来越多风电、太阳能等可再生能源接入电网,智能电表经历了试验阶段,已经在部分地区大规模装设,同时各电网公司都不同程度地增加PMU等监测设备以实现对电网更好的监控。在此背景下,大规模数据的实时分析和处理在电力系统运行中将成为新的趋势及一个需要解决的问题。但由于国内在智能电表、PMU装设规模还有限,对实时数据的重视程度及利用还十分不足(未实行(近)实时电价及新能源接入量较小也是其中的影响因素),大规模数据的处理的难题视乎在国内如此大规模的电网中“不存在”(至少鲜有提及)。从另一方面也反映了国内量测工作还没足够重视,监测点、更新时间间隔和实时数据量在电力调度部门现有的硬件下仍能“满足”,而PMU及WAMS系统应用有待进一步发展。 对比,美国一家服务九百万用户的TVA就已经装了几百个PMU,处理数据量达20TB。考虑未来的智能电网的发展,该公司将会有更多的PMU,数据规模将达PB级别,而同时对数据分析的要求将更高,现有的数据库显然难以应付,而扩展将带来巨大开销。此外,NERC作为统筹多个区域电网的安全稳定的机构,计划各区PMU数据汇集到统一协调机构已实现整体评估,避免数据不共享造成的评估难题。在如此背景下,适合大规模、分布式数据处理的Hadoop突围而出,可实现利用最普通的计算机构建庞大的分布式式数据库。TVA在其基础上开发了superPDC,最近并通过openPDC项目将其开源,此工作将有利于推到量测数据的大规模分析处理,同时将为电网其他时序数据的处理提共通用的平台。目前该项目已经得到美国多家电力公司的肯定并开展实施。本人也十分看好其前景,只是此类新技术难被国内电力系统采用,确实是一个长期存在的不争事实(从我看看,实际是需要这样的技术和平台)。考虑数据处理的必要性及必然性(PMU及WAMS进一步推广),从科研角度来看,如何结合国内情况,利用Hadoop是一个值得研究的小课题,未来的云计算及相关技术在电力系统应用则是大课题。 相关链接如下: Open-source Hadoop powers Tennessee smart grid http://news.cnet.com/8301-13846_3-10393259-62.html openPDC http://openpdc.codeplex.com/ 欢迎各位前辈、老师、同学讨论。如有错误,请指出。
个人分类: 科研天地|6629 次阅读|1 个评论
Grid computing of spatial statistics:using the TeraGrid for Gi*(d) analysis
guodanhuai 2010-3-24 15:56
Wang, S., M. K. Cowles, et al. (2008). Grid computing of spatial statistics: using the TeraGrid forGi* analysis. Concurrency and Computation: Practice and Experience 20(14): 1697-1720. The massive quantities of geographic information that are collected by modern sensing technologies are difficult to use and understand without data reduction methods that summarize distributions and report salient trends. Statistical analyses, therefore, are increasingly being used to analyze large geographic data sets over a broad spectrum of spatial and temporal scales. Computational Grids coordinate the use of distributed computational resources to form a large virtual supercomputer that can be applied to solve computationally intensive problems in science, engineering, and commerce. This paper presents a solution to computing a spatial statistic, Gi*(d) using Grids. Our approach is based on a quadtree-based domain decomposition that uses task-scheduling algorithms based on GridShell and Condor. Computational experiments carried out on the TeraGrid were designed to evaluate the performance of solution processes. The Grid-based approach to computing values for Gi*(d) shows improved performance over the sequential algorithm while also solving larger problem sizes. The solution demonstrated not only advances knowledge about the application of the Grid in spatial statistics applications but also provides insights into the design of Grid middleware for other computationally intensive applications. Copyright 2008 John Wiley Sons, Ltd.
个人分类: GIsystem & GIscience|3838 次阅读|0 个评论

Archiver|手机版|科学网 ( 京ICP备07017567号-12 )

GMT+8, 2024-5-23 21:25

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部