mirror of
https://github.com/TheAlgorithms/C-Plus-Plus.git
synced 2026-07-16 11:32:44 +08:00
Documentation for aaa08b0150
This commit is contained in:
414
db/dd3/ode__forward__euler_8cpp.html
Normal file
414
db/dd3/ode__forward__euler_8cpp.html
Normal file
@@ -0,0 +1,414 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
||||
<meta name="generator" content="Doxygen 1.8.18"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Algorithms_in_C++: numerical_methods/ode_forward_euler.cpp File Reference</title>
|
||||
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="../../jquery.js"></script>
|
||||
<script type="text/javascript" src="../../dynsections.js"></script>
|
||||
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="../../resize.js"></script>
|
||||
<script type="text/javascript" src="../../navtreedata.js"></script>
|
||||
<script type="text/javascript" src="../../navtree.js"></script>
|
||||
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="../../search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="../../search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/MathJax.js?config=TeX-MML-AM_CHTML/MathJax.js"></script>
|
||||
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr style="height: 56px;">
|
||||
<td id="projectalign" style="padding-left: 0.5em;">
|
||||
<div id="projectname">Algorithms_in_C++
|
||||
 <span id="projectnumber">1.0.0</span>
|
||||
</div>
|
||||
<div id="projectbrief">Set of algorithms implemented in C++.</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.8.18 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
||||
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="../../menudata.js"></script>
|
||||
<script type="text/javascript" src="../../menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
||||
$(function() {
|
||||
initMenu('../../',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
||||
$(document).ready(function(){initNavTree('db/dd3/ode__forward__euler_8cpp.html','../../'); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<iframe src="javascript:void(0)" frameborder="0"
|
||||
name="MSearchResults" id="MSearchResults">
|
||||
</iframe>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="summary">
|
||||
<a href="#func-members">Functions</a> </div>
|
||||
<div class="headertitle">
|
||||
<div class="title">ode_forward_euler.cpp File Reference</div> </div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
|
||||
<p>Solve a multivariable first order <a href="https://en.wikipedia.org/wiki/Ordinary_differential_equation">ordinary differential equation (ODEs)</a> using <a href="https://en.wikipedia.org/wiki/Numerical_methods_for_ordinary_differential_equations#Euler_method">forward Euler method</a>
|
||||
<a href="#details">More...</a></p>
|
||||
<div class="textblock"><code>#include <cmath></code><br />
|
||||
<code>#include <ctime></code><br />
|
||||
<code>#include <fstream></code><br />
|
||||
<code>#include <iostream></code><br />
|
||||
<code>#include <valarray></code><br />
|
||||
</div><div class="textblock"><div class="dynheader">
|
||||
Include dependency graph for ode_forward_euler.cpp:</div>
|
||||
<div class="dyncontent">
|
||||
<div class="center"><iframe scrolling="no" frameborder="0" src="../../dc/dc5/ode__forward__euler_8cpp__incl.svg" width="430" height="127"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
|
||||
</div>
|
||||
</div>
|
||||
</div><table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
|
||||
Functions</h2></td></tr>
|
||||
<tr class="memitem:abaeae8f62a018d197f0187a1c80a90fe"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/dd3/ode__forward__euler_8cpp.html#abaeae8f62a018d197f0187a1c80a90fe">problem</a> (const double &x, <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > *y, <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > *dy)</td></tr>
|
||||
<tr class="memdesc:abaeae8f62a018d197f0187a1c80a90fe"><td class="mdescLeft"> </td><td class="mdescRight">Problem statement for a system with first-order differential equations. Updates the system differential variables. <a href="../../db/dd3/ode__forward__euler_8cpp.html#abaeae8f62a018d197f0187a1c80a90fe">More...</a><br /></td></tr>
|
||||
<tr class="separator:abaeae8f62a018d197f0187a1c80a90fe"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:af3adf7b092a87868917ee5fb4255192b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b">exact_solution</a> (const double &x, <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > *y)</td></tr>
|
||||
<tr class="memdesc:af3adf7b092a87868917ee5fb4255192b"><td class="mdescLeft"> </td><td class="mdescRight">Exact solution of the problem. Used for solution comparison. <a href="../../db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b">More...</a><br /></td></tr>
|
||||
<tr class="separator:af3adf7b092a87868917ee5fb4255192b"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:gaa197c6b7085ac9ea71abc4c063e6f52f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d6/d60/group__ode.html#gaa197c6b7085ac9ea71abc4c063e6f52f">forward_euler_step</a> (const double dx, const double &x, <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > *y, <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > *dy)</td></tr>
|
||||
<tr class="memdesc:gaa197c6b7085ac9ea71abc4c063e6f52f"><td class="mdescLeft"> </td><td class="mdescRight">Compute next step approximation using the forward-Euler method. <a href="../../d6/d60/group__ode.html#gaa197c6b7085ac9ea71abc4c063e6f52f">More...</a><br /></td></tr>
|
||||
<tr class="separator:gaa197c6b7085ac9ea71abc4c063e6f52f"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:gae0509f8843e2bc42de2abbd00a14b7b9"><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d6/d60/group__ode.html#gae0509f8843e2bc42de2abbd00a14b7b9">forward_euler</a> (double dx, double x0, double x_max, <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > *y, bool save_to_file=false)</td></tr>
|
||||
<tr class="memdesc:gae0509f8843e2bc42de2abbd00a14b7b9"><td class="mdescLeft"> </td><td class="mdescRight">Compute approximation using the forward-Euler method in the given limits. <a href="../../d6/d60/group__ode.html#gae0509f8843e2bc42de2abbd00a14b7b9">More...</a><br /></td></tr>
|
||||
<tr class="separator:gae0509f8843e2bc42de2abbd00a14b7b9"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:aa13517b8e5de1b75592052db7f7e237f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/dd3/ode__forward__euler_8cpp.html#aa13517b8e5de1b75592052db7f7e237f">save_exact_solution</a> (const double &X0, const double &X_MAX, const double &step_size, const <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > &Y0)</td></tr>
|
||||
<tr class="separator:aa13517b8e5de1b75592052db7f7e237f"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a0ddf1224851353fc92bfbff6f499fa97"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/dd3/ode__forward__euler_8cpp.html#a0ddf1224851353fc92bfbff6f499fa97">main</a> (int argc, char *argv[])</td></tr>
|
||||
<tr class="separator:a0ddf1224851353fc92bfbff6f499fa97"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<div class="textblock"><p>Solve a multivariable first order <a href="https://en.wikipedia.org/wiki/Ordinary_differential_equation">ordinary differential equation (ODEs)</a> using <a href="https://en.wikipedia.org/wiki/Numerical_methods_for_ordinary_differential_equations#Euler_method">forward Euler method</a> </p>
|
||||
<dl class="section author"><dt>Authors</dt><dd><a href="https://github.com/kvedala">Krishna Vedala</a></dd></dl>
|
||||
<p>The ODE being solved is: </p><p class="formulaDsp">
|
||||
\begin{eqnarray*} \dot{u} &=& v\\ \dot{v} &=& -\omega^2 u\\ \omega &=& 1\\ [x_0, u_0, v_0] &=& [0,1,0]\qquad\ldots\text{(initial values)} \end{eqnarray*}
|
||||
</p>
|
||||
<p> The exact solution for the above problem is: </p><p class="formulaDsp">
|
||||
\begin{eqnarray*} u(x) &=& \cos(x)\\ v(x) &=& -\sin(x)\\ \end{eqnarray*}
|
||||
</p>
|
||||
<p> The computation results are stored to a text file <code>forward_euler.csv</code> and the exact soltuion results in <code>exact.csv</code> for comparison. <img src="https://raw.githubusercontent.com/TheAlgorithms/C-Plus-Plus/docs/images/numerical_methods/ode_forward_euler.svg" alt="Implementation solution" style="pointer-events: none;" class="inline"/></p>
|
||||
<p>To implement <a href="https://en.wikipedia.org/wiki/Van_der_Pol_oscillator">Van der Pol oscillator</a>, change the <a class="el" href="../../db/dd3/ode__forward__euler_8cpp.html#abaeae8f62a018d197f0187a1c80a90fe" title="Problem statement for a system with first-order differential equations. Updates the system differenti...">problem</a> function to: </p><div class="fragment"><div class="line"><span class="keyword">const</span> <span class="keywordtype">double</span> mu = 2.0;</div>
|
||||
<div class="line">dy[0] = y[1];</div>
|
||||
<div class="line">dy[1] = mu * (1.f - y[0] * y[0]) * y[1] - y[0];</div>
|
||||
</div><!-- fragment --><dl class="section see"><dt>See also</dt><dd><a class="el" href="../../d6/dd3/ode__midpoint__euler_8cpp.html" title="Solve a multivariable first order ordinary differential equation (ODEs) using midpoint Euler method">ode_midpoint_euler.cpp</a>, <a class="el" href="../../d3/d06/ode__semi__implicit__euler_8cpp.html" title="Solve a multivariable first order ordinary differential equation (ODEs) using semi implicit Euler met...">ode_semi_implicit_euler.cpp</a> </dd></dl>
|
||||
</div><h2 class="groupheader">Function Documentation</h2>
|
||||
<a id="af3adf7b092a87868917ee5fb4255192b"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#af3adf7b092a87868917ee5fb4255192b">◆ </a></span>exact_solution()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void exact_solution </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">const double & </td>
|
||||
<td class="paramname"><em>x</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype"><a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > * </td>
|
||||
<td class="paramname"><em>y</em> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Exact solution of the problem. Used for solution comparison. </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramdir">[in]</td><td class="paramname">x</td><td>independent variable </td></tr>
|
||||
<tr><td class="paramdir">[in,out]</td><td class="paramname">y</td><td>dependent variable </td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<div class="fragment"><div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  {</div>
|
||||
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  y[0][0] = <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/math/cos.html">std::cos</a>(x);</div>
|
||||
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  y[0][1] = -<a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/math/sin.html">std::sin</a>(x);</div>
|
||||
<div class="line"><a name="l00070"></a><span class="lineno"> 70</span> }</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="../../db/dd3/ode__forward__euler_8cpp_af3adf7b092a87868917ee5fb4255192b_cgraph.svg" width="235" height="88"><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="a0ddf1224851353fc92bfbff6f499fa97"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a0ddf1224851353fc92bfbff6f499fa97">◆ </a></span>main()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">int main </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">int </td>
|
||||
<td class="paramname"><em>argc</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">char * </td>
|
||||
<td class="paramname"><em>argv</em>[] </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
<p>Main Function </p>
|
||||
<div class="fragment"><div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  {</div>
|
||||
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  <span class="keywordtype">double</span> X0 = 0.f; <span class="comment">/* initial value of x0 */</span></div>
|
||||
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  <span class="keywordtype">double</span> X_MAX = 10.F; <span class="comment">/* upper limit of integration */</span></div>
|
||||
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray<double></a> Y0 = {1.f, 0.f}; <span class="comment">/* initial value Y = y(x = x_0) */</span></div>
|
||||
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span>  <span class="keywordtype">double</span> step_size;</div>
|
||||
<div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  </div>
|
||||
<div class="line"><a name="l00194"></a><span class="lineno"> 194</span>  <span class="keywordflow">if</span> (argc == 1) {</div>
|
||||
<div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> << <span class="stringliteral">"\nEnter the step size: "</span>;</div>
|
||||
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_istream.html">std::cin</a> >> step_size;</div>
|
||||
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  } <span class="keywordflow">else</span> {</div>
|
||||
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  <span class="comment">// use commandline argument as independent variable step size</span></div>
|
||||
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  step_size = <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/string/byte/atof.html">std::atof</a>(argv[1]);</div>
|
||||
<div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  }</div>
|
||||
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span>  </div>
|
||||
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  <span class="comment">// get approximate solution</span></div>
|
||||
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span>  <span class="keywordtype">double</span> total_time = <a class="code" href="../../d6/d60/group__ode.html#gae0509f8843e2bc42de2abbd00a14b7b9">forward_euler</a>(step_size, X0, X_MAX, &Y0, <span class="keyword">true</span>);</div>
|
||||
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> << <span class="stringliteral">"\tTime = "</span> << total_time << <span class="stringliteral">" ms\n"</span>;</div>
|
||||
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  </div>
|
||||
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  <span class="comment">/* compute exact solution for comparion */</span></div>
|
||||
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  <a class="code" href="../../db/dd3/ode__forward__euler_8cpp.html#aa13517b8e5de1b75592052db7f7e237f">save_exact_solution</a>(X0, X_MAX, step_size, Y0);</div>
|
||||
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  </div>
|
||||
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  <span class="keywordflow">return</span> 0;</div>
|
||||
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span> }</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="../../db/dd3/ode__forward__euler_8cpp_a0ddf1224851353fc92bfbff6f499fa97_cgraph.svg" width="568" height="367"><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="abaeae8f62a018d197f0187a1c80a90fe"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#abaeae8f62a018d197f0187a1c80a90fe">◆ </a></span>problem()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void problem </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">const double & </td>
|
||||
<td class="paramname"><em>x</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype"><a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > * </td>
|
||||
<td class="paramname"><em>y</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype"><a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > * </td>
|
||||
<td class="paramname"><em>dy</em> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Problem statement for a system with first-order differential equations. Updates the system differential variables. </p>
|
||||
<dl class="section note"><dt>Note</dt><dd>This function can be updated to and ode of any order.</dd></dl>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramdir">[in]</td><td class="paramname">x</td><td>independent variable(s) </td></tr>
|
||||
<tr><td class="paramdir">[in,out]</td><td class="paramname">y</td><td>dependent variable(s) </td></tr>
|
||||
<tr><td class="paramdir">[in,out]</td><td class="paramname">dy</td><td>first-derivative of dependent variable(s) </td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<div class="fragment"><div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  {</div>
|
||||
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  <span class="keyword">const</span> <span class="keywordtype">double</span> omega = 1.F; <span class="comment">// some const for the problem</span></div>
|
||||
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  dy[0][0] = y[0][1]; <span class="comment">// x dot</span></div>
|
||||
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  dy[0][1] = -omega * omega * y[0][0]; <span class="comment">// y dot</span></div>
|
||||
<div class="line"><a name="l00059"></a><span class="lineno"> 59</span> }</div>
|
||||
</div><!-- fragment -->
|
||||
</div>
|
||||
</div>
|
||||
<a id="aa13517b8e5de1b75592052db7f7e237f"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#aa13517b8e5de1b75592052db7f7e237f">◆ </a></span>save_exact_solution()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void save_exact_solution </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">const double & </td>
|
||||
<td class="paramname"><em>X0</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">const double & </td>
|
||||
<td class="paramname"><em>X_MAX</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">const double & </td>
|
||||
<td class="paramname"><em>step_size</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">const <a class="elRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a>< double > & </td>
|
||||
<td class="paramname"><em>Y0</em> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
<p>Function to compute and save exact solution for comparison</p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramdir">[in]</td><td class="paramname">X0</td><td>initial value of independent variable </td></tr>
|
||||
<tr><td class="paramdir">[in]</td><td class="paramname">X_MAX</td><td>final value of independent variable </td></tr>
|
||||
<tr><td class="paramdir">[in]</td><td class="paramname">step_size</td><td>independent variable step size </td></tr>
|
||||
<tr><td class="paramdir">[in]</td><td class="paramname">Y0</td><td>initial values of dependent variables </td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<div class="fragment"><div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  {</div>
|
||||
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  <span class="keywordtype">double</span> x = X0;</div>
|
||||
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray<double></a> y = Y0;</div>
|
||||
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  </div>
|
||||
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ofstream.html">std::ofstream</a> fp(<span class="stringliteral">"exact.csv"</span>, std::ostream::out);</div>
|
||||
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  <span class="keywordflow">if</span> (!fp.is_open()) {</div>
|
||||
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/c/perror.html">std::perror</a>(<span class="stringliteral">"Error! "</span>);</div>
|
||||
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  <span class="keywordflow">return</span>;</div>
|
||||
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  }</div>
|
||||
<div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> << <span class="stringliteral">"Finding exact solution\n"</span>;</div>
|
||||
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  </div>
|
||||
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/chrono/c/clock_t.html">std::clock_t</a> t1 = <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/chrono/c/clock.html">std::clock</a>();</div>
|
||||
<div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  <span class="keywordflow">do</span> {</div>
|
||||
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  fp << x << <span class="stringliteral">","</span>;</div>
|
||||
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i < y.size() - 1; i++) {</div>
|
||||
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  fp << y[i] << <span class="stringliteral">","</span>;</div>
|
||||
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  }</div>
|
||||
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  fp << y[y.size() - 1] << <span class="stringliteral">"\n"</span>;</div>
|
||||
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  </div>
|
||||
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  <a class="code" href="../../db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b">exact_solution</a>(x, &y);</div>
|
||||
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  </div>
|
||||
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  x += step_size;</div>
|
||||
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span>  } <span class="keywordflow">while</span> (x <= X_MAX);</div>
|
||||
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>  </div>
|
||||
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/chrono/c/clock_t.html">std::clock_t</a> t2 = <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/chrono/c/clock.html">std::clock</a>();</div>
|
||||
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  <span class="keywordtype">double</span> total_time = <span class="keyword">static_cast<</span><span class="keywordtype">double</span><span class="keyword">></span>(t2 - t1) / CLOCKS_PER_SEC;</div>
|
||||
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span>  <a class="codeRef" target="_blank" href="http://en.cppreference.com/w/cpp/io/basic_ostream.html">std::cout</a> << <span class="stringliteral">"\tTime = "</span> << total_time << <span class="stringliteral">" ms\n"</span>;</div>
|
||||
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  </div>
|
||||
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  fp.close();</div>
|
||||
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span> }</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="../../db/dd3/ode__forward__euler_8cpp_aa13517b8e5de1b75592052db7f7e237f_cgraph.svg" width="470" height="240"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<div class="ttc" id="aclock_t_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/chrono/c/clock_t.html">std::clock_t</a></div></div>
|
||||
<div class="ttc" id="acos_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/numeric/math/cos.html">std::cos</a></div><div class="ttdeci">T cos(T... args)</div></div>
|
||||
<div class="ttc" id="aode__forward__euler_8cpp_html_af3adf7b092a87868917ee5fb4255192b"><div class="ttname"><a href="../../db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b">exact_solution</a></div><div class="ttdeci">void exact_solution(const double &x, std::valarray< double > *y)</div><div class="ttdoc">Exact solution of the problem. Used for solution comparison.</div><div class="ttdef"><b>Definition:</b> ode_forward_euler.cpp:67</div></div>
|
||||
<div class="ttc" id="aatof_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/string/byte/atof.html">std::atof</a></div><div class="ttdeci">T atof(T... args)</div></div>
|
||||
<div class="ttc" id="aclock_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/chrono/c/clock.html">std::clock</a></div><div class="ttdeci">T clock(T... args)</div></div>
|
||||
<div class="ttc" id="aode__forward__euler_8cpp_html_aa13517b8e5de1b75592052db7f7e237f"><div class="ttname"><a href="../../db/dd3/ode__forward__euler_8cpp.html#aa13517b8e5de1b75592052db7f7e237f">save_exact_solution</a></div><div class="ttdeci">void save_exact_solution(const double &X0, const double &X_MAX, const double &step_size, const std::valarray< double > &Y0)</div><div class="ttdef"><b>Definition:</b> ode_forward_euler.cpp:152</div></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="abasic_ofstream_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/basic_ofstream.html">std::ofstream</a></div><div class="ttdoc">STL class.</div></div>
|
||||
<div class="ttc" id="aperror_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/c/perror.html">std::perror</a></div><div class="ttdeci">T perror(T... args)</div></div>
|
||||
<div class="ttc" id="avalarray_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/numeric/valarray.html">std::valarray</a></div><div class="ttdoc">STL class.</div></div>
|
||||
<div class="ttc" id="agroup__ode_html_gae0509f8843e2bc42de2abbd00a14b7b9"><div class="ttname"><a href="../../d6/d60/group__ode.html#gae0509f8843e2bc42de2abbd00a14b7b9">forward_euler</a></div><div class="ttdeci">double forward_euler(double dx, double x0, double x_max, std::valarray< double > *y, bool save_to_file=false)</div><div class="ttdoc">Compute approximation using the forward-Euler method in the given limits.</div><div class="ttdef"><b>Definition:</b> ode_forward_euler.cpp:102</div></div>
|
||||
<div class="ttc" id="asin_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/numeric/math/sin.html">std::sin</a></div><div class="ttdeci">T sin(T... args)</div></div>
|
||||
<div class="ttc" id="abasic_istream_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/io/basic_istream.html">std::cin</a></div></div>
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="../../dir_9c6faab82c22511b50177aa2e38e2780.html">numerical_methods</a></li><li class="navelem"><a class="el" href="../../db/dd3/ode__forward__euler_8cpp.html">ode_forward_euler.cpp</a></li>
|
||||
<li class="footer">Generated on Fri Jun 19 2020 16:06:44 for Algorithms_in_C++ by
|
||||
<a href="http://www.doxygen.org/index.html">
|
||||
<img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.18 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
9
db/dd3/ode__forward__euler_8cpp.js
Normal file
9
db/dd3/ode__forward__euler_8cpp.js
Normal file
@@ -0,0 +1,9 @@
|
||||
var ode__forward__euler_8cpp =
|
||||
[
|
||||
[ "exact_solution", "db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b", null ],
|
||||
[ "forward_euler", "d6/d60/group__ode.html#gae0509f8843e2bc42de2abbd00a14b7b9", null ],
|
||||
[ "forward_euler_step", "d6/d60/group__ode.html#gaa197c6b7085ac9ea71abc4c063e6f52f", null ],
|
||||
[ "main", "db/dd3/ode__forward__euler_8cpp.html#a0ddf1224851353fc92bfbff6f499fa97", null ],
|
||||
[ "problem", "db/dd3/ode__forward__euler_8cpp.html#abaeae8f62a018d197f0187a1c80a90fe", null ],
|
||||
[ "save_exact_solution", "db/dd3/ode__forward__euler_8cpp.html#aa13517b8e5de1b75592052db7f7e237f", null ]
|
||||
];
|
||||
@@ -0,0 +1,16 @@
|
||||
<map id="main" name="main">
|
||||
<area shape="rect" id="node1" title=" " alt="" coords="5,132,56,159"/>
|
||||
<area shape="rect" id="node2" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/string/byte/atof.html#" title=" " alt="" coords="139,81,210,108"/>
|
||||
<area shape="rect" id="node3" href="$d6/d60/group__ode.html#gae0509f8843e2bc42de2abbd00a14b7b9" title="Compute approximation using the forward-Euler method in the given limits." alt="" coords="125,183,225,209"/>
|
||||
<area shape="rect" id="node11" href="$db/dd3/ode__forward__euler_8cpp.html#aa13517b8e5de1b75592052db7f7e237f" title=" " alt="" coords="104,132,245,159"/>
|
||||
<area shape="rect" id="node4" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/chrono/c/clock.html#" title=" " alt="" coords="330,233,409,260"/>
|
||||
<area shape="rect" id="node5" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/io/basic_ofstream/close.html#" title=" " alt="" coords="300,81,439,108"/>
|
||||
<area shape="rect" id="node6" href="$d6/d60/group__ode.html#gaa197c6b7085ac9ea71abc4c063e6f52f" title="Compute next step approximation using the forward-Euler method." alt="" coords="303,335,435,361"/>
|
||||
<area shape="rect" id="node8" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/io/basic_ofstream/is_open.html#" title=" " alt="" coords="293,132,445,159"/>
|
||||
<area shape="rect" id="node9" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/io/basic_ofstream/open.html#" title=" " alt="" coords="302,284,437,311"/>
|
||||
<area shape="rect" id="node10" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/io/c/perror.html#" title=" " alt="" coords="329,183,410,209"/>
|
||||
<area shape="rect" id="node7" href="$db/dd3/ode__forward__euler_8cpp.html#abaeae8f62a018d197f0187a1c80a90fe" title="Problem statement for a system with first-order differential equations. Updates the system differenti..." alt="" coords="494,335,562,361"/>
|
||||
<area shape="rect" id="node12" href="$db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b" title="Exact solution of the problem. Used for solution comparison." alt="" coords="316,31,423,57"/>
|
||||
<area shape="rect" id="node13" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/numeric/math/cos.html#" title=" " alt="" coords="493,56,563,83"/>
|
||||
<area shape="rect" id="node14" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/numeric/math/sin.html#" title=" " alt="" coords="495,5,561,32"/>
|
||||
</map>
|
||||
@@ -0,0 +1 @@
|
||||
1c011524884e08ee09e2a375bad79290
|
||||
@@ -0,0 +1,241 @@
|
||||
<?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 2.44.0 (20200408.0750)
|
||||
-->
|
||||
<!-- Title: main Pages: 1 -->
|
||||
<svg width="426pt" height="275pt"
|
||||
viewBox="0.00 0.00 426.00 275.00" 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 271)">
|
||||
<title>main</title>
|
||||
<polygon fill="white" stroke="transparent" points="-4,4 -4,-271 422,-271 422,4 -4,4"/>
|
||||
<!-- Node1 -->
|
||||
<g id="node1" class="node">
|
||||
<title>Node1</title>
|
||||
<g id="a_node1"><a xlink:title=" ">
|
||||
<polygon fill="#bfbfbf" stroke="black" points="0,-152.5 0,-171.5 38,-171.5 38,-152.5 0,-152.5"/>
|
||||
<text text-anchor="middle" x="19" y="-159.5" font-family="Helvetica,sans-Serif" font-size="10.00">main</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node2 -->
|
||||
<g id="node2" class="node">
|
||||
<title>Node2</title>
|
||||
<g id="a_node2"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/string/byte/atof.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="100.5,-190.5 100.5,-209.5 153.5,-209.5 153.5,-190.5 100.5,-190.5"/>
|
||||
<text text-anchor="middle" x="127" y="-197.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::atof</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node2 -->
|
||||
<g id="edge1" class="edge">
|
||||
<title>Node1->Node2</title>
|
||||
<path fill="none" stroke="midnightblue" d="M38.46,-168.62C52.74,-173.74 72.95,-180.98 90.35,-187.22"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="89.61,-190.67 100.21,-190.75 91.97,-184.08 89.61,-190.67"/>
|
||||
</g>
|
||||
<!-- Node3 -->
|
||||
<g id="node3" class="node">
|
||||
<title>Node3</title>
|
||||
<g id="a_node3"><a xlink:href="../../d6/d60/group__ode.html#gae0509f8843e2bc42de2abbd00a14b7b9" target="_top" xlink:title="Compute approximation using the forward-Euler method in the given limits.">
|
||||
<polygon fill="white" stroke="black" points="89.5,-114.5 89.5,-133.5 164.5,-133.5 164.5,-114.5 89.5,-114.5"/>
|
||||
<text text-anchor="middle" x="127" y="-121.5" font-family="Helvetica,sans-Serif" font-size="10.00">forward_euler</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node3 -->
|
||||
<g id="edge2" class="edge">
|
||||
<title>Node1->Node3</title>
|
||||
<path fill="none" stroke="midnightblue" d="M38.46,-155.38C52.55,-150.33 72.39,-143.22 89.62,-137.04"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="91.17,-140.2 99.41,-133.53 88.81,-133.61 91.17,-140.2"/>
|
||||
</g>
|
||||
<!-- Node11 -->
|
||||
<g id="node11" class="node">
|
||||
<title>Node11</title>
|
||||
<g id="a_node11"><a xlink:href="../../db/dd3/ode__forward__euler_8cpp.html#aa13517b8e5de1b75592052db7f7e237f" target="_top" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="74,-152.5 74,-171.5 180,-171.5 180,-152.5 74,-152.5"/>
|
||||
<text text-anchor="middle" x="127" y="-159.5" font-family="Helvetica,sans-Serif" font-size="10.00">save_exact_solution</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node11 -->
|
||||
<g id="edge10" class="edge">
|
||||
<title>Node1->Node11</title>
|
||||
<path fill="none" stroke="midnightblue" d="M38.46,-162C45.69,-162 54.44,-162 63.58,-162"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="63.59,-165.5 73.59,-162 63.59,-158.5 63.59,-165.5"/>
|
||||
</g>
|
||||
<!-- Node4 -->
|
||||
<g id="node4" class="node">
|
||||
<title>Node4</title>
|
||||
<g id="a_node4"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/chrono/c/clock.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="243.5,-76.5 243.5,-95.5 302.5,-95.5 302.5,-76.5 243.5,-76.5"/>
|
||||
<text text-anchor="middle" x="273" y="-83.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::clock</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node3->Node4 -->
|
||||
<g id="edge3" class="edge">
|
||||
<title>Node3->Node4</title>
|
||||
<path fill="none" stroke="midnightblue" d="M164.34,-114.41C185.48,-108.83 212.12,-101.8 233.61,-96.13"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="234.61,-99.49 243.39,-93.55 232.83,-92.72 234.61,-99.49"/>
|
||||
</g>
|
||||
<!-- Node5 -->
|
||||
<g id="node5" class="node">
|
||||
<title>Node5</title>
|
||||
<g id="a_node5"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/io/basic_ofstream/close.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="221,-190.5 221,-209.5 325,-209.5 325,-190.5 221,-190.5"/>
|
||||
<text text-anchor="middle" x="273" y="-197.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::ofstream::close</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node3->Node5 -->
|
||||
<g id="edge4" class="edge">
|
||||
<title>Node3->Node5</title>
|
||||
<path fill="none" stroke="midnightblue" d="M161.28,-133.55C167.76,-136.12 174.3,-139.25 180,-143 199.44,-155.78 196.41,-168.45 216,-181 219.12,-183 222.48,-184.81 225.94,-186.46"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="224.69,-189.73 235.27,-190.4 227.42,-183.28 224.69,-189.73"/>
|
||||
</g>
|
||||
<!-- Node6 -->
|
||||
<g id="node6" class="node">
|
||||
<title>Node6</title>
|
||||
<g id="a_node6"><a xlink:href="../../d6/d60/group__ode.html#gaa197c6b7085ac9ea71abc4c063e6f52f" target="_top" xlink:title="Compute next step approximation using the forward-Euler method.">
|
||||
<polygon fill="white" stroke="black" points="223.5,-0.5 223.5,-19.5 322.5,-19.5 322.5,-0.5 223.5,-0.5"/>
|
||||
<text text-anchor="middle" x="273" y="-7.5" font-family="Helvetica,sans-Serif" font-size="10.00">forward_euler_step</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node3->Node6 -->
|
||||
<g id="edge5" class="edge">
|
||||
<title>Node3->Node6</title>
|
||||
<path fill="none" stroke="midnightblue" d="M134.34,-114.45C147.41,-95.49 179.22,-52.85 216,-29 219.11,-26.98 222.46,-25.16 225.92,-23.51"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="227.4,-26.68 235.23,-19.54 224.66,-20.24 227.4,-26.68"/>
|
||||
</g>
|
||||
<!-- Node8 -->
|
||||
<g id="node8" class="node">
|
||||
<title>Node8</title>
|
||||
<g id="a_node8"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/io/basic_ofstream/is_open.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="216,-152.5 216,-171.5 330,-171.5 330,-152.5 216,-152.5"/>
|
||||
<text text-anchor="middle" x="273" y="-159.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::ofstream::is_open</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node3->Node8 -->
|
||||
<g id="edge7" class="edge">
|
||||
<title>Node3->Node8</title>
|
||||
<path fill="none" stroke="midnightblue" d="M164.34,-133.59C183.08,-138.54 206.14,-144.62 226.11,-149.89"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="225.36,-153.31 235.92,-152.48 227.15,-146.54 225.36,-153.31"/>
|
||||
</g>
|
||||
<!-- Node9 -->
|
||||
<g id="node9" class="node">
|
||||
<title>Node9</title>
|
||||
<g id="a_node9"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/io/basic_ofstream/open.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="222.5,-38.5 222.5,-57.5 323.5,-57.5 323.5,-38.5 222.5,-38.5"/>
|
||||
<text text-anchor="middle" x="273" y="-45.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::ofstream::open</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node3->Node9 -->
|
||||
<g id="edge8" class="edge">
|
||||
<title>Node3->Node9</title>
|
||||
<path fill="none" stroke="midnightblue" d="M140.53,-114.45C157.08,-102.18 187.49,-80.8 216,-67 220.39,-64.87 225.08,-62.88 229.8,-61.05"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="231.28,-64.24 239.47,-57.52 228.88,-57.66 231.28,-64.24"/>
|
||||
</g>
|
||||
<!-- Node10 -->
|
||||
<g id="node10" class="node">
|
||||
<title>Node10</title>
|
||||
<g id="a_node10"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/io/c/perror.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="242.5,-114.5 242.5,-133.5 303.5,-133.5 303.5,-114.5 242.5,-114.5"/>
|
||||
<text text-anchor="middle" x="273" y="-121.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::perror</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node3->Node10 -->
|
||||
<g id="edge9" class="edge">
|
||||
<title>Node3->Node10</title>
|
||||
<path fill="none" stroke="midnightblue" d="M164.71,-124C185.24,-124 210.86,-124 231.91,-124"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="232.14,-127.5 242.14,-124 232.14,-120.5 232.14,-127.5"/>
|
||||
</g>
|
||||
<!-- Node7 -->
|
||||
<g id="node7" class="node">
|
||||
<title>Node7</title>
|
||||
<g id="a_node7"><a xlink:href="../../db/dd3/ode__forward__euler_8cpp.html#abaeae8f62a018d197f0187a1c80a90fe" target="_top" xlink:title="Problem statement for a system with first-order differential equations. Updates the system differenti...">
|
||||
<polygon fill="white" stroke="black" points="366.5,-0.5 366.5,-19.5 417.5,-19.5 417.5,-0.5 366.5,-0.5"/>
|
||||
<text text-anchor="middle" x="392" y="-7.5" font-family="Helvetica,sans-Serif" font-size="10.00">problem</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node6->Node7 -->
|
||||
<g id="edge6" class="edge">
|
||||
<title>Node6->Node7</title>
|
||||
<path fill="none" stroke="midnightblue" d="M322.6,-10C333.9,-10 345.71,-10 356.27,-10"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="356.36,-13.5 366.36,-10 356.36,-6.5 356.36,-13.5"/>
|
||||
</g>
|
||||
<!-- Node11->Node4 -->
|
||||
<g id="edge11" class="edge">
|
||||
<title>Node11->Node4</title>
|
||||
<path fill="none" stroke="midnightblue" d="M161.28,-152.45C167.76,-149.88 174.3,-146.75 180,-143 199.44,-130.22 196.41,-117.55 216,-105 221.45,-101.51 227.6,-98.59 233.79,-96.17"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="235.18,-99.39 243.44,-92.76 232.85,-92.79 235.18,-99.39"/>
|
||||
</g>
|
||||
<!-- Node11->Node5 -->
|
||||
<g id="edge12" class="edge">
|
||||
<title>Node11->Node5</title>
|
||||
<path fill="none" stroke="midnightblue" d="M164.34,-171.59C183.08,-176.54 206.14,-182.62 226.11,-187.89"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="225.36,-191.31 235.92,-190.48 227.15,-184.54 225.36,-191.31"/>
|
||||
</g>
|
||||
<!-- Node11->Node8 -->
|
||||
<g id="edge16" class="edge">
|
||||
<title>Node11->Node8</title>
|
||||
<path fill="none" stroke="midnightblue" d="M180.39,-162C188.51,-162 196.99,-162 205.37,-162"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="205.52,-165.5 215.52,-162 205.52,-158.5 205.52,-165.5"/>
|
||||
</g>
|
||||
<!-- Node11->Node10 -->
|
||||
<g id="edge17" class="edge">
|
||||
<title>Node11->Node10</title>
|
||||
<path fill="none" stroke="midnightblue" d="M164.34,-152.41C185.2,-146.91 211.4,-139.99 232.73,-134.36"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="233.68,-137.73 242.46,-131.8 231.9,-130.96 233.68,-137.73"/>
|
||||
</g>
|
||||
<!-- Node12 -->
|
||||
<g id="node12" class="node">
|
||||
<title>Node12</title>
|
||||
<g id="a_node12"><a xlink:href="../../db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b" target="_top" xlink:title="Exact solution of the problem. Used for solution comparison.">
|
||||
<polygon fill="white" stroke="black" points="233,-228.5 233,-247.5 313,-247.5 313,-228.5 233,-228.5"/>
|
||||
<text text-anchor="middle" x="273" y="-235.5" font-family="Helvetica,sans-Serif" font-size="10.00">exact_solution</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node11->Node12 -->
|
||||
<g id="edge13" class="edge">
|
||||
<title>Node11->Node12</title>
|
||||
<path fill="none" stroke="midnightblue" d="M161.28,-171.55C167.76,-174.12 174.3,-177.25 180,-181 199.44,-193.78 196.41,-206.45 216,-219 219.12,-221 222.48,-222.81 225.94,-224.46"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="224.69,-227.73 235.27,-228.4 227.42,-221.28 224.69,-227.73"/>
|
||||
</g>
|
||||
<!-- Node13 -->
|
||||
<g id="node13" class="node">
|
||||
<title>Node13</title>
|
||||
<g id="a_node13"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/numeric/math/cos.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="366,-209.5 366,-228.5 418,-228.5 418,-209.5 366,-209.5"/>
|
||||
<text text-anchor="middle" x="392" y="-216.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::cos</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node12->Node13 -->
|
||||
<g id="edge14" class="edge">
|
||||
<title>Node12->Node13</title>
|
||||
<path fill="none" stroke="midnightblue" d="M313.28,-231.62C327.01,-229.39 342.32,-226.91 355.7,-224.73"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="356.64,-228.13 365.95,-223.07 355.52,-221.22 356.64,-228.13"/>
|
||||
</g>
|
||||
<!-- Node14 -->
|
||||
<g id="node14" class="node">
|
||||
<title>Node14</title>
|
||||
<g id="a_node14"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/numeric/math/sin.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="367.5,-247.5 367.5,-266.5 416.5,-266.5 416.5,-247.5 367.5,-247.5"/>
|
||||
<text text-anchor="middle" x="392" y="-254.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::sin</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node12->Node14 -->
|
||||
<g id="edge15" class="edge">
|
||||
<title>Node12->Node14</title>
|
||||
<path fill="none" stroke="midnightblue" d="M313.28,-244.38C327.57,-246.7 343.57,-249.3 357.33,-251.53"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="356.91,-255.01 367.34,-253.16 358.03,-248.1 356.91,-255.01"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 12 KiB |
@@ -0,0 +1,10 @@
|
||||
<map id="save_exact_solution" name="save_exact_solution">
|
||||
<area shape="rect" id="node1" title=" " alt="" coords="5,107,147,133"/>
|
||||
<area shape="rect" id="node2" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/chrono/c/clock.html#" title=" " alt="" coords="231,5,310,32"/>
|
||||
<area shape="rect" id="node3" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/io/basic_ofstream/close.html#" title=" " alt="" coords="201,56,340,83"/>
|
||||
<area shape="rect" id="node4" href="$db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b" title="Exact solution of the problem. Used for solution comparison." alt="" coords="217,107,324,133"/>
|
||||
<area shape="rect" id="node7" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/io/basic_ofstream/is_open.html#" title=" " alt="" coords="195,157,347,184"/>
|
||||
<area shape="rect" id="node8" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/io/c/perror.html#" title=" " alt="" coords="230,208,311,235"/>
|
||||
<area shape="rect" id="node5" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/numeric/math/cos.html#" title=" " alt="" coords="395,81,464,108"/>
|
||||
<area shape="rect" id="node6" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/numeric/math/sin.html#" title=" " alt="" coords="397,132,462,159"/>
|
||||
</map>
|
||||
@@ -0,0 +1 @@
|
||||
e73ec3022db67a36c8cbe08bd9e8f092
|
||||
@@ -0,0 +1,127 @@
|
||||
<?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 2.44.0 (20200408.0750)
|
||||
-->
|
||||
<!-- Title: save_exact_solution Pages: 1 -->
|
||||
<svg width="352pt" height="180pt"
|
||||
viewBox="0.00 0.00 352.00 180.00" 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 176)">
|
||||
<title>save_exact_solution</title>
|
||||
<polygon fill="white" stroke="transparent" points="-4,4 -4,-176 348,-176 348,4 -4,4"/>
|
||||
<!-- Node1 -->
|
||||
<g id="node1" class="node">
|
||||
<title>Node1</title>
|
||||
<g id="a_node1"><a xlink:title=" ">
|
||||
<polygon fill="#bfbfbf" stroke="black" points="0,-76.5 0,-95.5 106,-95.5 106,-76.5 0,-76.5"/>
|
||||
<text text-anchor="middle" x="53" y="-83.5" font-family="Helvetica,sans-Serif" font-size="10.00">save_exact_solution</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node2 -->
|
||||
<g id="node2" class="node">
|
||||
<title>Node2</title>
|
||||
<g id="a_node2"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/chrono/c/clock.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="169.5,-152.5 169.5,-171.5 228.5,-171.5 228.5,-152.5 169.5,-152.5"/>
|
||||
<text text-anchor="middle" x="199" y="-159.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::clock</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node2 -->
|
||||
<g id="edge1" class="edge">
|
||||
<title>Node1->Node2</title>
|
||||
<path fill="none" stroke="midnightblue" d="M66.53,-95.55C83.08,-107.82 113.49,-129.2 142,-143 147.51,-145.67 153.48,-148.12 159.41,-150.32"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="158.66,-153.76 169.25,-153.76 160.97,-147.15 158.66,-153.76"/>
|
||||
</g>
|
||||
<!-- Node3 -->
|
||||
<g id="node3" class="node">
|
||||
<title>Node3</title>
|
||||
<g id="a_node3"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/io/basic_ofstream/close.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="147,-114.5 147,-133.5 251,-133.5 251,-114.5 147,-114.5"/>
|
||||
<text text-anchor="middle" x="199" y="-121.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::ofstream::close</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node3 -->
|
||||
<g id="edge2" class="edge">
|
||||
<title>Node1->Node3</title>
|
||||
<path fill="none" stroke="midnightblue" d="M90.34,-95.59C109.08,-100.54 132.14,-106.62 152.11,-111.89"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="151.36,-115.31 161.92,-114.48 153.15,-108.54 151.36,-115.31"/>
|
||||
</g>
|
||||
<!-- Node4 -->
|
||||
<g id="node4" class="node">
|
||||
<title>Node4</title>
|
||||
<g id="a_node4"><a xlink:href="../../db/dd3/ode__forward__euler_8cpp.html#af3adf7b092a87868917ee5fb4255192b" target="_top" xlink:title="Exact solution of the problem. Used for solution comparison.">
|
||||
<polygon fill="white" stroke="black" points="159,-76.5 159,-95.5 239,-95.5 239,-76.5 159,-76.5"/>
|
||||
<text text-anchor="middle" x="199" y="-83.5" font-family="Helvetica,sans-Serif" font-size="10.00">exact_solution</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node4 -->
|
||||
<g id="edge3" class="edge">
|
||||
<title>Node1->Node4</title>
|
||||
<path fill="none" stroke="midnightblue" d="M106.39,-86C120.24,-86 135.12,-86 148.79,-86"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="148.97,-89.5 158.97,-86 148.97,-82.5 148.97,-89.5"/>
|
||||
</g>
|
||||
<!-- Node7 -->
|
||||
<g id="node7" class="node">
|
||||
<title>Node7</title>
|
||||
<g id="a_node7"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/io/basic_ofstream/is_open.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="142,-38.5 142,-57.5 256,-57.5 256,-38.5 142,-38.5"/>
|
||||
<text text-anchor="middle" x="199" y="-45.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::ofstream::is_open</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node7 -->
|
||||
<g id="edge6" class="edge">
|
||||
<title>Node1->Node7</title>
|
||||
<path fill="none" stroke="midnightblue" d="M90.34,-76.41C109.08,-71.46 132.14,-65.38 152.11,-60.11"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="153.15,-63.46 161.92,-57.52 151.36,-56.69 153.15,-63.46"/>
|
||||
</g>
|
||||
<!-- Node8 -->
|
||||
<g id="node8" class="node">
|
||||
<title>Node8</title>
|
||||
<g id="a_node8"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/io/c/perror.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="168.5,-0.5 168.5,-19.5 229.5,-19.5 229.5,-0.5 168.5,-0.5"/>
|
||||
<text text-anchor="middle" x="199" y="-7.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::perror</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node8 -->
|
||||
<g id="edge7" class="edge">
|
||||
<title>Node1->Node8</title>
|
||||
<path fill="none" stroke="midnightblue" d="M66.53,-76.45C83.08,-64.18 113.49,-42.8 142,-29 147.33,-26.42 153.1,-24.04 158.84,-21.9"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="160.12,-25.15 168.39,-18.53 157.79,-18.55 160.12,-25.15"/>
|
||||
</g>
|
||||
<!-- Node5 -->
|
||||
<g id="node5" class="node">
|
||||
<title>Node5</title>
|
||||
<g id="a_node5"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/numeric/math/cos.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="292,-95.5 292,-114.5 344,-114.5 344,-95.5 292,-95.5"/>
|
||||
<text text-anchor="middle" x="318" y="-102.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::cos</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node4->Node5 -->
|
||||
<g id="edge4" class="edge">
|
||||
<title>Node4->Node5</title>
|
||||
<path fill="none" stroke="midnightblue" d="M239.28,-92.38C253.01,-94.61 268.32,-97.09 281.7,-99.27"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="281.52,-102.78 291.95,-100.93 282.64,-95.87 281.52,-102.78"/>
|
||||
</g>
|
||||
<!-- Node6 -->
|
||||
<g id="node6" class="node">
|
||||
<title>Node6</title>
|
||||
<g id="a_node6"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/numeric/math/sin.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="293.5,-57.5 293.5,-76.5 342.5,-76.5 342.5,-57.5 293.5,-57.5"/>
|
||||
<text text-anchor="middle" x="318" y="-64.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::sin</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node4->Node6 -->
|
||||
<g id="edge5" class="edge">
|
||||
<title>Node4->Node6</title>
|
||||
<path fill="none" stroke="midnightblue" d="M239.28,-79.62C253.57,-77.3 269.57,-74.7 283.33,-72.47"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="284.03,-75.9 293.34,-70.84 282.91,-68.99 284.03,-75.9"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 6.1 KiB |
@@ -0,0 +1,5 @@
|
||||
<map id="exact_solution" name="exact_solution">
|
||||
<area shape="rect" id="node1" title="Exact solution of the problem. Used for solution comparison." alt="" coords="5,31,112,57"/>
|
||||
<area shape="rect" id="node2" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/numeric/math/cos.html#" title=" " alt="" coords="160,5,229,32"/>
|
||||
<area shape="rect" id="node3" href="/Users/runner/runners/2.263.0/work/C-Plus-Plus/C-Plus-Plus/doc/cppreference-doxygen-web.tag.xml$cpp/numeric/math/sin.html#" title=" " alt="" coords="162,56,227,83"/>
|
||||
</map>
|
||||
@@ -0,0 +1 @@
|
||||
28f68d690a34e83ed529b0e7cf875a9c
|
||||
@@ -0,0 +1,52 @@
|
||||
<?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 2.44.0 (20200408.0750)
|
||||
-->
|
||||
<!-- Title: exact_solution Pages: 1 -->
|
||||
<svg width="176pt" height="66pt"
|
||||
viewBox="0.00 0.00 176.00 66.00" 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 62)">
|
||||
<title>exact_solution</title>
|
||||
<polygon fill="white" stroke="transparent" points="-4,4 -4,-62 172,-62 172,4 -4,4"/>
|
||||
<!-- Node1 -->
|
||||
<g id="node1" class="node">
|
||||
<title>Node1</title>
|
||||
<g id="a_node1"><a xlink:title="Exact solution of the problem. Used for solution comparison.">
|
||||
<polygon fill="#bfbfbf" stroke="black" points="0,-19.5 0,-38.5 80,-38.5 80,-19.5 0,-19.5"/>
|
||||
<text text-anchor="middle" x="40" y="-26.5" font-family="Helvetica,sans-Serif" font-size="10.00">exact_solution</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node2 -->
|
||||
<g id="node2" class="node">
|
||||
<title>Node2</title>
|
||||
<g id="a_node2"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/numeric/math/cos.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="116,-38.5 116,-57.5 168,-57.5 168,-38.5 116,-38.5"/>
|
||||
<text text-anchor="middle" x="142" y="-45.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::cos</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node2 -->
|
||||
<g id="edge1" class="edge">
|
||||
<title>Node1->Node2</title>
|
||||
<path fill="none" stroke="midnightblue" d="M80.24,-36.45C88.79,-38.08 97.79,-39.79 106.17,-41.38"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="105.52,-44.82 116,-43.25 106.83,-37.94 105.52,-44.82"/>
|
||||
</g>
|
||||
<!-- Node3 -->
|
||||
<g id="node3" class="node">
|
||||
<title>Node3</title>
|
||||
<g id="a_node3"><a target="_blank" xlink:href="http://en.cppreference.com/w/cpp/numeric/math/sin.html#" xlink:title=" ">
|
||||
<polygon fill="white" stroke="black" points="117.5,-0.5 117.5,-19.5 166.5,-19.5 166.5,-0.5 117.5,-0.5"/>
|
||||
<text text-anchor="middle" x="142" y="-7.5" font-family="Helvetica,sans-Serif" font-size="10.00">std::sin</text>
|
||||
</a>
|
||||
</g>
|
||||
</g>
|
||||
<!-- Node1->Node3 -->
|
||||
<g id="edge2" class="edge">
|
||||
<title>Node1->Node3</title>
|
||||
<path fill="none" stroke="midnightblue" d="M80.24,-21.55C89.28,-19.83 98.82,-18.01 107.59,-16.35"/>
|
||||
<polygon fill="midnightblue" stroke="midnightblue" points="108.29,-19.78 117.46,-14.47 106.98,-12.9 108.29,-19.78"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 2.4 KiB |
Reference in New Issue
Block a user