• PUDN用户
    了解作者
  • C/C++
    开发工具
  • 6KB
    文件大小
  • rar
    文件格式
  • 1
    收藏次数
  • 10 积分
    下载积分
  • 1224
    下载次数
  • 2006-09-12 23:23
    上传日期
画等值线程序源代码,用矩形网格法。用于地质、水文、石油、气象等方面,绘制等高线、等值线。
isoline.rar
  • contour.doc
    38KB
  • www.pudn.com.txt
    218B
内容介绍
<html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta charset="utf-8"> <meta name="generator" content="pdf2htmlEX"> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> <link rel="stylesheet" href="https://static.pudn.com/base/css/base.min.css"> <link rel="stylesheet" href="https://static.pudn.com/base/css/fancy.min.css"> <link rel="stylesheet" href="https://static.pudn.com/prod/directory_preview_static/622b323e81ded46b7f2dad5c/raw.css"> <script src="https://static.pudn.com/base/js/compatibility.min.js"></script> <script src="https://static.pudn.com/base/js/pdf2htmlEX.min.js"></script> <script> try{ pdf2htmlEX.defaultViewer = new pdf2htmlEX.Viewer({}); }catch(e){} </script> <title></title> </head> <body> <div id="sidebar" style="display: none"> <div id="outline"> </div> </div> <div id="pf1" class="pf w0 h0" data-page-no="1"><div class="pc pc1 w0 h0"><img class="bi x0 y0 w1 h1" alt="" src="https://static.pudn.com/prod/directory_preview_static/622b323e81ded46b7f2dad5c/bg1.jpg"><div class="c x0 y1 w2 h2"><div class="t m0 x1 h3 y2 ff1 fs0 fc0 sc0 ls0 ws0">W<span class="_ _0"></span>ell, Thanks t<span class="_ _1"></span>o all you folks who replied, I now have a contour plotting</div><div class="t m0 x1 h3 y3 ff1 fs0 fc0 sc0 ls0 ws0">routine, that does its job fairly well. I\'ve posted this code below<span class="_ _0"></span>. It </div><div class="t m0 x1 h3 y4 ff1 fs0 fc0 sc0 ls0 ws0">is not nearly runnable as other Unix programs go, but you could use it</div><div class="t m0 x1 h3 y5 ff1 fs0 fc0 sc0 ls0 ws0">if you need C code to start off with to do conto<span class="_ _1"></span>ur plotting.</div><div class="t m0 x1 h3 y6 ff1 fs0 fc0 sc0 ls0 ws0">It doesn\'t handle stuff lik<span class="_ _1"></span>e labelling etc. which is somewhat tricky<span class="_ _0"></span>.</div><div class="t m0 x1 h3 y7 ff1 fs0 fc0 sc0 ls0 ws0">Basically almost all of the respondents suggested dividing up the set of </div><div class="t m0 x1 h3 y8 ff1 fs0 fc0 sc0 ls0 ws0">discrete points into a set of triangles and then computing the intersection</div><div class="t m0 x1 h3 y9 ff1 fs0 fc0 sc0 ls0 ws0">of these rectangles with planes representing the contour levels. <span class="_ _1"></span>This way</div><div class="t m0 x1 h3 ya ff1 fs0 fc0 sc0 ls0 ws0">we can process all the levels at once instead of the "crawler" type algorithms</div><div class="t m0 x1 h3 yb ff1 fs0 fc0 sc0 ls0 ws0">which is what I had originally been trying to get to work.</div><div class="t m0 x1 h3 yc ff1 fs0 fc0 sc0 ls0 ws0">T<span class="_ _0"></span>o summarize their ideas: if P1=P[j],P2=P[i+1][j],P3=P[i+1][j+1]</div><div class="t m0 x1 h3 yd ff1 fs0 fc0 sc0 ls0 ws0">and P4=P[j+1] are four points, compute an intermediate point using</div><div class="t m0 x1 h3 ye ff1 fs0 fc0 sc0 ls0 ws0">an interpolation scheme (in the code below<span class="_ _0"></span>, I just use averaging, but</div><div class="t m0 x1 h3 yf ff1 fs0 fc0 sc0 ls0 ws0">one could obviously use fancier schemes). If this point is P<span class="_ _2"></span>, then the</div><div class="t m0 x1 h3 y10 ff1 fs0 fc0 sc0 ls0 ws0">foll. four triangles are used to compute the intersections with</div><div class="t m0 x1 h3 y11 ff1 fs0 fc0 sc0 ls0 ws0">contour levels l_0, .. l_n: P1 P2 P<span class="_ _2"></span>, P2 P3 P<span class="_ _2"></span>, P3 P4 P<span class="_ _2"></span>, P4 P1 P<span class="_ _0"></span>.</div><div class="t m0 x1 h3 y12 ff1 fs0 fc0 sc0 ls0 ws0">The intersection computation is quite trivial. Once these line segments have been</div><div class="t m0 x1 h3 y13 ff1 fs0 fc0 sc0 ls0 ws0">computed you could smooth them in 2d (the code below doesn\'t).</div><div class="t m0 x1 h3 y14 ff1 fs0 fc0 sc0 ls0 ws0">(see Michael <span class="_ _3"></span>Aramini\'s earlier posting for a variation on this that uses </div><div class="t m0 x1 h3 y15 ff1 fs0 fc0 sc0 ls0 ws0">rectangles directly -- He also mentions that you could use the diagonal edges</div><div class="t m0 x1 h3 y16 ff1 fs0 fc0 sc0 ls0 ws0">between two vertices instead of computing another intermediate point, but this</div><div class="t m0 x1 h3 y17 ff1 fs0 fc0 sc0 ls0 ws0">method has problems).</div><div class="t m0 x1 h3 y18 ff1 fs0 fc0 sc0 ls0 ws0">-Sundar</div><div class="t m0 x1 h3 y19 ff1 fs0 fc0 sc0 ls0 ws0">-----Sample Code Follows----------</div><div class="t m0 x1 h3 y1a ff1 fs0 fc0 sc0 ls0 ws0">/*</div><div class="t m0 x1 h3 y1b ff1 fs0 fc0 sc0 ls0 ws0">* If you want try using this, you probably would need to provide</div><div class="t m0 x1 h3 y1c ff1 fs0 fc0 sc0 ls0 ws0">* graph_set_point(), and graph_draw_line(), besides do things like</div><div class="t m0 x1 h3 y1d ff1 fs0 fc0 sc0 ls0 ws0">* initialize window systems and so on.</div><div class="t m0 x1 h3 y1e ff1 fs0 fc0 sc0 ls0 ws0">*</div><div class="t m0 x1 h3 y1f ff1 fs0 fc0 sc0 ls0 ws0">* Please see the code for a note about data format</div><div class="t m0 x1 h3 y20 ff1 fs0 fc0 sc0 ls0 ws0">*/</div><div class="t m0 x1 h3 y21 ff1 fs0 fc0 sc0 ls0 ws0">/* Definitions */</div><div class="t m0 x1 h3 y22 ff1 fs0 fc0 sc0 ls0 ws0">struct _array {</div><div class="t m0 x1 h3 y23 ff1 fs0 fc0 sc0 ls0 ws0"> float *a_elements;</div><div class="t m0 x1 h3 y24 ff1 fs0 fc0 sc0 ls0 ws0"> int a_rows;</div><div class="t m0 x1 h3 y25 ff1 fs0 fc0 sc0 ls0 ws0"> int a_cols;</div><div class="t m0 x1 h3 y26 ff1 fs0 fc0 sc0 ls0 ws0"> float *a_filler;</div></div></div><div class="pi" data-data='{"ctm":[1.611850,0.000000,0.000000,1.611850,0.000000,0.000000]}'></div></div> </body> </html>
评论
  • PUDN用户 2009-08-23 18:56:46
    是啊,没有什么用
