Update docs

This commit is contained in:
2023-10-14 03:11:43 +02:00
parent c4aa6f2179
commit 22c8b9707d
105 changed files with 3315 additions and 1025 deletions

View File

@@ -124,6 +124,7 @@ Macros</h2></td></tr>
<tr class="memdesc:a73d4f21ad937dbc50a0c0538c78fd4f9"><td class="mdescLeft">&#160;</td><td class="mdescRight">A prettier assertion function. <br /></td></tr>
<tr class="separator:a73d4f21ad937dbc50a0c0538c78fd4f9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a60dca3177fb9cb5256609adc7af55168"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168">__METHOD_NAME__</a>&#160;&#160;&#160;methodName(__PRETTY_FUNCTION__)</td></tr>
<tr class="memdesc:a60dca3177fb9cb5256609adc7af55168"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the name of the current method/function. <br /></td></tr>
<tr class="separator:a60dca3177fb9cb5256609adc7af55168"><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>
@@ -140,6 +141,9 @@ Functions</h2></td></tr>
<tr class="memitem:a0c95c4791692b06f8811905a76dbd772"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="utils_8hpp.html#a0c95c4791692b06f8811905a76dbd772">arma_vector_close_to</a> (arma::vec &amp;a, arma::vec &amp;b, double tol=1e-8)</td></tr>
<tr class="memdesc:a0c95c4791692b06f8811905a76dbd772"><td class="mdescLeft">&#160;</td><td class="mdescRight">Test if two armadillo vectors are close to each other. <br /></td></tr>
<tr class="separator:a0c95c4791692b06f8811905a76dbd772"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6fdd7217b750aff5b6295ece7cbdeffa"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a> (std::string path, int mode=0777)</td></tr>
<tr class="memdesc:a6fdd7217b750aff5b6295ece7cbdeffa"><td class="mdescLeft">&#160;</td><td class="mdescRight">Make path given. <br /></td></tr>
<tr class="separator:a6fdd7217b750aff5b6295ece7cbdeffa"><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>Function prototypes and macros that are useful. </p>
@@ -148,7 +152,7 @@ Functions</h2></td></tr>
Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
<dl class="section version"><dt>Version</dt><dd>1.0</dd></dl>
<p>These utility function are mainly for convenience and aren't directly related to the project.</p>
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000004">Bug:</a></b></dt><dd>No known bugs </dd></dl>
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000005">Bug:</a></b></dt><dd>No known bugs </dd></dl>
<p class="definition">Definition in file <a class="el" href="utils_8hpp_source.html">utils.hpp</a>.</p>
</div><h2 class="groupheader">Macro Definition Documentation</h2>
@@ -164,7 +168,9 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="utils_8hpp_source.html#l00048">48</a> of file <a class="el" href="utils_8hpp_source.html">utils.hpp</a>.</p>
<p>Get the name of the current method/function. </p>
<p class="definition">Definition at line <a class="el" href="utils_8hpp_source.html#l00051">51</a> of file <a class="el" href="utils_8hpp_source.html">utils.hpp</a>.</p>
</div>
</div>
@@ -193,9 +199,10 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</tr>
</table>
</div><div class="memdoc">
<b>Value:</b><div class="fragment"><div class="line"> <a class="code hl_function" href="utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38">m_assert</a>(expr, #expr, __METHOD_NAME__, __FILE__, \</div>
<b>Value:</b><div class="fragment"><div class="line"> <a class="code hl_function" href="utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38">m_assert</a>(expr, #expr, <a class="code hl_define" href="utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168">__METHOD_NAME__</a>, __FILE__, \</div>
<div class="line"> __LINE__, msg)</div>
<div class="ttc" id="autils_8hpp_html_a2cc3a2cdb635bac3c8b02e89d4d6af38"><div class="ttname"><a href="utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38">m_assert</a></div><div class="ttdeci">void m_assert(bool expr, std::string expr_str, std::string func, std::string file, int line, std::string msg)</div><div class="ttdoc">Test an expression, confirm that test is ok, or abort execution.</div><div class="ttdef"><b>Definition:</b> <a href="utils_8cpp_source.html#l00040">utils.cpp:40</a></div></div>
<div class="ttc" id="autils_8hpp_html_a2cc3a2cdb635bac3c8b02e89d4d6af38"><div class="ttname"><a href="utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38">m_assert</a></div><div class="ttdeci">void m_assert(bool expr, std::string expr_str, std::string func, std::string file, int line, std::string msg)</div><div class="ttdoc">Test an expression, confirm that test is ok, or abort execution.</div><div class="ttdef"><b>Definition:</b> <a href="utils_8cpp_source.html#l00043">utils.cpp:43</a></div></div>
<div class="ttc" id="autils_8hpp_html_a60dca3177fb9cb5256609adc7af55168"><div class="ttname"><a href="utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168">__METHOD_NAME__</a></div><div class="ttdeci">#define __METHOD_NAME__</div><div class="ttdoc">Get the name of the current method/function.</div><div class="ttdef"><b>Definition:</b> <a href="utils_8hpp_source.html#l00051">utils.hpp:51</a></div></div>
</div><!-- fragment -->
<p>A prettier assertion function. </p>
<p>This macro calls the m_assert function which is a more informative assertion function than the regular assert function from cassert. </p>
@@ -270,9 +277,9 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Boolean </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>bool </dd></dl>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00059">59</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00062">62</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
</div>
</div>
@@ -340,7 +347,48 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00040">40</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00043">43</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
</div>
</div>
<a id="a6fdd7217b750aff5b6295ece7cbdeffa" name="a6fdd7217b750aff5b6295ece7cbdeffa"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6fdd7217b750aff5b6295ece7cbdeffa">&#9670;&#160;</a></span>mkpath()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool mkpath </td>
<td>(</td>
<td class="paramtype">std::string&#160;</td>
<td class="paramname"><em>path</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&#160;</td>
<td class="paramname"><em>mode</em> = <code>0777</code>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Make path given. </p>
<p>This tries to be the equivalent to "mkdir -p" and creates a new directory whenever it needs to.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">path</td><td>The path to be created </td></tr>
<tr><td class="paramname">mode</td><td>The mode/permissions for all the new directories</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>bool </dd></dl>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00076">76</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
</div>
</div>
@@ -377,6 +425,7 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</div><div class="memdoc">
<p>Turns a vector of doubles into a string written in scientific format. </p>
<p>The code is stolen from <a href="https://github.com/anderkve/FYS3150">https://github.com/anderkve/FYS3150</a>.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">v</td><td>The vector to stringify </td></tr>
@@ -385,9 +434,9 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>String </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>std::string </dd></dl>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00021">21</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00024">24</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
</div>
</div>
@@ -424,7 +473,7 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</div><div class="memdoc">
<p>Turns a double into a string written in scientific format. </p>
<p>Code stolen from <a href="https://github.com/anderkve/FYS3150">https://github.com/anderkve/FYS3150</a> Header: <a href="https://github.com/anderkve/FYS3150/blob/master/code_examples/compilation_linking/example_1/include/utils.hpp">https://github.com/anderkve/FYS3150/blob/master/code_examples/compilation_linking/example_1/include/utils.hpp</a> Source: <a href="https://github.com/anderkve/FYS3150/blob/master/code_examples/compilation_linking/example_1/src/utils.cpp">https://github.com/anderkve/FYS3150/blob/master/code_examples/compilation_linking/example_1/src/utils.cpp</a> </p>
<p>The code is stolen from <a href="https://github.com/anderkve/FYS3150">https://github.com/anderkve/FYS3150</a>.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">d</td><td>The number to stringify </td></tr>
@@ -433,9 +482,9 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>String </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>std::string </dd></dl>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00014">14</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
<p class="definition">Definition at line <a class="el" href="utils_8cpp_source.html#l00017">17</a> of file <a class="el" href="utils_8cpp_source.html">utils.cpp</a>.</p>
</div>
</div>