Debian Codegraph @

opcodes/sumarray.xml

raw symbols SCIP
1 
2 <refentry id="sumarray">
3 <indexterm id="IndexSumarray"><primary>sumarray</primary></indexterm>
4 <refentryinfo><title>Array Opcodes</title></refentryinfo>
5 <refmeta>
6 <refentrytitle>sumarray</refentrytitle>
7 </refmeta>
8
9
10
11 <refnamediv>
12 <refname>sumarray</refname>
13
14 <refpurpose>
15 returns the sum of the elements in an array.
16 </refpurpose>
17 </refnamediv>
18
19 <refsect1>
20 <title>Description</title>
21 <para>
22 The <emphasis>sumarray</emphasis> opcode returns the sum of all
23 elements in a k-rate array array.
24 </para>
25 </refsect1>
26
27 <refsect1>
28 <title>Syntax</title>
29 <synopsis>ksum <command>sumarray</command> karray</synopsis>
30 </refsect1>
31
32 <refsect1>
33 <title>Performance</title>
34 <para>
35 <emphasis>ksum</emphasis> -- variable for result.
36 </para>
37 <para>
38 <emphasis>karray</emphasis> -- array for reading.
39 </para>
40
41 </refsect1>
42
43 <refsect1>
44 <title>Examples</title>
45 <para>
46 Here is an example of the sumarray opcode. It uses the file <ulink url="examples/sumarray.csd"><citetitle>sumarray.csd</citetitle></ulink>.
47 <example>
48 <title>Example of the sumarray opcode.</title>
49 <para>See the sections <link linkend="UsingRealTime"><citetitle>Real-time Audio</citetitle></link> and <link linkend="CommandFlags"><citetitle>Command Line Flags</citetitle></link> for more information on using command line flags.</para>
50 <xi:include href="examples-xml/sumarray.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
51 </example>
52 </para>
53 </refsect1>
54
55 <refsect1>
56 <title>See also</title>
57 <para><link linkend="arrayOpcodes"><citetitle>Array opcodes</citetitle></link></para>
58 </refsect1>
59
60 <refsect1>
61 <title>Credits</title>
62 <para>
63 <simplelist>
64 <member>Author: &namejohn;</member>
65 <member>October 2011</member>
66 </simplelist>
67 </para>
68
69 <para>New in Csound version 5.14</para>
70 <para>Revised in Csound version 6.00 to work on multidimensional arrays</para>
71 </refsect1>
72 </refentry>