<!-- Converted to DocBook/SGML by Kevin Conder -->
<refentry id="GEN16">
  <refmeta>
    <refentrytitle>GEN16</refentrytitle>
  </refmeta>
 
  <refnamediv>
    <refname>GEN16</refname>
    <refpurpose>
      Creates a table from a starting value to an ending value.
      <indexterm id="IndexGEN16"><primary>GEN16</primary></indexterm>
    </refpurpose>
  </refnamediv>
 
  <refsect1>
    <title>Description</title>
    <para>
      Creates a table from <emphasis>beg</emphasis> value to <emphasis>end</emphasis> value of <emphasis>dur</emphasis> steps.
    </para>
  </refsect1>
 
  <refsect1>
    <title>Syntax</title>
    <synopsis><command>f</command> # time size 16 beg dur type end</synopsis>
  </refsect1>
 
  <refsect1>
    <title>Initialization</title>
    <para>
      <emphasis>size</emphasis> -- number of points in the table. Must be a power of 2 or a power-of-2 plus 1 (see <link linkend="f"><citetitle>f statement</citetitle></link>). The normal value is power-of-2 plus 1.
    </para>

    <para>
      <emphasis>beg</emphasis> -- starting value
    </para>

    <para>
      <emphasis>dur</emphasis> -- number of segments
    </para>

    <para>
      <emphasis>type</emphasis> -- if 0, a straight line is produced. If non-zero, then <emphasis>GEN16</emphasis> creates the following curve, for <emphasis>dur</emphasis> steps:
      <literallayout>
beg + (end - beg) * (1 - exp( i*type/(dur-1) )) / (1 - exp(type))
      </literallayout>
    </para>

    <para>
      <emphasis>end</emphasis> -- value after <emphasis>dur</emphasis> segments
    </para>

    <note>
      <title>Note</title>
      <para>
        If <emphasis>type</emphasis> &gt; 0, there is a slowly rising, fast decaying (convex) curve, while if <emphasis>type</emphasis> &lt; 0, the curve is fast rising, slowly decaying (concave). See also <link linkend="transeg"><citetitle>transeg</citetitle></link>.
      </para>
    </note>
  </refsect1>
 
  <refsect1>
    <title>Credits</title>
    <para>
      <simplelist>
        <member>Author: &namejohn;</member>
        <member>University of Bath, Codemist. Ltd.</member>
        <member>Bath, UK</member>
        <member>October, 2000</member>
      </simplelist>
    </para>

    <para>New in Csound version 4.09</para>
  </refsect1>
</refentry>
