<?xml version="1.0" encoding="UTF-8" standalone="no"?> <!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/html; charset=UTF-8" /> <title>urd</title> <link rel="stylesheet" href="csound.css" type="text/css" /> <meta name="generator" content="DocBook XSL Stylesheets V1.75.2" /> <link rel="home" href="index.html" title="The Canonical Csound Reference Manual" /> <link rel="up" href="OpcodesTop.html" title="Orchestra Opcodes and Operators" /> <link rel="prev" href="urandom.html" title="urandom" /> <link rel="next" href="vadd.html" title="vadd" /> </head> <body> <div class="navheader"> <table width="100%" summary="Navigation header"> <tr> <th colspan="3" align="center">urd</th> </tr> <tr> <td width="20%" align="left"><a accesskey="p" href="urandom.html">Prev</a> </td> <th width="60%" align="center">Orchestra Opcodes and Operators</th> <td width="20%" align="right"> <a accesskey="n" href="vadd.html">Next</a></td> </tr> </table> <hr /> </div> <div class="refentry" title="urd"> <a id="urd"></a> <div class="titlepage"></div> <a id="IndexUrd" class="indexterm"></a> <div class="refnamediv"> <h2> <span class="refentrytitle">urd</span> </h2> <p>urd — A discrete user-defined-distribution random generator that can be used as a function. </p> </div> <div class="refsect1" title="Description"> <a id="id3307615"></a> <h2>Description</h2> <p> A discrete user-defined-distribution random generator that can be used as a function. </p> </div> <div class="refsect1" title="Syntax"> <a id="id3307786"></a> <h2>Syntax</h2> <pre class="synopsis">aout = <span class="command"><strong>urd</strong></span>(ktableNum)</pre> <pre class="synopsis">iout = <span class="command"><strong>urd</strong></span>(itableNum)</pre> <pre class="synopsis">kout = <span class="command"><strong>urd</strong></span>(ktableNum)</pre> </div> <div class="refsect1" title="Initialization"> <a id="id3307827"></a> <h2>Initialization</h2> <p> <span class="emphasis"><em>itableNum</em></span> -- number of table containing the random-distribution function. Such table is generated by the user. See <a class="link" href="GEN40.html" title="GEN40">GEN40</a>, <a class="link" href="GEN41.html" title="GEN41">GEN41</a>, and <a class="link" href="GEN42.html" title="GEN42">GEN42</a>. The table length does not need to be a power of 2 </p> </div> <div class="refsect1" title="Performance"> <a id="id3307863"></a> <h2>Performance</h2> <p> <span class="emphasis"><em>ktableNum</em></span> -- number of table containing the random-distribution function. Such table is generated by the user. See <a class="link" href="GEN40.html" title="GEN40">GEN40</a>, <a class="link" href="GEN41.html" title="GEN41">GEN41</a>, and <a class="link" href="GEN42.html" title="GEN42">GEN42</a>. The table length does not need to be a power of 2 </p> <p> <span class="emphasis"><em>urd</em></span> is the same opcode as <a class="link" href="duserrnd.html" title="duserrnd"><em class="citetitle">duserrnd</em></a>, but can be used in function fashion. </p> <p> For a tutorial about random distribution histograms and functions see: </p> <div class="itemizedlist"> <ul class="itemizedlist" type="disc"> <li class="listitem"> <p> D. Lorrain. "A panoply of stochastic cannons". In C. Roads, ed. 1989. Music machine. Cambridge, Massachusetts: MIT press, pp. 351 - 379. </p> </li> </ul> </div> <p> </p> </div> <div class="refsect1" title="See Also"> <a id="id3308572"></a> <h2>See Also</h2> <p> <a class="link" href="cuserrnd.html" title="cuserrnd"><em class="citetitle">cuserrnd</em></a>, <a class="link" href="duserrnd.html" title="duserrnd"><em class="citetitle">duserrnd</em></a> </p> </div> <div class="refsect1" title="Credits"> <a id="id3308597"></a> <h2>Credits</h2> <p>Author: Gabriel Maldonado</p> <p>New in Version 4.16</p> </div> </div> <div class="navfooter"> <hr /> <table width="100%" summary="Navigation footer"> <tr> <td width="40%" align="left"><a accesskey="p" href="urandom.html">Prev</a> </td> <td width="20%" align="center"> <a accesskey="u" href="OpcodesTop.html">Up</a> </td> <td width="40%" align="right"> <a accesskey="n" href="vadd.html">Next</a></td> </tr> <tr> <td width="40%" align="left" valign="top">urandom </td> <td width="20%" align="center"> <a accesskey="h" href="index.html">Home</a> </td> <td width="40%" align="right" valign="top"> vadd</td> </tr> </table> </div> </body> </html>