Documentation for af72fab013

This commit is contained in:
realstealthninja
2024-08-31 00:44:14 +00:00
parent 1fc5a79d4f
commit 41be012ea2
88 changed files with 1144 additions and 1691 deletions

View File

@@ -110,12 +110,11 @@ $(function(){initNavTree('d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.
<p>This is the complete list of members for <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a>, including all inherited members.</p>
<table class="directory">
<tr bgcolor="#f0f0f0" class="even"><td class="entry"><b>fac</b> (defined in <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a>)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#afde201f4687740454302c444f507a926">gcdExtended</a>(const uint64_t &amp;a, const uint64_t &amp;b, int64_t *x, int64_t *y)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a0431ec5c876e1154d8e1e5f89e1ab34a">modInverse</a>(const uint64_t &amp;a, const uint64_t &amp;m)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08">ncr</a>(const uint64_t &amp;n, const uint64_t &amp;r, const uint64_t &amp;p)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#af3d41271912f9fa50b774c96c51874b9">NCRModuloP</a>(const uint64_t &amp;size, const uint64_t &amp;mod)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a57c168cd6eb85718eab97da658a698ad">p</a></td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#ab5744fa589f6a48f9fe7bca13dbe661f">computeFactorialsMod</a>(const int64_t &amp;max_arg_val, const int64_t &amp;mod)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">inline</span><span class="mlabel">private</span><span class="mlabel">static</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a738a5f59bb3560c81cdb7f43bcfe9fec">fac</a></td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
<tr class="even"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a499df7a01bcd348345dc5a0ab79bb0e9">ncr</a>(const int64_t &amp;n, const int64_t &amp;r) const</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr class="odd"><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a94b07e7dc61d8d7a1e9c5a28988e72f9">NCRModuloP</a>(const int64_t &amp;size, const int64_t &amp;p)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
<tr bgcolor="#f0f0f0" class="even"><td class="entry"><b>p</b> (defined in <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a>)</td><td class="entry"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
</table></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->

View File

@@ -137,20 +137,130 @@ Namespaces</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">namespace &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d4/db9/namespacencr__modulo__p.html">ncr_modulo_p</a></td></tr>
<tr class="memdesc:d4/db9/namespacencr__modulo__p"><td class="mdescLeft">&#160;</td><td class="mdescRight">Functions for <a href="https://cp-algorithms.com/combinatorics/binomial-coefficients.html" target="_blank">nCr modulo p</a> implementation. <br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">namespace &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d6/d84/namespaceutils.html">utils</a></td></tr>
<tr class="memdesc:d6/d84/namespaceutils"><td class="mdescLeft">&#160;</td><td class="mdescRight">this namespace contains the definitions of the functions called from the class <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html" title="Class which contains all methods required for calculating nCr mod p.">math::ncr_modulo_p::NCRModuloP</a> <br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="func-members" name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:af0a3e6827f41c151e47451f5ff98b1f1" id="r_af0a3e6827f41c151e47451f5ff98b1f1"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#af0a3e6827f41c151e47451f5ff98b1f1">tests</a> (<a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a> ncrObj)</td></tr>
<tr class="memdesc:af0a3e6827f41c151e47451f5ff98b1f1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Test implementations. <br /></td></tr>
<tr class="separator:af0a3e6827f41c151e47451f5ff98b1f1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9010ad5669d31449c3bf3271ab5ebc86" id="r_a9010ad5669d31449c3bf3271ab5ebc86"><td class="memItemLeft" align="right" valign="top">int64_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a9010ad5669d31449c3bf3271ab5ebc86">math::ncr_modulo_p::utils::gcdExtended</a> (const int64_t &amp;a, const int64_t &amp;b, int64_t &amp;x, int64_t &amp;y)</td></tr>
<tr class="memdesc:a9010ad5669d31449c3bf3271ab5ebc86"><td class="mdescLeft">&#160;</td><td class="mdescRight">finds the values x and y such that a*x + b*y = gcd(a,b) <br /></td></tr>
<tr class="separator:a9010ad5669d31449c3bf3271ab5ebc86"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6c7bfe3bdaa086d32261a5c5584d0fa9" id="r_a6c7bfe3bdaa086d32261a5c5584d0fa9"><td class="memItemLeft" align="right" valign="top">int64_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a6c7bfe3bdaa086d32261a5c5584d0fa9">math::ncr_modulo_p::utils::modInverse</a> (const int64_t &amp;a, const int64_t &amp;m)</td></tr>
<tr class="separator:a6c7bfe3bdaa086d32261a5c5584d0fa9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a483bb8ccf42aaf7375a83e91490eda1e" id="r_a483bb8ccf42aaf7375a83e91490eda1e"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a483bb8ccf42aaf7375a83e91490eda1e">tests</a> ()</td></tr>
<tr class="memdesc:a483bb8ccf42aaf7375a83e91490eda1e"><td class="mdescLeft">&#160;</td><td class="mdescRight">tests <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html" title="Class which contains all methods required for calculating nCr mod p.">math::ncr_modulo_p::NCRModuloP</a> <br /></td></tr>
<tr class="separator:a483bb8ccf42aaf7375a83e91490eda1e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afa2b50f4716fc3b42221a72e676e1422" id="r_afa2b50f4716fc3b42221a72e676e1422"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#afa2b50f4716fc3b42221a72e676e1422">example</a> ()</td></tr>
<tr class="memdesc:afa2b50f4716fc3b42221a72e676e1422"><td class="mdescLeft">&#160;</td><td class="mdescRight">example showing the usage of the <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html" title="Class which contains all methods required for calculating nCr mod p.">math::ncr_modulo_p::NCRModuloP</a> class <br /></td></tr>
<tr class="separator:afa2b50f4716fc3b42221a72e676e1422"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae66f6b31b5ad750f1fe042a706a4e3d4" id="r_ae66f6b31b5ad750f1fe042a706a4e3d4"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ae66f6b31b5ad750f1fe042a706a4e3d4">main</a> ()</td></tr>
<tr class="memdesc:ae66f6b31b5ad750f1fe042a706a4e3d4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Main function. <br /></td></tr>
<tr class="separator:ae66f6b31b5ad750f1fe042a706a4e3d4"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>This program aims at calculating <a href="https://cp-algorithms.com/combinatorics/binomial-coefficients.html" target="_blank">nCr modulo p</a>. </p>
<p>nCr is defined as n! / (r! * (n-r)!) where n! represents factorial of n. In many cases, the value of nCr is too large to fit in a 64 bit integer. Hence, in competitive programming, there are many problems or subproblems to compute nCr modulo p where p is a given number. </p><dl class="section author"><dt>Author</dt><dd><a href="https://github.com/KaustubhDamania" target="_blank">Kaustubh Damania</a> </dd></dl>
</div><h2 class="groupheader">Function Documentation</h2>
<a id="afa2b50f4716fc3b42221a72e676e1422" name="afa2b50f4716fc3b42221a72e676e1422"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afa2b50f4716fc3b42221a72e676e1422">&#9670;&#160;</a></span>example()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void example </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>example showing the usage of the <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html" title="Class which contains all methods required for calculating nCr mod p.">math::ncr_modulo_p::NCRModuloP</a> class </p>
<div class="fragment"><div class="line"><span class="lineno"> 175</span> {</div>
<div class="line"><span class="lineno"> 176</span> <span class="keyword">const</span> int64_t size = 1e6 + 1;</div>
<div class="line"><span class="lineno"> 177</span> <span class="keyword">const</span> int64_t p = 1e9 + 7;</div>
<div class="line"><span class="lineno"> 178</span> </div>
<div class="line"><span class="lineno"> 179</span> <span class="comment">// the ncrObj contains the precomputed values of factorials modulo p for</span></div>
<div class="line"><span class="lineno"> 180</span> <span class="comment">// values from 0 to size</span></div>
<div class="line"><span class="lineno"> 181</span> <span class="keyword">const</span> <span class="keyword">auto</span> ncrObj = <a class="code hl_class" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a>(size, p);</div>
<div class="line"><span class="lineno"> 182</span> </div>
<div class="line"><span class="lineno"> 183</span> <span class="comment">// having the ncrObj we can efficiently query the values of (n C r)%p</span></div>
<div class="line"><span class="lineno"> 184</span> <span class="comment">// note that time of the computation does not depend on size</span></div>
<div class="line"><span class="lineno"> 185</span> <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i &lt;= 7; i++) {</div>
<div class="line"><span class="lineno"> 186</span> <a class="code hl_classRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> &lt;&lt; 6 &lt;&lt; <span class="stringliteral">&quot;C&quot;</span> &lt;&lt; i &lt;&lt; <span class="stringliteral">&quot; mod &quot;</span> &lt;&lt; p &lt;&lt; <span class="stringliteral">&quot; = &quot;</span> &lt;&lt; ncrObj.ncr(6, i)</div>
<div class="line"><span class="lineno"> 187</span> &lt;&lt; <span class="stringliteral">&quot;\n&quot;</span>;</div>
<div class="line"><span class="lineno"> 188</span> }</div>
<div class="line"><span class="lineno"> 189</span>}</div>
<div class="ttc" id="abasic_ostream_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a></div></div>
<div class="ttc" id="aclassmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p_html"><div class="ttname"><a href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></div><div class="ttdoc">Class which contains all methods required for calculating nCr mod p.</div><div class="ttdef"><b>Definition</b> ncr_modulo_p.cpp:79</div></div>
</div><!-- fragment -->
</div>
</div>
<a id="a9010ad5669d31449c3bf3271ab5ebc86" name="a9010ad5669d31449c3bf3271ab5ebc86"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9010ad5669d31449c3bf3271ab5ebc86">&#9670;&#160;</a></span>gcdExtended()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int64_t math::ncr_modulo_p::utils::gcdExtended </td>
<td>(</td>
<td class="paramtype">const int64_t &amp;</td> <td class="paramname"><span class="paramname"><em>a</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const int64_t &amp;</td> <td class="paramname"><span class="paramname"><em>b</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int64_t &amp;</td> <td class="paramname"><span class="paramname"><em>x</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int64_t &amp;</td> <td class="paramname"><span class="paramname"><em>y</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>finds the values x and y such that a*x + b*y = gcd(a,b) </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">a</td><td>the first input of the gcd </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">a</td><td>the second input of the gcd </td></tr>
<tr><td class="paramdir">[out]</td><td class="paramname">x</td><td>the Bézout coefficient of a </td></tr>
<tr><td class="paramdir">[out]</td><td class="paramname">y</td><td>the Bézout coefficient of b </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the gcd of a and b </dd></dl>
<div class="fragment"><div class="line"><span class="lineno"> 45</span> {</div>
<div class="line"><span class="lineno"> 46</span> <span class="keywordflow">if</span> (a == 0) {</div>
<div class="line"><span class="lineno"> 47</span> x = 0;</div>
<div class="line"><span class="lineno"> 48</span> y = 1;</div>
<div class="line"><span class="lineno"> 49</span> <span class="keywordflow">return</span> b;</div>
<div class="line"><span class="lineno"> 50</span> }</div>
<div class="line"><span class="lineno"> 51</span> </div>
<div class="line"><span class="lineno"> 52</span> int64_t x1 = 0, y1 = 0;</div>
<div class="line"><span class="lineno"> 53</span> <span class="keyword">const</span> int64_t <a class="code hl_function" href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e">gcd</a> = <a class="code hl_function" href="#a9010ad5669d31449c3bf3271ab5ebc86">gcdExtended</a>(b % a, a, x1, y1);</div>
<div class="line"><span class="lineno"> 54</span> </div>
<div class="line"><span class="lineno"> 55</span> x = y1 - (b / a) * x1;</div>
<div class="line"><span class="lineno"> 56</span> y = x1;</div>
<div class="line"><span class="lineno"> 57</span> <span class="keywordflow">return</span> <a class="code hl_function" href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e">gcd</a>;</div>
<div class="line"><span class="lineno"> 58</span>}</div>
<div class="ttc" id="agcd__iterative__euclidean_8cpp_html_ae48807fa2b7000afae599e67f327545e"><div class="ttname"><a href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e">gcd</a></div><div class="ttdeci">int gcd(int num1, int num2)</div><div class="ttdef"><b>Definition</b> gcd_iterative_euclidean.cpp:15</div></div>
<div class="ttc" id="ancr__modulo__p_8cpp_html_a9010ad5669d31449c3bf3271ab5ebc86"><div class="ttname"><a href="#a9010ad5669d31449c3bf3271ab5ebc86">math::ncr_modulo_p::utils::gcdExtended</a></div><div class="ttdeci">int64_t gcdExtended(const int64_t &amp;a, const int64_t &amp;b, int64_t &amp;x, int64_t &amp;y)</div><div class="ttdoc">finds the values x and y such that a*x + b*y = gcd(a,b)</div><div class="ttdef"><b>Definition</b> ncr_modulo_p.cpp:44</div></div>
</div><!-- fragment --><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><iframe scrolling="no" frameborder="0" src="../../de/dab/ncr__modulo__p_8cpp_a9010ad5669d31449c3bf3271ab5ebc86_cgraph.svg" width="240" height="76"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div>
</div>
</div>
</div>
<a id="ae66f6b31b5ad750f1fe042a706a4e3d4" name="ae66f6b31b5ad750f1fe042a706a4e3d4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae66f6b31b5ad750f1fe042a706a4e3d4">&#9670;&#160;</a></span>main()</h2>
@@ -165,37 +275,63 @@ Functions</h2></td></tr>
</tr>
</table>
</div><div class="memdoc">
<div class="fragment"><div class="line"><span class="lineno"> 191</span> {</div>
<div class="line"><span class="lineno"> 192</span> <a class="code hl_function" href="#a483bb8ccf42aaf7375a83e91490eda1e">tests</a>();</div>
<div class="line"><span class="lineno"> 193</span> <a class="code hl_function" href="#afa2b50f4716fc3b42221a72e676e1422">example</a>();</div>
<div class="line"><span class="lineno"> 194</span> <span class="keywordflow">return</span> 0;</div>
<div class="line"><span class="lineno"> 195</span>}</div>
<div class="ttc" id="ancr__modulo__p_8cpp_html_a483bb8ccf42aaf7375a83e91490eda1e"><div class="ttname"><a href="#a483bb8ccf42aaf7375a83e91490eda1e">tests</a></div><div class="ttdeci">static void tests()</div><div class="ttdoc">tests math::ncr_modulo_p::NCRModuloP</div><div class="ttdef"><b>Definition</b> ncr_modulo_p.cpp:142</div></div>
<div class="ttc" id="ancr__modulo__p_8cpp_html_afa2b50f4716fc3b42221a72e676e1422"><div class="ttname"><a href="#afa2b50f4716fc3b42221a72e676e1422">example</a></div><div class="ttdeci">void example()</div><div class="ttdoc">example showing the usage of the math::ncr_modulo_p::NCRModuloP class</div><div class="ttdef"><b>Definition</b> ncr_modulo_p.cpp:175</div></div>
</div><!-- fragment -->
</div>
</div>
<a id="a6c7bfe3bdaa086d32261a5c5584d0fa9" name="a6c7bfe3bdaa086d32261a5c5584d0fa9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6c7bfe3bdaa086d32261a5c5584d0fa9">&#9670;&#160;</a></span>modInverse()</h2>
<p>Main function. </p>
<dl class="section return"><dt>Returns</dt><dd>0 on exit </dd></dl>
<div class="fragment"><div class="line"><span class="lineno"> 137</span> {</div>
<div class="line"><span class="lineno"> 138</span> <span class="comment">// populate the fac array</span></div>
<div class="line"><span class="lineno"> 139</span> <span class="keyword">const</span> uint64_t size = 1e6 + 1;</div>
<div class="line"><span class="lineno"> 140</span> <span class="keyword">const</span> uint64_t p = 1e9 + 7;</div>
<div class="line"><span class="lineno"> 141</span> <a class="code hl_class" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a> ncrObj =</div>
<div class="line"><span class="lineno"> 142</span> <a class="code hl_class" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a>(size, p);</div>
<div class="line"><span class="lineno"> 143</span> <span class="comment">// test 6Ci for i=0 to 7</span></div>
<div class="line"><span class="lineno"> 144</span> <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i &lt;= 7; i++) {</div>
<div class="line"><span class="lineno"> 145</span> <a class="code hl_classRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> &lt;&lt; 6 &lt;&lt; <span class="stringliteral">&quot;C&quot;</span> &lt;&lt; i &lt;&lt; <span class="stringliteral">&quot; = &quot;</span> &lt;&lt; ncrObj.<a class="code hl_function" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08">ncr</a>(6, i, p) &lt;&lt; <span class="stringliteral">&quot;\n&quot;</span>;</div>
<div class="line"><span class="lineno"> 146</span> }</div>
<div class="line"><span class="lineno"> 147</span> <a class="code hl_namespace" href="../../d9/df4/namespacetests.html">tests</a>(ncrObj); <span class="comment">// execute the tests</span></div>
<div class="line"><span class="lineno"> 148</span> <a class="code hl_classRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> &lt;&lt; <span class="stringliteral">&quot;Assertions passed\n&quot;</span>;</div>
<div class="line"><span class="lineno"> 149</span> <span class="keywordflow">return</span> 0;</div>
<div class="line"><span class="lineno"> 150</span>}</div>
<div class="ttc" id="abasic_ostream_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a></div></div>
<div class="ttc" id="aclassmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p_html"><div class="ttname"><a href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></div><div class="ttdoc">Class which contains all methods required for calculating nCr mod p.</div><div class="ttdef"><b>Definition</b> ncr_modulo_p.cpp:31</div></div>
<div class="ttc" id="aclassmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p_html_a6b95277f5f527beacc8d0f3bc91fcd08"><div class="ttname"><a href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08">math::ncr_modulo_p::NCRModuloP::ncr</a></div><div class="ttdeci">int64_t ncr(const uint64_t &amp;n, const uint64_t &amp;r, const uint64_t &amp;p)</div><div class="ttdef"><b>Definition</b> ncr_modulo_p.cpp:92</div></div>
<div class="ttc" id="anamespacetests_html"><div class="ttname"><a href="../../d9/df4/namespacetests.html">tests</a></div><div class="ttdoc">Testcases to check Union of Two Arrays.</div></div>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int64_t math::ncr_modulo_p::utils::modInverse </td>
<td>(</td>
<td class="paramtype">const int64_t &amp;</td> <td class="paramname"><span class="paramname"><em>a</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const int64_t &amp;</td> <td class="paramname"><span class="paramname"><em>m</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Find modular inverse of a modulo m i.e. a number x such that (a*x)m = 1</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">a</td><td>the number for which the modular inverse is queried </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">m</td><td>the modulus </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the inverce of a modulo m, if it exists, -1 otherwise </dd></dl>
<div class="fragment"><div class="line"><span class="lineno"> 66</span> {</div>
<div class="line"><span class="lineno"> 67</span> int64_t x = 0, y = 0;</div>
<div class="line"><span class="lineno"> 68</span> <span class="keyword">const</span> int64_t <a class="code hl_function" href="../../d4/d18/composite__simpson__rule_8cpp.html#a2f67508d5f392b0321772169342c98ad">g</a> = <a class="code hl_function" href="#a9010ad5669d31449c3bf3271ab5ebc86">gcdExtended</a>(a, m, x, y);</div>
<div class="line"><span class="lineno"> 69</span> <span class="keywordflow">if</span> (g != 1) { <span class="comment">// modular inverse doesn&#39;t exist</span></div>
<div class="line"><span class="lineno"> 70</span> <span class="keywordflow">return</span> -1;</div>
<div class="line"><span class="lineno"> 71</span> } <span class="keywordflow">else</span> {</div>
<div class="line"><span class="lineno"> 72</span> <span class="keywordflow">return</span> ((x + m) % m);</div>
<div class="line"><span class="lineno"> 73</span> }</div>
<div class="line"><span class="lineno"> 74</span>}</div>
<div class="ttc" id="acomposite__simpson__rule_8cpp_html_a2f67508d5f392b0321772169342c98ad"><div class="ttname"><a href="../../d4/d18/composite__simpson__rule_8cpp.html#a2f67508d5f392b0321772169342c98ad">numerical_methods::simpson_method::g</a></div><div class="ttdeci">double g(double x)</div><div class="ttdoc">Another test function.</div><div class="ttdef"><b>Definition</b> composite_simpson_rule.cpp:115</div></div>
</div><!-- fragment --><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><div class="zoom"><iframe scrolling="no" frameborder="0" src="../../de/dab/ncr__modulo__p_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph.svg" width="100%" height="300"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div></div>
<div class="center"><iframe scrolling="no" frameborder="0" src="../../de/dab/ncr__modulo__p_8cpp_a6c7bfe3bdaa086d32261a5c5584d0fa9_cgraph.svg" width="428" height="76"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div>
</div>
</div>
</div>
<a id="af0a3e6827f41c151e47451f5ff98b1f1" name="af0a3e6827f41c151e47451f5ff98b1f1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af0a3e6827f41c151e47451f5ff98b1f1">&#9670;&#160;</a></span>tests()</h2>
<a id="a483bb8ccf42aaf7375a83e91490eda1e" name="a483bb8ccf42aaf7375a83e91490eda1e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a483bb8ccf42aaf7375a83e91490eda1e">&#9670;&#160;</a></span>tests()</h2>
<div class="memitem">
<div class="memproto">
@@ -206,7 +342,7 @@ Here is the call graph for this function:</div>
<tr>
<td class="memname">static void tests </td>
<td>(</td>
<td class="paramtype"><a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a></td> <td class="paramname"><span class="paramname"><em>ncrObj</em></span></td><td>)</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
@@ -217,26 +353,43 @@ Here is the call graph for this function:</div>
</table>
</div><div class="memdoc">
<p>Test implementations. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">ncrObj</td><td>object which contains the precomputed factorial values and ncr function </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>void </dd></dl>
<div class="fragment"><div class="line"><span class="lineno"> 124</span> {</div>
<div class="line"><span class="lineno"> 125</span> <span class="comment">// (52323 C 26161) % (1e9 + 7) = 224944353</span></div>
<div class="line"><span class="lineno"> 126</span> assert(ncrObj.<a class="code hl_function" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08">ncr</a>(52323, 26161, 1000000007) == 224944353);</div>
<div class="line"><span class="lineno"> 127</span> <span class="comment">// 6 C 2 = 30, 30%5 = 0</span></div>
<div class="line"><span class="lineno"> 128</span> assert(ncrObj.<a class="code hl_function" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08">ncr</a>(6, 2, 5) == 0);</div>
<div class="line"><span class="lineno"> 129</span> <span class="comment">// 7C3 = 35, 35 % 29 = 8</span></div>
<div class="line"><span class="lineno"> 130</span> assert(ncrObj.<a class="code hl_function" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08">ncr</a>(7, 3, 29) == 6);</div>
<div class="line"><span class="lineno"> 131</span>}</div>
<p>tests <a class="el" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html" title="Class which contains all methods required for calculating nCr mod p.">math::ncr_modulo_p::NCRModuloP</a> </p>
<div class="fragment"><div class="line"><span class="lineno"> 142</span> {</div>
<div class="line"><span class="lineno"> 143</span> <span class="keyword">struct </span><a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a> {</div>
<div class="line"><span class="lineno"> 144</span> <span class="keyword">const</span> int64_t size;</div>
<div class="line"><span class="lineno"> 145</span> <span class="keyword">const</span> int64_t p;</div>
<div class="line"><span class="lineno"> 146</span> <span class="keyword">const</span> int64_t n;</div>
<div class="line"><span class="lineno"> 147</span> <span class="keyword">const</span> int64_t r;</div>
<div class="line"><span class="lineno"> 148</span> <span class="keyword">const</span> int64_t expected;</div>
<div class="line"><span class="lineno"> 149</span> </div>
<div class="line"><span class="lineno"> 150</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(<span class="keyword">const</span> int64_t size, <span class="keyword">const</span> int64_t p, <span class="keyword">const</span> int64_t n,</div>
<div class="line"><span class="lineno"> 151</span> <span class="keyword">const</span> int64_t r, <span class="keyword">const</span> int64_t expected)</div>
<div class="line"><span class="lineno"> 152</span> : size(size), p(p), n(n), r(r), expected(expected) {}</div>
<div class="line"><span class="lineno"> 153</span> };</div>
<div class="line"><span class="lineno"> 154</span> <span class="keyword">const</span> <a class="code hl_classRef" target="_blank" href="http://en.cppreference.com/w/cpp/container/vector.html">std::vector&lt;TestCase&gt;</a> test_cases = {</div>
<div class="line"><span class="lineno"> 155</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(60000, 1000000007, 52323, 26161, 224944353),</div>
<div class="line"><span class="lineno"> 156</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(20, 5, 6, 2, 30 % 5),</div>
<div class="line"><span class="lineno"> 157</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(100, 29, 7, 3, 35 % 29),</div>
<div class="line"><span class="lineno"> 158</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(1000, 13, 10, 3, 120 % 13),</div>
<div class="line"><span class="lineno"> 159</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(20, 17, 1, 10, 0),</div>
<div class="line"><span class="lineno"> 160</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(45, 19, 23, 1, 23 % 19),</div>
<div class="line"><span class="lineno"> 161</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(45, 19, 23, 0, 1),</div>
<div class="line"><span class="lineno"> 162</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(45, 19, 23, 23, 1),</div>
<div class="line"><span class="lineno"> 163</span> <a class="code hl_struct" href="../../da/d86/struct_test_case.html">TestCase</a>(20, 9, 10, 2, -1)};</div>
<div class="line"><span class="lineno"> 164</span> <span class="keywordflow">for</span> (<span class="keyword">const</span> <span class="keyword">auto</span>&amp; tc : test_cases) {</div>
<div class="line"><span class="lineno"> 165</span> assert(<a class="code hl_class" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html">math::ncr_modulo_p::NCRModuloP</a>(tc.size, tc.p).<a class="code hl_function" href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a499df7a01bcd348345dc5a0ab79bb0e9">ncr</a>(tc.n, tc.r) ==</div>
<div class="line"><span class="lineno"> 166</span> tc.expected);</div>
<div class="line"><span class="lineno"> 167</span> }</div>
<div class="line"><span class="lineno"> 168</span> </div>
<div class="line"><span class="lineno"> 169</span> <a class="code hl_classRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> &lt;&lt; <span class="stringliteral">&quot;\n\nAll tests have successfully passed!\n&quot;</span>;</div>
<div class="line"><span class="lineno"> 170</span>}</div>
<div class="ttc" id="aclassmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p_html_a499df7a01bcd348345dc5a0ab79bb0e9"><div class="ttname"><a href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a499df7a01bcd348345dc5a0ab79bb0e9">math::ncr_modulo_p::NCRModuloP::ncr</a></div><div class="ttdeci">int64_t ncr(const int64_t &amp;n, const int64_t &amp;r) const</div><div class="ttdoc">computes nCr % p</div><div class="ttdef"><b>Definition</b> ncr_modulo_p.cpp:116</div></div>
<div class="ttc" id="astruct_test_case_html"><div class="ttname"><a href="../../da/d86/struct_test_case.html">TestCase</a></div><div class="ttdoc">represents single example inputs and expected output of the function longest_common_string_length</div><div class="ttdef"><b>Definition</b> longest_common_string.cpp:54</div></div>
<div class="ttc" id="avector_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/container/vector.html">std::vector</a></div></div>
</div><!-- fragment --><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><div class="zoom"><iframe scrolling="no" frameborder="0" src="../../de/dab/ncr__modulo__p_8cpp_af0a3e6827f41c151e47451f5ff98b1f1_cgraph.svg" width="100%" height="300"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div></div>
<div class="center"><iframe scrolling="no" frameborder="0" src="../../de/dab/ncr__modulo__p_8cpp_a483bb8ccf42aaf7375a83e91490eda1e_cgraph.svg" width="248" height="52"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div>
</div>
</div>

View File

@@ -1,6 +1,8 @@
var ncr__modulo__p_8cpp =
[
[ "math::ncr_modulo_p::NCRModuloP", "d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html", "d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p" ],
[ "main", "de/dab/ncr__modulo__p_8cpp.html#ae66f6b31b5ad750f1fe042a706a4e3d4", null ],
[ "tests", "de/dab/ncr__modulo__p_8cpp.html#af0a3e6827f41c151e47451f5ff98b1f1", null ]
[ "example", "de/dab/ncr__modulo__p_8cpp.html#afa2b50f4716fc3b42221a72e676e1422", null ],
[ "gcdExtended", "de/dab/ncr__modulo__p_8cpp.html#a9010ad5669d31449c3bf3271ab5ebc86", null ],
[ "modInverse", "de/dab/ncr__modulo__p_8cpp.html#a6c7bfe3bdaa086d32261a5c5584d0fa9", null ],
[ "tests", "de/dab/ncr__modulo__p_8cpp.html#a483bb8ccf42aaf7375a83e91490eda1e", null ]
];

View File

@@ -0,0 +1,5 @@
<map id="tests" name="tests">
<area shape="rect" id="Node000001" title="tests math::ncr_modulo_p::NCRModuloP" alt="" coords="5,13,56,38"/>
<area shape="rect" id="Node000002" href="$d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a499df7a01bcd348345dc5a0ab79bb0e9" title="computes nCr % p" alt="" coords="104,5,243,46"/>
<area shape="poly" id="edge1_Node000001_Node000002" title=" " alt="" coords="56,23,88,23,88,28,56,28"/>
</map>

View File

@@ -0,0 +1 @@
ec67b7f0511b8bc24ff7b08d968d95ab

View File

@@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: tests Pages: 1 -->
<svg width="186pt" height="39pt"
viewBox="0.00 0.00 186.25 38.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<svg id="main" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve">
<style type="text/css"><![CDATA[
.node, .edge {opacity: 0.7;}
.node.selected, .edge.selected {opacity: 1;}
.edge:hover path { stroke: red; }
.edge:hover polygon { stroke: red; fill: red; }
]]></style>
<script type="application/ecmascript" xlink:href="../../svg.min.js"/>
<svg id="graph" class="graph">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 34.5)">
<title>tests</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="tests math::ncr_modulo_p::NCRModuloP">
<polygon fill="#999999" stroke="#666666" points="37.75,-24.88 0,-24.88 0,-5.63 37.75,-5.63 37.75,-24.88"/>
<text text-anchor="middle" x="18.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">tests</text>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a499df7a01bcd348345dc5a0ab79bb0e9" target="_top" xlink:title="computes nCr % p">
<polygon fill="white" stroke="#666666" points="178.25,-30.5 73.75,-30.5 73.75,0 178.25,0 178.25,-30.5"/>
<text text-anchor="start" x="81.75" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="126" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::ncr</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M38.19,-15.25C45.14,-15.25 53.5,-15.25 62.25,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="61.96,-18.75 71.96,-15.25 61.96,-11.75 61.96,-18.75"/>
</a>
</g>
</g>
</g>
</svg>
</svg>
<style type='text/css'>
<![CDATA[
[data-mouse-over-selected='false'] { opacity: 0.7; }
[data-mouse-over-selected='true'] { opacity: 1.0; }
]]>
</style>
<script type="application/ecmascript"><![CDATA[
document.addEventListener('DOMContentLoaded', (event) => {
highlightEdges();
highlightAdjacentNodes();
});
]]></script>
</svg>

After

Width:  |  Height:  |  Size: 2.6 KiB

View File

@@ -0,0 +1,40 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: tests Pages: 1 -->
<svg width="186pt" height="39pt"
viewBox="0.00 0.00 186.25 38.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 34.5)">
<title>tests</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="tests math::ncr_modulo_p::NCRModuloP">
<polygon fill="#999999" stroke="#666666" points="37.75,-24.88 0,-24.88 0,-5.63 37.75,-5.63 37.75,-24.88"/>
<text text-anchor="middle" x="18.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">tests</text>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a499df7a01bcd348345dc5a0ab79bb0e9" target="_top" xlink:title="computes nCr % p">
<polygon fill="white" stroke="#666666" points="178.25,-30.5 73.75,-30.5 73.75,0 178.25,0 178.25,-30.5"/>
<text text-anchor="start" x="81.75" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="126" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::ncr</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M38.19,-15.25C45.14,-15.25 53.5,-15.25 62.25,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="61.96,-18.75 71.96,-15.25 61.96,-11.75 61.96,-18.75"/>
</a>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@@ -0,0 +1,9 @@
<map id="math::ncr_modulo_p::utils::modInverse" name="math::ncr_modulo_p::utils::modInverse">
<area shape="rect" id="Node000001" title=" " alt="" coords="5,29,145,70"/>
<area shape="poly" id="edge4_Node000001_Node000001" title=" " alt="" coords="39,29,37,19,43,10,56,5,75,3,95,5,108,11,105,16,94,10,75,8,57,10,47,15,43,20,44,28"/>
<area shape="rect" id="Node000002" href="$de/dab/ncr__modulo__p_8cpp.html#a9010ad5669d31449c3bf3271ab5ebc86" title="finds the values x and y such that a*x + b*y = gcd(a,b)" alt="" coords="193,29,332,70"/>
<area shape="poly" id="edge1_Node000001_Node000002" title=" " alt="" coords="145,47,177,47,177,52,145,52"/>
<area shape="poly" id="edge3_Node000002_Node000002" title=" " alt="" coords="235,29,234,20,238,11,248,5,262,3,278,5,287,12,284,16,276,10,262,8,250,10,242,14,239,20,240,28"/>
<area shape="rect" id="Node000003" href="$d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" title=" " alt="" coords="380,37,422,62"/>
<area shape="poly" id="edge2_Node000002_Node000003" title=" " alt="" coords="333,47,364,47,364,52,333,52"/>
</map>

View File

@@ -0,0 +1 @@
1a4f0a265ffd31483084966d366feec6

View File

@@ -0,0 +1,103 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: math::ncr_modulo_p::utils::modInverse Pages: 1 -->
<svg width="321pt" height="57pt"
viewBox="0.00 0.00 320.75 56.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<svg id="main" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve">
<style type="text/css"><![CDATA[
.node, .edge {opacity: 0.7;}
.node.selected, .edge.selected {opacity: 1;}
.edge:hover path { stroke: red; }
.edge:hover polygon { stroke: red; fill: red; }
]]></style>
<script type="application/ecmascript" xlink:href="../../svg.min.js"/>
<svg id="graph" class="graph">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 52.5)">
<title>math::ncr_modulo_p::utils::modInverse</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title=" ">
<polygon fill="#999999" stroke="#666666" points="104.5,-30.5 0,-30.5 0,0 104.5,0 104.5,-30.5"/>
<text text-anchor="start" x="8" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="52.25" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::utils::modInverse</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node1 -->
<g id="edge4_Node000001_Node000001" class="edge">
<title>Node1&#45;&gt;Node1</title>
<g id="a_edge4_Node000001_Node000001"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M27.35,-30.99C22.27,-40.06 30.57,-48.5 52.25,-48.5 64.11,-48.5 71.96,-45.97 75.81,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="79.26,-42.83 76.97,-32.49 72.31,-42.01 79.26,-42.83"/>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../de/dab/ncr__modulo__p_8cpp.html#a9010ad5669d31449c3bf3271ab5ebc86" target="_top" xlink:title="finds the values x and y such that a*x + b*y = gcd(a,b)">
<polygon fill="white" stroke="#666666" points="245,-30.5 140.5,-30.5 140.5,0 245,0 245,-30.5"/>
<text text-anchor="start" x="148.5" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="192.75" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::utils::gcdExtended</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M104.82,-15.25C112.66,-15.25 120.83,-15.25 128.88,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="128.62,-18.75 138.62,-15.25 128.62,-11.75 128.62,-18.75"/>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node2 -->
<g id="edge3_Node000002_Node000002" class="edge">
<title>Node2&#45;&gt;Node2</title>
<g id="a_edge3_Node000002_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M174.3,-30.99C170.53,-40.06 176.68,-48.5 192.75,-48.5 201.54,-48.5 207.36,-45.97 210.21,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="213.68,-42.76 211.07,-32.49 206.7,-42.15 213.68,-42.76"/>
</a>
</g>
</g>
<!-- Node3 -->
<g id="Node000003" class="node">
<title>Node3</title>
<g id="a_Node000003"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="312.75,-24.88 281,-24.88 281,-5.63 312.75,-5.63 312.75,-24.88"/>
<text text-anchor="middle" x="296.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node3 -->
<g id="edge2_Node000002_Node000003" class="edge">
<title>Node2&#45;&gt;Node3</title>
<g id="a_edge2_Node000002_Node000003"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M245.41,-15.25C253.65,-15.25 261.87,-15.25 269.21,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="269.07,-18.75 279.07,-15.25 269.07,-11.75 269.07,-18.75"/>
</a>
</g>
</g>
</g>
</svg>
</svg>
<style type='text/css'>
<![CDATA[
[data-mouse-over-selected='false'] { opacity: 0.7; }
[data-mouse-over-selected='true'] { opacity: 1.0; }
]]>
</style>
<script type="application/ecmascript"><![CDATA[
document.addEventListener('DOMContentLoaded', (event) => {
highlightEdges();
highlightAdjacentNodes();
});
]]></script>
</svg>

After

Width:  |  Height:  |  Size: 4.4 KiB

View File

@@ -0,0 +1,77 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: math::ncr_modulo_p::utils::modInverse Pages: 1 -->
<svg width="321pt" height="57pt"
viewBox="0.00 0.00 320.75 56.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 52.5)">
<title>math::ncr_modulo_p::utils::modInverse</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title=" ">
<polygon fill="#999999" stroke="#666666" points="104.5,-30.5 0,-30.5 0,0 104.5,0 104.5,-30.5"/>
<text text-anchor="start" x="8" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="52.25" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::utils::modInverse</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node1 -->
<g id="edge4_Node000001_Node000001" class="edge">
<title>Node1&#45;&gt;Node1</title>
<g id="a_edge4_Node000001_Node000001"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M27.35,-30.99C22.27,-40.06 30.57,-48.5 52.25,-48.5 64.11,-48.5 71.96,-45.97 75.81,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="79.26,-42.83 76.97,-32.49 72.31,-42.01 79.26,-42.83"/>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../de/dab/ncr__modulo__p_8cpp.html#a9010ad5669d31449c3bf3271ab5ebc86" target="_top" xlink:title="finds the values x and y such that a*x + b*y = gcd(a,b)">
<polygon fill="white" stroke="#666666" points="245,-30.5 140.5,-30.5 140.5,0 245,0 245,-30.5"/>
<text text-anchor="start" x="148.5" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="192.75" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::utils::gcdExtended</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M104.82,-15.25C112.66,-15.25 120.83,-15.25 128.88,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="128.62,-18.75 138.62,-15.25 128.62,-11.75 128.62,-18.75"/>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node2 -->
<g id="edge3_Node000002_Node000002" class="edge">
<title>Node2&#45;&gt;Node2</title>
<g id="a_edge3_Node000002_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M174.3,-30.99C170.53,-40.06 176.68,-48.5 192.75,-48.5 201.54,-48.5 207.36,-45.97 210.21,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="213.68,-42.76 211.07,-32.49 206.7,-42.15 213.68,-42.76"/>
</a>
</g>
</g>
<!-- Node3 -->
<g id="Node000003" class="node">
<title>Node3</title>
<g id="a_Node000003"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="312.75,-24.88 281,-24.88 281,-5.63 312.75,-5.63 312.75,-24.88"/>
<text text-anchor="middle" x="296.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node3 -->
<g id="edge2_Node000002_Node000003" class="edge">
<title>Node2&#45;&gt;Node3</title>
<g id="a_edge2_Node000002_Node000003"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M245.41,-15.25C253.65,-15.25 261.87,-15.25 269.21,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="269.07,-18.75 279.07,-15.25 269.07,-11.75 269.07,-18.75"/>
</a>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@@ -0,0 +1,6 @@
<map id="math::ncr_modulo_p::utils::gcdExtended" name="math::ncr_modulo_p::utils::gcdExtended">
<area shape="rect" id="Node000001" title="finds the values x and y such that a*x + b*y = gcd(a,b)" alt="" coords="5,29,145,70"/>
<area shape="poly" id="edge2_Node000001_Node000001" title=" " alt="" coords="48,29,46,20,51,11,61,5,75,3,91,5,100,12,97,16,89,10,75,8,62,10,55,14,52,20,53,28"/>
<area shape="rect" id="Node000002" href="$d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" title=" " alt="" coords="193,37,235,62"/>
<area shape="poly" id="edge1_Node000001_Node000002" title=" " alt="" coords="145,47,177,47,177,52,145,52"/>
</map>

View File

@@ -0,0 +1 @@
ba3da75994498c1bdb1f6cc36a33fadf

View File

@@ -0,0 +1,75 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: math::ncr_modulo_p::utils::gcdExtended Pages: 1 -->
<svg width="180pt" height="57pt"
viewBox="0.00 0.00 180.25 56.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<svg id="main" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve">
<style type="text/css"><![CDATA[
.node, .edge {opacity: 0.7;}
.node.selected, .edge.selected {opacity: 1;}
.edge:hover path { stroke: red; }
.edge:hover polygon { stroke: red; fill: red; }
]]></style>
<script type="application/ecmascript" xlink:href="../../svg.min.js"/>
<svg id="graph" class="graph">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 52.5)">
<title>math::ncr_modulo_p::utils::gcdExtended</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="finds the values x and y such that a*x + b*y = gcd(a,b)">
<polygon fill="#999999" stroke="#666666" points="104.5,-30.5 0,-30.5 0,0 104.5,0 104.5,-30.5"/>
<text text-anchor="start" x="8" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="52.25" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::utils::gcdExtended</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node1 -->
<g id="edge2_Node000001_Node000001" class="edge">
<title>Node1&#45;&gt;Node1</title>
<g id="a_edge2_Node000001_Node000001"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M33.8,-30.99C30.03,-40.06 36.18,-48.5 52.25,-48.5 61.04,-48.5 66.86,-45.97 69.71,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="73.18,-42.76 70.57,-32.49 66.2,-42.15 73.18,-42.76"/>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="172.25,-24.88 140.5,-24.88 140.5,-5.63 172.25,-5.63 172.25,-24.88"/>
<text text-anchor="middle" x="156.38" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M104.91,-15.25C113.15,-15.25 121.37,-15.25 128.71,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="128.57,-18.75 138.57,-15.25 128.57,-11.75 128.57,-18.75"/>
</a>
</g>
</g>
</g>
</svg>
</svg>
<style type='text/css'>
<![CDATA[
[data-mouse-over-selected='false'] { opacity: 0.7; }
[data-mouse-over-selected='true'] { opacity: 1.0; }
]]>
</style>
<script type="application/ecmascript"><![CDATA[
document.addEventListener('DOMContentLoaded', (event) => {
highlightEdges();
highlightAdjacentNodes();
});
]]></script>
</svg>

After

Width:  |  Height:  |  Size: 3.1 KiB

View File

@@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: math::ncr_modulo_p::utils::gcdExtended Pages: 1 -->
<svg width="180pt" height="57pt"
viewBox="0.00 0.00 180.25 56.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 52.5)">
<title>math::ncr_modulo_p::utils::gcdExtended</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="finds the values x and y such that a*x + b*y = gcd(a,b)">
<polygon fill="#999999" stroke="#666666" points="104.5,-30.5 0,-30.5 0,0 104.5,0 104.5,-30.5"/>
<text text-anchor="start" x="8" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="52.25" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::utils::gcdExtended</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node1 -->
<g id="edge2_Node000001_Node000001" class="edge">
<title>Node1&#45;&gt;Node1</title>
<g id="a_edge2_Node000001_Node000001"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M33.8,-30.99C30.03,-40.06 36.18,-48.5 52.25,-48.5 61.04,-48.5 66.86,-45.97 69.71,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="73.18,-42.76 70.57,-32.49 66.2,-42.15 73.18,-42.76"/>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="172.25,-24.88 140.5,-24.88 140.5,-5.63 172.25,-5.63 172.25,-24.88"/>
<text text-anchor="middle" x="156.38" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M104.91,-15.25C113.15,-15.25 121.37,-15.25 128.71,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="128.57,-18.75 138.57,-15.25 128.57,-11.75 128.57,-18.75"/>
</a>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

@@ -1,12 +0,0 @@
<map id="main" name="main">
<area shape="rect" id="Node000001" title="Main function." alt="" coords="5,37,55,62"/>
<area shape="rect" id="Node000002" href="$d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08" title=" " alt="" coords="103,29,242,70"/>
<area shape="poly" id="edge1_Node000001_Node000002" title=" " alt="" coords="55,47,87,47,87,52,55,52"/>
<area shape="rect" id="Node000003" href="$d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a0431ec5c876e1154d8e1e5f89e1ab34a" title=" " alt="" coords="290,29,476,70"/>
<area shape="poly" id="edge2_Node000002_Node000003" title=" " alt="" coords="242,47,274,47,274,52,242,52"/>
<area shape="rect" id="Node000004" href="$d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#afde201f4687740454302c444f507a926" title=" " alt="" coords="524,29,719,70"/>
<area shape="poly" id="edge3_Node000003_Node000004" title=" " alt="" coords="477,47,508,47,508,52,477,52"/>
<area shape="poly" id="edge5_Node000004_Node000004" title=" " alt="" coords="589,29,588,19,593,11,604,5,622,3,640,5,651,11,648,16,638,10,621,8,606,10,597,14,593,20,595,28"/>
<area shape="rect" id="Node000005" href="$d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" title=" " alt="" coords="767,37,809,62"/>
<area shape="poly" id="edge4_Node000004_Node000005" title=" " alt="" coords="719,47,751,47,751,52,719,52"/>
</map>

View File

@@ -1 +0,0 @@
afda47681566cb929ac8335b91ba8353

View File

@@ -1,188 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: main Pages: 1 -->
<!--zoomable 57 -->
<svg id="main" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" onload="init(evt)">
<style type="text/css"><![CDATA[
.node, .edge {opacity: 0.7;}
.node.selected, .edge.selected {opacity: 1;}
.edge:hover path { stroke: red; }
.edge:hover polygon { stroke: red; fill: red; }
]]></style>
<defs>
<circle id="rim" cx="0" cy="0" r="7"/>
<circle id="rim2" cx="0" cy="0" r="3.5"/>
<g id="zoomPlus">
<use xlink:href="#rim" fill="#404040"><set attributeName="fill" to="#808080" begin="zoomplus.mouseover" end="zoomplus.mouseout"/></use>
<path d="M-4,0h8M0,-4v8" fill="none" stroke="white" stroke-width="1.5" pointer-events="none"/>
</g>
<g id="zoomMin">
<use xlink:href="#rim" fill="#404040"><set attributeName="fill" to="#808080" begin="zoomminus.mouseover" end="zoomminus.mouseout"/></use>
<path d="M-4,0h8" fill="none" stroke="white" stroke-width="1.5" pointer-events="none"/>
</g>
<g id="arrowUp" transform="translate(30 24)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="arrowRight" transform="rotate(90) translate(36 -43)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="arrowDown" transform="rotate(180) translate(-30 -48)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="arrowLeft" transform="rotate(270) translate(-36 17)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="resetDef">
<use xlink:href="#rim2" fill="#404040"><set attributeName="fill" to="#808080" begin="reset.mouseover" end="reset.mouseout"/></use>
</g>
</defs>
<script type="application/ecmascript">
var viewWidth = 611;
var viewHeight = 57;
var sectionId = 'dynsection-1';
</script>
<script type="application/ecmascript" xlink:href="../../svg.min.js"/>
<svg id="graph" class="graph">
<g id="viewport">
<title>main</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="Main function.">
<polygon fill="#999999" stroke="#666666" points="37,-24.88 0,-24.88 0,-5.63 37,-5.63 37,-24.88"/>
<text text-anchor="middle" x="18.5" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">main</text>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="177.5,-30.5 73,-30.5 73,0 177.5,0 177.5,-30.5"/>
<text text-anchor="start" x="81" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="125.25" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::ncr</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M37.27,-15.25C44.25,-15.25 52.71,-15.25 61.58,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="61.44,-18.75 71.44,-15.25 61.44,-11.75 61.44,-18.75"/>
</a>
</g>
</g>
<!-- Node3 -->
<g id="Node000003" class="node">
<title>Node3</title>
<g id="a_Node000003"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a0431ec5c876e1154d8e1e5f89e1ab34a" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="353.25,-30.5 213.5,-30.5 213.5,0 353.25,0 353.25,-30.5"/>
<text text-anchor="start" x="221.5" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="283.38" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::modInverse</text>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node3 -->
<g id="edge2_Node000002_Node000003" class="edge">
<title>Node2&#45;&gt;Node3</title>
<g id="a_edge2_Node000002_Node000003"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M177.8,-15.25C185.47,-15.25 193.52,-15.25 201.62,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="201.53,-18.75 211.53,-15.25 201.53,-11.75 201.53,-18.75"/>
</a>
</g>
</g>
<!-- Node4 -->
<g id="Node000004" class="node">
<title>Node4</title>
<g id="a_Node000004"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#afde201f4687740454302c444f507a926" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="535,-30.5 389.25,-30.5 389.25,0 535,0 535,-30.5"/>
<text text-anchor="start" x="397.25" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="462.12" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::gcdExtended</text>
</a>
</g>
</g>
<!-- Node3&#45;&gt;Node4 -->
<g id="edge3_Node000003_Node000004" class="edge">
<title>Node3&#45;&gt;Node4</title>
<g id="a_edge3_Node000003_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M353.72,-15.25C361.46,-15.25 369.39,-15.25 377.28,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="377.26,-18.75 387.26,-15.25 377.26,-11.75 377.26,-18.75"/>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node4 -->
<g id="edge5_Node000004_Node000004" class="edge">
<title>Node4&#45;&gt;Node4</title>
<g id="a_edge5_Node000004_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M440.02,-30.99C435.51,-40.06 442.88,-48.5 462.12,-48.5 472.65,-48.5 479.63,-45.97 483.05,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="486.5,-42.8 484.07,-32.49 479.54,-42.07 486.5,-42.8"/>
</a>
</g>
</g>
<!-- Node5 -->
<g id="Node000005" class="node">
<title>Node5</title>
<g id="a_Node000005"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="602.75,-24.88 571,-24.88 571,-5.63 602.75,-5.63 602.75,-24.88"/>
<text text-anchor="middle" x="586.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node5 -->
<g id="edge4_Node000004_Node000005" class="edge">
<title>Node4&#45;&gt;Node5</title>
<g id="a_edge4_Node000004_Node000005"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M535.24,-15.25C543.69,-15.25 551.87,-15.25 559.09,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="559.06,-18.75 569.06,-15.25 559.06,-11.75 559.06,-18.75"/>
</a>
</g>
</g>
</g>
</svg>
<g id="navigator" transform="translate(0 0)" fill="#404254">
<rect fill="#f2f5e9" fill-opacity="0.5" stroke="#606060" stroke-width=".5" x="0" y="0" width="60" height="60"/>
<use id="zoomplus" xlink:href="#zoomPlus" x="17" y="9" onmousedown="handleZoom(evt,'in')"/>
<use id="zoomminus" xlink:href="#zoomMin" x="42" y="9" onmousedown="handleZoom(evt,'out')"/>
<use id="reset" xlink:href="#resetDef" x="30" y="36" onmousedown="handleReset()"/>
<use id="arrowup" xlink:href="#arrowUp" x="0" y="0" onmousedown="handlePan(0,-1)"/>
<use id="arrowright" xlink:href="#arrowRight" x="0" y="0" onmousedown="handlePan(1,0)"/>
<use id="arrowdown" xlink:href="#arrowDown" x="0" y="0" onmousedown="handlePan(0,1)"/>
<use id="arrowleft" xlink:href="#arrowLeft" x="0" y="0" onmousedown="handlePan(-1,0)"/>
</g>
<svg viewBox="0 0 15 15" width="100%" height="30px" preserveAspectRatio="xMaxYMin meet">
<g id="arrow_out" transform="scale(0.3 0.3)">
<a xlink:href="ncr__modulo__p_8cpp_ae66f6b31b5ad750f1fe042a706a4e3d4_cgraph_org.svg" target="_base">
<rect id="button" ry="5" rx="5" y="6" x="6" height="38" width="38"
fill="#f2f5e9" fill-opacity="0.5" stroke="#606060" stroke-width="1.0"/>
<path id="arrow"
d="M 11.500037,31.436501 C 11.940474,20.09759 22.043105,11.32322 32.158766,21.979434 L 37.068811,17.246167 C 37.068811,17.246167 37.088388,32 37.088388,32 L 22.160133,31.978069 C 22.160133,31.978069 26.997745,27.140456 26.997745,27.140456 C 18.528582,18.264221 13.291696,25.230495 11.500037,31.436501 z"
style="fill:#404040;"/>
</a>
</g>
</svg>
<style type='text/css'>
<![CDATA[
[data-mouse-over-selected='false'] { opacity: 0.7; }
[data-mouse-over-selected='true'] { opacity: 1.0; }
]]>
</style>
<script type="application/ecmascript"><![CDATA[
document.addEventListener('DOMContentLoaded', (event) => {
highlightEdges();
highlightAdjacentNodes();
});
]]></script>
</svg>

Before

Width:  |  Height:  |  Size: 8.9 KiB

View File

@@ -1,105 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: main Pages: 1 -->
<svg width="611pt" height="57pt"
viewBox="0.00 0.00 610.75 56.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 52.5)">
<title>main</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="Main function.">
<polygon fill="#999999" stroke="#666666" points="37,-24.88 0,-24.88 0,-5.63 37,-5.63 37,-24.88"/>
<text text-anchor="middle" x="18.5" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">main</text>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="177.5,-30.5 73,-30.5 73,0 177.5,0 177.5,-30.5"/>
<text text-anchor="start" x="81" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="125.25" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::ncr</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M37.27,-15.25C44.25,-15.25 52.71,-15.25 61.58,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="61.44,-18.75 71.44,-15.25 61.44,-11.75 61.44,-18.75"/>
</a>
</g>
</g>
<!-- Node3 -->
<g id="Node000003" class="node">
<title>Node3</title>
<g id="a_Node000003"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a0431ec5c876e1154d8e1e5f89e1ab34a" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="353.25,-30.5 213.5,-30.5 213.5,0 353.25,0 353.25,-30.5"/>
<text text-anchor="start" x="221.5" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="283.38" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::modInverse</text>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node3 -->
<g id="edge2_Node000002_Node000003" class="edge">
<title>Node2&#45;&gt;Node3</title>
<g id="a_edge2_Node000002_Node000003"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M177.8,-15.25C185.47,-15.25 193.52,-15.25 201.62,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="201.53,-18.75 211.53,-15.25 201.53,-11.75 201.53,-18.75"/>
</a>
</g>
</g>
<!-- Node4 -->
<g id="Node000004" class="node">
<title>Node4</title>
<g id="a_Node000004"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#afde201f4687740454302c444f507a926" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="535,-30.5 389.25,-30.5 389.25,0 535,0 535,-30.5"/>
<text text-anchor="start" x="397.25" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="462.12" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::gcdExtended</text>
</a>
</g>
</g>
<!-- Node3&#45;&gt;Node4 -->
<g id="edge3_Node000003_Node000004" class="edge">
<title>Node3&#45;&gt;Node4</title>
<g id="a_edge3_Node000003_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M353.72,-15.25C361.46,-15.25 369.39,-15.25 377.28,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="377.26,-18.75 387.26,-15.25 377.26,-11.75 377.26,-18.75"/>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node4 -->
<g id="edge5_Node000004_Node000004" class="edge">
<title>Node4&#45;&gt;Node4</title>
<g id="a_edge5_Node000004_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M440.02,-30.99C435.51,-40.06 442.88,-48.5 462.12,-48.5 472.65,-48.5 479.63,-45.97 483.05,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="486.5,-42.8 484.07,-32.49 479.54,-42.07 486.5,-42.8"/>
</a>
</g>
</g>
<!-- Node5 -->
<g id="Node000005" class="node">
<title>Node5</title>
<g id="a_Node000005"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="602.75,-24.88 571,-24.88 571,-5.63 602.75,-5.63 602.75,-24.88"/>
<text text-anchor="middle" x="586.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node5 -->
<g id="edge4_Node000004_Node000005" class="edge">
<title>Node4&#45;&gt;Node5</title>
<g id="a_edge4_Node000004_Node000005"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M535.24,-15.25C543.69,-15.25 551.87,-15.25 559.09,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="559.06,-18.75 569.06,-15.25 559.06,-11.75 559.06,-18.75"/>
</a>
</g>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 5.0 KiB

View File

@@ -1,12 +0,0 @@
<map id="tests" name="tests">
<area shape="rect" id="Node000001" title="Test implementations." alt="" coords="5,37,56,62"/>
<area shape="rect" id="Node000002" href="$d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08" title=" " alt="" coords="104,29,243,70"/>
<area shape="poly" id="edge1_Node000001_Node000002" title=" " alt="" coords="56,47,88,47,88,52,56,52"/>
<area shape="rect" id="Node000003" href="$d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a0431ec5c876e1154d8e1e5f89e1ab34a" title=" " alt="" coords="291,29,477,70"/>
<area shape="poly" id="edge2_Node000002_Node000003" title=" " alt="" coords="243,47,275,47,275,52,243,52"/>
<area shape="rect" id="Node000004" href="$d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#afde201f4687740454302c444f507a926" title=" " alt="" coords="525,29,720,70"/>
<area shape="poly" id="edge3_Node000003_Node000004" title=" " alt="" coords="478,47,509,47,509,52,478,52"/>
<area shape="poly" id="edge5_Node000004_Node000004" title=" " alt="" coords="590,29,589,19,594,11,605,5,623,3,641,5,652,11,649,16,639,10,622,8,607,10,598,14,594,20,596,28"/>
<area shape="rect" id="Node000005" href="$d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" title=" " alt="" coords="768,37,810,62"/>
<area shape="poly" id="edge4_Node000004_Node000005" title=" " alt="" coords="720,47,752,47,752,52,720,52"/>
</map>

View File

@@ -1 +0,0 @@
2cc016bbb48cae071e8a751a9517bc3b

View File

@@ -1,188 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: tests Pages: 1 -->
<!--zoomable 57 -->
<svg id="main" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" onload="init(evt)">
<style type="text/css"><![CDATA[
.node, .edge {opacity: 0.7;}
.node.selected, .edge.selected {opacity: 1;}
.edge:hover path { stroke: red; }
.edge:hover polygon { stroke: red; fill: red; }
]]></style>
<defs>
<circle id="rim" cx="0" cy="0" r="7"/>
<circle id="rim2" cx="0" cy="0" r="3.5"/>
<g id="zoomPlus">
<use xlink:href="#rim" fill="#404040"><set attributeName="fill" to="#808080" begin="zoomplus.mouseover" end="zoomplus.mouseout"/></use>
<path d="M-4,0h8M0,-4v8" fill="none" stroke="white" stroke-width="1.5" pointer-events="none"/>
</g>
<g id="zoomMin">
<use xlink:href="#rim" fill="#404040"><set attributeName="fill" to="#808080" begin="zoomminus.mouseover" end="zoomminus.mouseout"/></use>
<path d="M-4,0h8" fill="none" stroke="white" stroke-width="1.5" pointer-events="none"/>
</g>
<g id="arrowUp" transform="translate(30 24)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="arrowRight" transform="rotate(90) translate(36 -43)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="arrowDown" transform="rotate(180) translate(-30 -48)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="arrowLeft" transform="rotate(270) translate(-36 17)">
<use xlink:href="#rim"/>
<path pointer-events="none" fill="none" stroke="white" stroke-width="1.5" d="M0,-3.0v7 M-2.5,-0.5L0,-3.0L2.5,-0.5"/>
</g>
<g id="resetDef">
<use xlink:href="#rim2" fill="#404040"><set attributeName="fill" to="#808080" begin="reset.mouseover" end="reset.mouseout"/></use>
</g>
</defs>
<script type="application/ecmascript">
var viewWidth = 612;
var viewHeight = 57;
var sectionId = 'dynsection-2';
</script>
<script type="application/ecmascript" xlink:href="../../svg.min.js"/>
<svg id="graph" class="graph">
<g id="viewport">
<title>tests</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="Test implementations.">
<polygon fill="#999999" stroke="#666666" points="37.75,-24.88 0,-24.88 0,-5.63 37.75,-5.63 37.75,-24.88"/>
<text text-anchor="middle" x="18.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">tests</text>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="178.25,-30.5 73.75,-30.5 73.75,0 178.25,0 178.25,-30.5"/>
<text text-anchor="start" x="81.75" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="126" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::ncr</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M38.19,-15.25C45.14,-15.25 53.5,-15.25 62.25,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="61.96,-18.75 71.96,-15.25 61.96,-11.75 61.96,-18.75"/>
</a>
</g>
</g>
<!-- Node3 -->
<g id="Node000003" class="node">
<title>Node3</title>
<g id="a_Node000003"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a0431ec5c876e1154d8e1e5f89e1ab34a" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="354,-30.5 214.25,-30.5 214.25,0 354,0 354,-30.5"/>
<text text-anchor="start" x="222.25" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="284.12" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::modInverse</text>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node3 -->
<g id="edge2_Node000002_Node000003" class="edge">
<title>Node2&#45;&gt;Node3</title>
<g id="a_edge2_Node000002_Node000003"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M178.55,-15.25C186.22,-15.25 194.27,-15.25 202.37,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="202.28,-18.75 212.28,-15.25 202.28,-11.75 202.28,-18.75"/>
</a>
</g>
</g>
<!-- Node4 -->
<g id="Node000004" class="node">
<title>Node4</title>
<g id="a_Node000004"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#afde201f4687740454302c444f507a926" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="535.75,-30.5 390,-30.5 390,0 535.75,0 535.75,-30.5"/>
<text text-anchor="start" x="398" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="462.88" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::gcdExtended</text>
</a>
</g>
</g>
<!-- Node3&#45;&gt;Node4 -->
<g id="edge3_Node000003_Node000004" class="edge">
<title>Node3&#45;&gt;Node4</title>
<g id="a_edge3_Node000003_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M354.47,-15.25C362.21,-15.25 370.14,-15.25 378.03,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="378.01,-18.75 388.01,-15.25 378.01,-11.75 378.01,-18.75"/>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node4 -->
<g id="edge5_Node000004_Node000004" class="edge">
<title>Node4&#45;&gt;Node4</title>
<g id="a_edge5_Node000004_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M440.77,-30.99C436.26,-40.06 443.63,-48.5 462.88,-48.5 473.4,-48.5 480.38,-45.97 483.8,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="487.25,-42.8 484.82,-32.49 480.29,-42.07 487.25,-42.8"/>
</a>
</g>
</g>
<!-- Node5 -->
<g id="Node000005" class="node">
<title>Node5</title>
<g id="a_Node000005"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="603.5,-24.88 571.75,-24.88 571.75,-5.63 603.5,-5.63 603.5,-24.88"/>
<text text-anchor="middle" x="587.62" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node5 -->
<g id="edge4_Node000004_Node000005" class="edge">
<title>Node4&#45;&gt;Node5</title>
<g id="a_edge4_Node000004_Node000005"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M535.99,-15.25C544.44,-15.25 552.62,-15.25 559.84,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="559.81,-18.75 569.81,-15.25 559.81,-11.75 559.81,-18.75"/>
</a>
</g>
</g>
</g>
</svg>
<g id="navigator" transform="translate(0 0)" fill="#404254">
<rect fill="#f2f5e9" fill-opacity="0.5" stroke="#606060" stroke-width=".5" x="0" y="0" width="60" height="60"/>
<use id="zoomplus" xlink:href="#zoomPlus" x="17" y="9" onmousedown="handleZoom(evt,'in')"/>
<use id="zoomminus" xlink:href="#zoomMin" x="42" y="9" onmousedown="handleZoom(evt,'out')"/>
<use id="reset" xlink:href="#resetDef" x="30" y="36" onmousedown="handleReset()"/>
<use id="arrowup" xlink:href="#arrowUp" x="0" y="0" onmousedown="handlePan(0,-1)"/>
<use id="arrowright" xlink:href="#arrowRight" x="0" y="0" onmousedown="handlePan(1,0)"/>
<use id="arrowdown" xlink:href="#arrowDown" x="0" y="0" onmousedown="handlePan(0,1)"/>
<use id="arrowleft" xlink:href="#arrowLeft" x="0" y="0" onmousedown="handlePan(-1,0)"/>
</g>
<svg viewBox="0 0 15 15" width="100%" height="30px" preserveAspectRatio="xMaxYMin meet">
<g id="arrow_out" transform="scale(0.3 0.3)">
<a xlink:href="ncr__modulo__p_8cpp_af0a3e6827f41c151e47451f5ff98b1f1_cgraph_org.svg" target="_base">
<rect id="button" ry="5" rx="5" y="6" x="6" height="38" width="38"
fill="#f2f5e9" fill-opacity="0.5" stroke="#606060" stroke-width="1.0"/>
<path id="arrow"
d="M 11.500037,31.436501 C 11.940474,20.09759 22.043105,11.32322 32.158766,21.979434 L 37.068811,17.246167 C 37.068811,17.246167 37.088388,32 37.088388,32 L 22.160133,31.978069 C 22.160133,31.978069 26.997745,27.140456 26.997745,27.140456 C 18.528582,18.264221 13.291696,25.230495 11.500037,31.436501 z"
style="fill:#404040;"/>
</a>
</g>
</svg>
<style type='text/css'>
<![CDATA[
[data-mouse-over-selected='false'] { opacity: 0.7; }
[data-mouse-over-selected='true'] { opacity: 1.0; }
]]>
</style>
<script type="application/ecmascript"><![CDATA[
document.addEventListener('DOMContentLoaded', (event) => {
highlightEdges();
highlightAdjacentNodes();
});
]]></script>
</svg>

Before

Width:  |  Height:  |  Size: 8.9 KiB

View File

@@ -1,105 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 12.1.0 (20240811.2233)
-->
<!-- Title: tests Pages: 1 -->
<svg width="612pt" height="57pt"
viewBox="0.00 0.00 611.50 56.50" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 52.5)">
<title>tests</title>
<!-- Node1 -->
<g id="Node000001" class="node">
<title>Node1</title>
<g id="a_Node000001"><a xlink:title="Test implementations.">
<polygon fill="#999999" stroke="#666666" points="37.75,-24.88 0,-24.88 0,-5.63 37.75,-5.63 37.75,-24.88"/>
<text text-anchor="middle" x="18.88" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">tests</text>
</a>
</g>
</g>
<!-- Node2 -->
<g id="Node000002" class="node">
<title>Node2</title>
<g id="a_Node000002"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a6b95277f5f527beacc8d0f3bc91fcd08" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="178.25,-30.5 73.75,-30.5 73.75,0 178.25,0 178.25,-30.5"/>
<text text-anchor="start" x="81.75" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="126" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::ncr</text>
</a>
</g>
</g>
<!-- Node1&#45;&gt;Node2 -->
<g id="edge1_Node000001_Node000002" class="edge">
<title>Node1&#45;&gt;Node2</title>
<g id="a_edge1_Node000001_Node000002"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M38.19,-15.25C45.14,-15.25 53.5,-15.25 62.25,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="61.96,-18.75 71.96,-15.25 61.96,-11.75 61.96,-18.75"/>
</a>
</g>
</g>
<!-- Node3 -->
<g id="Node000003" class="node">
<title>Node3</title>
<g id="a_Node000003"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#a0431ec5c876e1154d8e1e5f89e1ab34a" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="354,-30.5 214.25,-30.5 214.25,0 354,0 354,-30.5"/>
<text text-anchor="start" x="222.25" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="284.12" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::modInverse</text>
</a>
</g>
</g>
<!-- Node2&#45;&gt;Node3 -->
<g id="edge2_Node000002_Node000003" class="edge">
<title>Node2&#45;&gt;Node3</title>
<g id="a_edge2_Node000002_Node000003"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M178.55,-15.25C186.22,-15.25 194.27,-15.25 202.37,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="202.28,-18.75 212.28,-15.25 202.28,-11.75 202.28,-18.75"/>
</a>
</g>
</g>
<!-- Node4 -->
<g id="Node000004" class="node">
<title>Node4</title>
<g id="a_Node000004"><a xlink:href="../../d6/dc1/classmath_1_1ncr__modulo__p_1_1_n_c_r_modulo_p.html#afde201f4687740454302c444f507a926" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="535.75,-30.5 390,-30.5 390,0 535.75,0 535.75,-30.5"/>
<text text-anchor="start" x="398" y="-17" font-family="Helvetica,sans-Serif" font-size="10.00">math::ncr_modulo_p</text>
<text text-anchor="middle" x="462.88" y="-5.75" font-family="Helvetica,sans-Serif" font-size="10.00">::NCRModuloP::gcdExtended</text>
</a>
</g>
</g>
<!-- Node3&#45;&gt;Node4 -->
<g id="edge3_Node000003_Node000004" class="edge">
<title>Node3&#45;&gt;Node4</title>
<g id="a_edge3_Node000003_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M354.47,-15.25C362.21,-15.25 370.14,-15.25 378.03,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="378.01,-18.75 388.01,-15.25 378.01,-11.75 378.01,-18.75"/>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node4 -->
<g id="edge5_Node000004_Node000004" class="edge">
<title>Node4&#45;&gt;Node4</title>
<g id="a_edge5_Node000004_Node000004"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M440.77,-30.99C436.26,-40.06 443.63,-48.5 462.88,-48.5 473.4,-48.5 480.38,-45.97 483.8,-42.2"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="487.25,-42.8 484.82,-32.49 480.29,-42.07 487.25,-42.8"/>
</a>
</g>
</g>
<!-- Node5 -->
<g id="Node000005" class="node">
<title>Node5</title>
<g id="a_Node000005"><a xlink:href="../../d4/da0/gcd__iterative__euclidean_8cpp.html#ae48807fa2b7000afae599e67f327545e" target="_top" xlink:title=" ">
<polygon fill="white" stroke="#666666" points="603.5,-24.88 571.75,-24.88 571.75,-5.63 603.5,-5.63 603.5,-24.88"/>
<text text-anchor="middle" x="587.62" y="-11.38" font-family="Helvetica,sans-Serif" font-size="10.00">gcd</text>
</a>
</g>
</g>
<!-- Node4&#45;&gt;Node5 -->
<g id="edge4_Node000004_Node000005" class="edge">
<title>Node4&#45;&gt;Node5</title>
<g id="a_edge4_Node000004_Node000005"><a xlink:title=" ">
<path fill="none" stroke="#63b8ff" d="M535.99,-15.25C544.44,-15.25 552.62,-15.25 559.84,-15.25"/>
<polygon fill="#63b8ff" stroke="#63b8ff" points="559.81,-18.75 569.81,-15.25 559.81,-11.75 559.81,-18.75"/>
</a>
</g>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 5.0 KiB