1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>init_rs</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="Reed-Solomon Library Programming Interface"><link rel="up" href="pubfunctions.html" title="Chapter&#160;5.&#160;Public Functions Provided"><link rel="prev" href="API-free-rs.html" title="free_rs"><link rel="next" href="API-init-rs-non-canonical.html" title="init_rs_non_canonical"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center"><span class="phrase">init_rs</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-free-rs.html">Prev</a>&#160;</td><th width="60%" align="center">Chapter&#160;5.&#160;Public Functions Provided</th><td width="20%" align="right">&#160;<a accesskey="n" href="API-init-rs-non-canonical.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-init-rs"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>init_rs &#8212; 
2     Find a matching or allocate a new rs control structure
3 </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="funcsynopsis"><table border="0" class="funcprototype-table" summary="Function synopsis" style="cellspacing: 0; cellpadding: 0;"><tr><td><code class="funcdef">struct rs_control * <b class="fsfunc">init_rs </b>(</code></td><td>int <var class="pdparam">symsize</var>, </td></tr><tr><td>&#160;</td><td>int <var class="pdparam">gfpoly</var>, </td></tr><tr><td>&#160;</td><td>int <var class="pdparam">fcr</var>, </td></tr><tr><td>&#160;</td><td>int <var class="pdparam">prim</var>, </td></tr><tr><td>&#160;</td><td>int <var class="pdparam">nroots</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div></div><div class="refsect1"><a name="idp1120766580"></a><h2>Arguments</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>symsize</code></em></span></dt><dd><p>
4     the symbol size (number of bits)
5    </p></dd><dt><span class="term"><em class="parameter"><code>gfpoly</code></em></span></dt><dd><p>
6     the extended Galois field generator polynomial coefficients,
7     with the 0th coefficient in the low order bit. The polynomial
8     must be primitive;
9    </p></dd><dt><span class="term"><em class="parameter"><code>fcr</code></em></span></dt><dd><p>
10     the first consecutive root of the rs code generator polynomial
11     in index form
12    </p></dd><dt><span class="term"><em class="parameter"><code>prim</code></em></span></dt><dd><p>
13     primitive element to generate polynomial roots
14    </p></dd><dt><span class="term"><em class="parameter"><code>nroots</code></em></span></dt><dd><p>
15     RS code generator polynomial degree (number of roots)
16    </p></dd></dl></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-free-rs.html">Prev</a>&#160;</td><td width="20%" align="center"><a accesskey="u" href="pubfunctions.html">Up</a></td><td width="40%" align="right">&#160;<a accesskey="n" href="API-init-rs-non-canonical.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">free_rs</span>&#160;</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">&#160;<span class="phrase">init_rs_non_canonical</span></td></tr></table></div></body></html>
17