Sophie

Sophie

distrib > Fedora > 14 > x86_64 > by-pkgid > 5035839f674c88dea1f7928a86fbdc64 > files > 687

geos-devel-3.2.1-3.fc14.x86_64.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>GEOS: geos::algorithm::distance::DiscreteHausdorffDistance Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.7.1 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
      <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
    </ul>
  </div>
  <div class="navpath">
    <ul>
      <li><a class="el" href="namespacegeos.html">geos</a>      </li>
      <li><a class="el" href="namespacegeos_1_1algorithm.html">algorithm</a>      </li>
      <li><b>distance</b>      </li>
      <li><a class="el" href="classgeos_1_1algorithm_1_1distance_1_1DiscreteHausdorffDistance.html">geos::algorithm::distance::DiscreteHausdorffDistance</a>      </li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-static-methods">Static Public Member Functions</a>  </div>
  <div class="headertitle">
<h1>geos::algorithm::distance::DiscreteHausdorffDistance Class Reference</h1>  </div>
</div>
<div class="contents">
<!-- doxytag: class="geos::algorithm::distance::DiscreteHausdorffDistance" -->
<p>An algorithm for computing a distance metric which is an approximation to the Hausdorff Distance based on a discretization of the input <a class="el" href="">Geometry</a>.  
<a href="#_details">More...</a></p>

<p><code>#include &lt;<a class="el" href="DiscreteHausdorffDistance_8h_source.html">DiscreteHausdorffDistance.h</a>&gt;</code></p>

<p><a href="classgeos_1_1algorithm_1_1distance_1_1DiscreteHausdorffDistance-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a13a23b057f76d947b93e81916f2fd72a"></a><!-- doxytag: member="geos::algorithm::distance::DiscreteHausdorffDistance::DiscreteHausdorffDistance" ref="a13a23b057f76d947b93e81916f2fd72a" args="(const geom::Geometry &amp;g0, const geom::Geometry &amp;g1)" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><b>DiscreteHausdorffDistance</b> (const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &amp;g0, const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &amp;g1)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1algorithm_1_1distance_1_1DiscreteHausdorffDistance.html#a83c84f436933402aae360a3115336416">setDensifyFraction</a> (double dFrac)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a7089843f2a6cdcf015509b4dba1d8d42"></a><!-- doxytag: member="geos::algorithm::distance::DiscreteHausdorffDistance::distance" ref="a7089843f2a6cdcf015509b4dba1d8d42" args="()" -->
double&nbsp;</td><td class="memItemRight" valign="bottom"><b>distance</b> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a520ffe124732bb78c7fcf53f8a837bd4"></a><!-- doxytag: member="geos::algorithm::distance::DiscreteHausdorffDistance::orientedDistance" ref="a520ffe124732bb78c7fcf53f8a837bd4" args="()" -->
double&nbsp;</td><td class="memItemRight" valign="bottom"><b>orientedDistance</b> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="afec7e38c698b94e4716c078e69bb5a9e"></a><!-- doxytag: member="geos::algorithm::distance::DiscreteHausdorffDistance::getCoordinates" ref="afec7e38c698b94e4716c078e69bb5a9e" args="() const " -->
const std::vector<br class="typebreak"/>
&lt; <a class="el" href="classgeos_1_1geom_1_1Coordinate.html">geom::Coordinate</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><b>getCoordinates</b> () const </td></tr>
<tr><td colspan="2"><h2><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="abfe80c59bd22ce6617af00c37be98348"></a><!-- doxytag: member="geos::algorithm::distance::DiscreteHausdorffDistance::distance" ref="abfe80c59bd22ce6617af00c37be98348" args="(const geom::Geometry &amp;g0, const geom::Geometry &amp;g1)" -->
static double&nbsp;</td><td class="memItemRight" valign="bottom"><b>distance</b> (const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &amp;g0, const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &amp;g1)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aebc8cecc70327b0c19e75c87a64be699"></a><!-- doxytag: member="geos::algorithm::distance::DiscreteHausdorffDistance::distance" ref="aebc8cecc70327b0c19e75c87a64be699" args="(const geom::Geometry &amp;g0, const geom::Geometry &amp;g1, double densifyFrac)" -->
static double&nbsp;</td><td class="memItemRight" valign="bottom"><b>distance</b> (const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &amp;g0, const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &amp;g1, double densifyFrac)</td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<p>An algorithm for computing a distance metric which is an approximation to the Hausdorff Distance based on a discretization of the input <a class="el" href="">Geometry</a>. </p>
<p>The algorithm computes the Hausdorff distance restricted to discrete points for one of the geometries. The points can be either the vertices of the geometries (the default), or the geometries with line segments densified by a given fraction. Also determines two points of the Geometries which are separated by the computed distance.</p>
<p>This algorithm is an approximation to the standard Hausdorff distance. Specifically, </p>
<pre>
    for all geometries a, b:    DHD(a, b) &lt;= HD(a, b)
 </pre><p> The approximation can be made as close as needed by densifying the input geometries. In the limit, this value will approach the true Hausdorff distance: </p>
<pre>
    DHD(A, B, densifyFactor) -&gt; HD(A, B) as densifyFactor -&gt; 0.0
 </pre><p> The default approximation is exact or close enough for a large subset of useful cases. Examples of these are:</p>
<ul>
<li>computing distance between Linestrings that are roughly parallel to each other, and roughly equal in length. This occurs in matching linear networks.</li>
<li>Testing similarity of geometries.</li>
</ul>
<p>An example where the default approximation is not close is: </p>
<pre>
   A = LINESTRING (0 0, 100 0, 10 100, 10 100)
   B = LINESTRING (0 100, 0 10, 80 10)</pre><pre>   DHD(A, B) = 22.360679774997898
   HD(A, B) ~= 47.8
 </pre> <hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a83c84f436933402aae360a3115336416"></a><!-- doxytag: member="geos::algorithm::distance::DiscreteHausdorffDistance::setDensifyFraction" ref="a83c84f436933402aae360a3115336416" args="(double dFrac)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void geos::algorithm::distance::DiscreteHausdorffDistance::setDensifyFraction </td>
          <td>(</td>
          <td class="paramtype">double&nbsp;</td>
          <td class="paramname"> <em>dFrac</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Sets the fraction by which to densify each segment. Each segment will be (virtually) split into a number of equal-length subsegments, whose fraction of the total length is closest to the given fraction.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dFrac</em>&nbsp;</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="DiscreteHausdorffDistance_8h_source.html">DiscreteHausdorffDistance.h</a></li>
</ul>
</div>
<hr class="footer"/><address class="footer"><small>Generated on Thu Jul 22 2010 for GEOS by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.1 </small></address>
</body>
</html>