"Fossies" - the Fresh Open Source Software Archive

Member "sip-0.12.1/help/en_US/arclength.xml" (22 Feb 2012, 3068 Bytes) of package /linux/privat/sip-0.12.1.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) XML source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 <?xml version="1.0" encoding="ISO-8859-1"?>
    2 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="en" xml:id="arclength">
    3 <info>
    4   <pubdate>February 2012</pubdate>
    5 </info>
    6 
    7 <refnamediv>
    8   <refname>arclength</refname>
    9   <refpurpose>Arc length function of a sampled curve</refpurpose>
   10 </refnamediv>
   11    
   12    
   13    
   14    <refsynopsisdiv><title>Calling Sequence</title>
   15     <synopsis>s = arclength(crv)</synopsis>
   16     <synopsis>s = arclength(crv, circular)</synopsis>
   17    </refsynopsisdiv>
   18    
   19    <refsection><title>Parameters</title>
   20    
   21       <variablelist>
   22       
   23          <varlistentry>
   24             <term>crv</term>
   25             <listitem>
   26                 nx2 curve vector [x y]
   27             </listitem>
   28          </varlistentry>
   29       
   30          <varlistentry>
   31             <term>circular</term>
   32             <listitem>
   33               boolean, %t if curve is to be treated as circular. Defaults to %f. 
   34             </listitem>
   35          </varlistentry>
   36 
   37          <varlistentry>
   38             <term>s</term>
   39             <listitem>
   40             vector containing the estimated arclength at each sample point
   41             x(i),y(i) from x(0),y(0). Thus s(1) == 0.
   42             </listitem>
   43          </varlistentry>
   44    
   45       </variablelist>
   46    
   47    </refsection>
   48    
   49    <refsection><title>Description</title>
   50    
   51       <para>
   52       This function computes the numerical arclength at each sample of a curve, as
   53       measured from the first sample. The method implicitly interpolates the
   54       curve using line segments between each sample.
   55       </para>
   56    
   57    </refsection>
   58    
   59    <refsection><title>Examples</title><programlisting role="example"><![CDATA[
   60        initial_dir = PWD;
   61        chdir (SIPDIR + 'images');
   62 
   63        Img = imread('star.bmp');
   64        clf
   65        imshow(Img,2);
   66 
   67        [x,y] = follow(Img);
   68 
   69        s = arclength([x y], %t);
   70 
   71        // plot arc length vs sample id to get an idea of the difference
   72        clf;
   73        plot(s);
   74        a = gca();
   75        a.isoview = 'on';
   76 
   77        // the last element should equal the perimeter
   78        s($), perim(Img)
   79 
   80        chdir(initial_dir);
   81    ]]></programlisting></refsection>
   82    
   83    <refsection><title>Authors</title><simplelist type="vert">
   84       
   85       <member> Ricardo Fabbri &lt;ricardofabbri (AT) users DOT sf DOT net&gt; </member>
   86    
   87    </simplelist></refsection>
   88 
   89 
   90    <refsection><title>Availability</title>
   91 The latest version of the Scilab Image Processing toolbox can be found at
   92 <para>
   93          http://siptoolbox.sourceforge.net
   94       </para>
   95 
   96    </refsection>
   97 
   98    
   99    <refsection><title>See Also</title><simplelist type="inline">
  100       
  101       <member> 
  102          <link linkend="follow">follow</link> 
  103       </member>
  104 
  105       <member> 
  106          <link linkend="perim">im2bw</link> 
  107       </member>
  108       
  109       <member> 
  110          <link linkend="edge">edge</link> 
  111       </member>
  112    </simplelist></refsection>
  113 
  114 </refentry>