相关推荐
  • petrelguide.rar
    petrl 学习资料 石油行业 地质行业 重要可视化软件
  • lcx.rar
    CAD绘图,主要用于石油地质编绘系统图件的绘制
  • 石文软件测井地质专用软件
    用于测井解释、地质分类的常用绘图与分析软件,可为石油工作者提供技术支持。
  • oil-and-gas-viewer:用于查看石油和天然气许可证的 Web 应用程序
    #石油和天然气查看器 用于定位和查看油气井数据的 Web 应用程序。 该数据由 [Arizona Oil and Gas Conservation Commission] ( ) 和 [Arizona Geological Survey] ( ) 提供。 该应用程序允许用户下载井文件夹、...
  • 读写ffA体积格式:用户可以轻松地在Matlab和ffA的SVI Pro / SEA 3D Pro之间移动3D体积数据-matl
    ffA 为石油和天然气行业提供世界领先的 3D 地震分析软件和服务。 ffA 软件从 3D 地震数据中提取地质特征,比传统技术更客观、更快速,以帮助地球科学家和工程师在更短的时间内以更高的信心做出更好的决策。 ffA 的...
  • surfer15破解版(英文界面)
    自1983年问世以来,它就经受住了时间的考验,受全球成千上万的科学家和工程师使用并运用在农业、地球物理、矿业、考古学、岩土工程、录井、施工、地热、石油、教育、能源方面,现推出的surfer15更是新增了3D视图、...
  • 等值线类库
    等值线图广泛应用于石油勘探开发、采矿、地质、地球物理和气象等领域,使表示数字资料的最普通的手段之一。由于它能显示三维空间中曲面的形态,从而就可以表示一个变量在二维空间中的数值变化。 原始的观测数据在二...
  • 夏宇闻著作:从算法设计到硬线逻辑的实现
    如在石油地质调查中,我们通过钻探和一系列的爆破,记录下各种地层的回波数据,然后用计算机对这些数据进行处理,去除噪声等无用信息,最后我们可以得到地层的构造,从而找到埋藏的石油。因为地层不会在几年内有明显...
  • matlab分时代码-GeoModeling_Unconditional_ProGAN:无条件的地理建模相关工作(代码,数据和结
    CUPB:中国石油大学-北京 摘要:长期以来,人们一直在研究地质相模型来预测地下资源。 近年来,生成对抗网络(GAN)已被用作地质相建模的新方法,并取得了令人惊讶的良好结果。 然而,在常规GAN中,所有层都被同时...
  • 微机硫河南鹤壁微机测硫仪煤矿化验室软件通用KZDL-800A
    测硫仪是测量煤中含硫量的主要仪器(石油中硫含量测定选用微库仑法)煤中全硫含量。是评价煤炭质量的重要指标之一,它也是大气污染的主要成份之一。因此煤炭生产部门和化肥、发电、民用、炼焦和建材等用煤部门都十分...