<!-- Converted to DocBook/SGML by Kevin Conder -->
<refentry id="raises">
  <refmeta>
    <refentrytitle>&circ;</refentrytitle>
  </refmeta>
 
  <refnamediv>
    <refname>&circ;</refname>

    <refpurpose>
      <quote>Power of</quote> operator.
      <indexterm id="IndexCirc"><primary>&circ;</primary></indexterm>
    </refpurpose>
  </refnamediv>
 
  <refsect1>
    <title>Description</title>
    <para>
      Arithmetic operators perform operations of change-sign (negate), don't-change-sign, logical AND logical OR, add, subtract, multiply and divide. Note that a value or an expression may fall between two of these operators, either of which could take it as its left or right argument, as in
      <literallayout>
a + b * c.
      </literallayout>
    </para>

    <para>
      In such cases three rules apply:
    </para>

    <para>
      1. &ast; and <emphasis>&sol;</emphasis> bind to their neighbors more strongly than &plus; and &minus;. Thus the above expression is taken as
      <literallayout>  
a + (b * c)
      </literallayout>
      with &ast; taking b and c and then &plus; taking a and b &ast; c.
    </para>

    <para>
      2. <emphasis>&plus;</emphasis> and <emphasis>&minus;</emphasis> bind more strongly than &amp;&amp;, which in turn is stronger than &verbar;&verbar;:
      <literallayout>  
a &amp;&amp; b - c &verbar;&verbar; d
      </literallayout>
      is taken as
      <literallayout>  
(a &amp;&amp; (b - c)) &verbar;&verbar; d
      </literallayout>
    </para>

    <para>
      3. When both operators bind equally strongly, the operations are done left to right:
      <literallayout>  
a - b - c i
      </literallayout>
      is taken as
      <literallayout>  
(a - b) - c
      </literallayout>
    </para>

    <para>
      Parentheses may be used as above to force particular groupings.
    </para>

    <para>
      The operator <emphasis>&circ;</emphasis> raises <emphasis>a</emphasis> to the <emphasis>b</emphasis> power. <emphasis>b</emphasis> may not be audio-rate. Use with caution as precedence may not work correctly. See <link linkend="pow"><citetitle>pow</citetitle></link>.  (New in Csound version 3.493.)
    </para>
  </refsect1>

  <refsect1>
    <title>Syntax</title>
    <synopsis>a <command>&circ;</command>  b  (b not audio-rate)</synopsis>

    <para>
      where the arguments <emphasis>a</emphasis> and <emphasis>b</emphasis> may be further expressions.
    </para>
  </refsect1>

  <refsect1>
    <title>Examples</title>
    <para>
      Here is an example of the &circ; operator. It uses the files <ulink url="examples/raises.orc"><citetitle>raises.orc</citetitle></ulink> and <ulink url="examples/raises.sco"><citetitle>raises.sco</citetitle></ulink>.

      <example>
        <title>Example of the &circ; operator.</title>

        <programlisting>
<inlinemediaobject>
            <imageobject>
              <imagedata fileref="examples/raises.orc" format="linespecific">
            </imageobject>
          </inlinemediaobject>
        </programlisting>

        <programlisting>
<inlinemediaobject>
            <imageobject>
              <imagedata fileref="examples/raises.sco" format="linespecific">
            </imageobject>
          </inlinemediaobject>
        </programlisting>
      </example>

      Its output should include a line like this:
      <screen>
instr 1:  i1 = 4096.000
      </screen>
    </para>
  </refsect1>

  <refsect1>
    <title>See Also</title>
    <para>
      <link linkend="subtracts"><citetitle>-</citetitle></link>, 
      <link linkend="adds"><citetitle>&plus;</citetitle></link>, 
      <link linkend="opand"><citetitle>&amp;&amp;</citetitle></link>, 
      <link linkend="opor"><citetitle>&verbar;&verbar;</citetitle></link>, 
      <link linkend="multiplies"><citetitle>&ast;</citetitle></link>, 
      <link linkend="divides"><citetitle>&sol;</citetitle></link>, 
      <link linkend="modulus"><citetitle>&percnt;</citetitle></link>
    </para>
  </refsect1>

  <refsect1>
    <title>Credits</title>
    <para>Example written by &namekevin;.</para>
  </refsect1>
</refentry>
