docs(docs): rebuilt docs with loads more detail for triggers and weak reactions
This commit is contained in:
@@ -444,7 +444,7 @@ GraphEngine Initialization</h3>
|
||||
<div class="line"> fourdst::composition::Composition comp;</div>
|
||||
<div class="line"> <a class="code hl_class" href="classgridfire_1_1_graph_engine.html">gridfire::GraphEngine</a> engine(comp);</div>
|
||||
<div class="line">}</div>
|
||||
<div class="ttc" id="aclassgridfire_1_1_graph_engine_html"><div class="ttname"><a href="classgridfire_1_1_graph_engine.html">gridfire::GraphEngine</a></div><div class="ttdoc">A reaction network engine that uses a graph-based representation.</div><div class="ttdef"><b>Definition</b> engine_graph.h:100</div></div>
|
||||
<div class="ttc" id="aclassgridfire_1_1_graph_engine_html"><div class="ttname"><a href="classgridfire_1_1_graph_engine.html">gridfire::GraphEngine</a></div><div class="ttdoc">A reaction network engine that uses a graph-based representation.</div><div class="ttdef"><b>Definition</b> engine_graph.h:97</div></div>
|
||||
<div class="ttc" id="aengine__graph_8h_html"><div class="ttname"><a href="engine__graph_8h.html">engine_graph.h</a></div></div>
|
||||
</div><!-- fragment --><h3><a class="anchor" id="autotoc_md48"></a>
|
||||
Adaptive Network View</h3>
|
||||
@@ -457,7 +457,7 @@ Adaptive Network View</h3>
|
||||
<div class="line"> <span class="comment">// Dynamically adapt network topology based on reaction flows</span></div>
|
||||
<div class="line"> <a class="code hl_class" href="classgridfire_1_1_adaptive_engine_view.html">gridfire::AdaptiveEngineView</a> adaptiveView(baseEngine);</div>
|
||||
<div class="line">}</div>
|
||||
<div class="ttc" id="aclassgridfire_1_1_adaptive_engine_view_html"><div class="ttname"><a href="classgridfire_1_1_adaptive_engine_view.html">gridfire::AdaptiveEngineView</a></div><div class="ttdoc">An engine view that dynamically adapts the reaction network based on runtime conditions.</div><div class="ttdef"><b>Definition</b> engine_adaptive.h:50</div></div>
|
||||
<div class="ttc" id="aclassgridfire_1_1_adaptive_engine_view_html"><div class="ttname"><a href="classgridfire_1_1_adaptive_engine_view.html">gridfire::AdaptiveEngineView</a></div><div class="ttdoc">An engine view that dynamically adapts the reaction network based on runtime conditions.</div><div class="ttdef"><b>Definition</b> engine_adaptive.h:49</div></div>
|
||||
<div class="ttc" id="aengine__adaptive_8h_html"><div class="ttname"><a href="engine__adaptive_8h.html">engine_adaptive.h</a></div></div>
|
||||
</div><!-- fragment --><h3><a class="anchor" id="autotoc_md49"></a>
|
||||
Composition Initialization</h3>
|
||||
@@ -524,7 +524,7 @@ Common Workflow Example</h3>
|
||||
<div class="line"> NetOut output = solver.evaluate(input);</div>
|
||||
<div class="line"> std::cout << <span class="stringliteral">"Final results are: "</span> << output << std::endl;</div>
|
||||
<div class="line">}</div>
|
||||
<div class="ttc" id="aclassgridfire_1_1_multiscale_partitioning_engine_view_html"><div class="ttname"><a href="classgridfire_1_1_multiscale_partitioning_engine_view.html">gridfire::MultiscalePartitioningEngineView</a></div><div class="ttdoc">An engine view that partitions the reaction network into multiple groups based on timescales.</div><div class="ttdef"><b>Definition</b> engine_multiscale.h:182</div></div>
|
||||
<div class="ttc" id="aclassgridfire_1_1_multiscale_partitioning_engine_view_html"><div class="ttname"><a href="classgridfire_1_1_multiscale_partitioning_engine_view.html">gridfire::MultiscalePartitioningEngineView</a></div><div class="ttdoc">An engine view that partitions the reaction network into multiple groups based on timescales.</div><div class="ttdef"><b>Definition</b> engine_multiscale.h:180</div></div>
|
||||
<div class="ttc" id="aengine_8h_html"><div class="ttname"><a href="engine_8h.html">engine.h</a></div><div class="ttdoc">Core header for the GridFire reaction network engine module.</div></div>
|
||||
<div class="ttc" id="asolver_8h_html"><div class="ttname"><a href="solver_8h.html">solver.h</a></div></div>
|
||||
</div><!-- fragment --><h4><a class="anchor" id="autotoc_md51"></a>
|
||||
@@ -546,11 +546,11 @@ Callback Example</h3>
|
||||
<div class="line"> </div>
|
||||
<div class="line"><span class="preprocessor">#include <iostream></span></div>
|
||||
<div class="line"> </div>
|
||||
<div class="line"><span class="keywordtype">void</span> callback(<span class="keyword">const</span> <a class="code hl_struct" href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html">gridfire::solver::DirectNetworkSolver::TimestepContext</a>& context) {</div>
|
||||
<div class="line"> <span class="keywordtype">int</span> H1Index = context.<a class="code hl_variable" href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#a53985d354dcaeda96dc39828c6c9d9d1">engine</a>.<a class="code hl_function" href="classgridfire_1_1_dynamic_engine.html#ad3d56a8b9161b9cc7f4da51f6bf7e8c9">getSpeciesIndex</a>(fourdst::atomic::H_1);</div>
|
||||
<div class="line"> <span class="keywordtype">int</span> He4Index = context.<a class="code hl_variable" href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#a53985d354dcaeda96dc39828c6c9d9d1">engine</a>.<a class="code hl_function" href="classgridfire_1_1_dynamic_engine.html#ad3d56a8b9161b9cc7f4da51f6bf7e8c9">getSpeciesIndex</a>(fourdst::atomic::He_4);</div>
|
||||
<div class="line"><span class="keywordtype">void</span> callback(<span class="keyword">const</span> gridfire::solver::DirectNetworkSolver::TimestepContext& context) {</div>
|
||||
<div class="line"> <span class="keywordtype">int</span> H1Index = context.engine.getSpeciesIndex(fourdst::atomic::H_1);</div>
|
||||
<div class="line"> <span class="keywordtype">int</span> He4Index = context.engine.getSpeciesIndex(fourdst::atomic::He_4);</div>
|
||||
<div class="line"> </div>
|
||||
<div class="line"> std::cout << context.<a class="code hl_variable" href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#ad49305586fdc676f96161e91c6b863dd">t</a> << <span class="stringliteral">","</span> << context.<a class="code hl_variable" href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#adab4b53a94b935f89f799bd5a67847a2">state</a>(H1Index) << <span class="stringliteral">","</span> << context.<a class="code hl_variable" href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#adab4b53a94b935f89f799bd5a67847a2">state</a>(He4Index) << <span class="stringliteral">"\n"</span>;</div>
|
||||
<div class="line"> std::cout << context.t << <span class="stringliteral">","</span> << context.state(H1Index) << <span class="stringliteral">","</span> << context.state(He4Index) << <span class="stringliteral">"\n"</span>;</div>
|
||||
<div class="line">}</div>
|
||||
<div class="line"> </div>
|
||||
<div class="line"><span class="keywordtype">int</span> main(){</div>
|
||||
@@ -591,11 +591,6 @@ Callback Example</h3>
|
||||
<div class="line"> NetOut output = solver.evaluate(input);</div>
|
||||
<div class="line"> std::cout << <span class="stringliteral">"Final results are: "</span> << output << std::endl;</div>
|
||||
<div class="line">}</div>
|
||||
<div class="ttc" id="aclassgridfire_1_1_dynamic_engine_html_ad3d56a8b9161b9cc7f4da51f6bf7e8c9"><div class="ttname"><a href="classgridfire_1_1_dynamic_engine.html#ad3d56a8b9161b9cc7f4da51f6bf7e8c9">gridfire::DynamicEngine::getSpeciesIndex</a></div><div class="ttdeci">virtual int getSpeciesIndex(const fourdst::atomic::Species &species) const =0</div><div class="ttdoc">Get the index of a species in the network.</div></div>
|
||||
<div class="ttc" id="astructgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context_html"><div class="ttname"><a href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html">gridfire::solver::DirectNetworkSolver::TimestepContext</a></div><div class="ttdoc">Context for the timestep callback function for the DirectNetworkSolver.</div><div class="ttdef"><b>Definition</b> solver.h:155</div></div>
|
||||
<div class="ttc" id="astructgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context_html_a53985d354dcaeda96dc39828c6c9d9d1"><div class="ttname"><a href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#a53985d354dcaeda96dc39828c6c9d9d1">gridfire::solver::DirectNetworkSolver::TimestepContext::engine</a></div><div class="ttdeci">const DynamicEngine & engine</div><div class="ttdoc">Reference to the dynamic engine.</div><div class="ttdef"><b>Definition</b> solver.h:166</div></div>
|
||||
<div class="ttc" id="astructgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context_html_ad49305586fdc676f96161e91c6b863dd"><div class="ttname"><a href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#ad49305586fdc676f96161e91c6b863dd">gridfire::solver::DirectNetworkSolver::TimestepContext::t</a></div><div class="ttdeci">const double t</div><div class="ttdoc">Current time.</div><div class="ttdef"><b>Definition</b> solver.h:156</div></div>
|
||||
<div class="ttc" id="astructgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context_html_adab4b53a94b935f89f799bd5a67847a2"><div class="ttname"><a href="structgridfire_1_1solver_1_1_direct_network_solver_1_1_timestep_context.html#adab4b53a94b935f89f799bd5a67847a2">gridfire::solver::DirectNetworkSolver::TimestepContext::state</a></div><div class="ttdeci">const boost::numeric::ublas::vector< double > & state</div><div class="ttdoc">Current state of the system.</div><div class="ttdef"><b>Definition</b> solver.h:157</div></div>
|
||||
</div><!-- fragment --><p>><b>Note:</b> A fully detailed list of all available information in the TimestepContext struct is available in the API documentation.</p>
|
||||
<p>><b>Note:</b> The order of species in the boost state vector (<code>ctx.state</code>) is <b>not guaranteed</b> to be any particular order run over run. Therefore, in order to reliably extract </p><blockquote class="doxtable">
|
||||
<p>values from it, you <b>must</b> use the <code>getSpeciesIndex</code> method of the engine to get the index of the species you are interested in (these will always be in the same order). </p>
|
||||
@@ -648,7 +643,7 @@ Common Workflow Example</h3>
|
||||
<div class="line">results = solver.evaluate(netIn)</div>
|
||||
<div class="line"> </div>
|
||||
<div class="line">print(f<span class="stringliteral">"Final H-1 mass fraction {results.composition.getMassFraction("</span>H-1<span class="stringliteral">")}"</span>)</div>
|
||||
<div class="ttc" id="anamespacegridfire_1_1solver_html"><div class="ttname"><a href="namespacegridfire_1_1solver.html">gridfire::solver</a></div><div class="ttdef"><b>Definition</b> solver.h:18</div></div>
|
||||
<div class="ttc" id="anamespacegridfire_1_1solver_html"><div class="ttname"><a href="namespacegridfire_1_1solver.html">gridfire::solver</a></div><div class="ttdef"><b>Definition</b> solver.h:12</div></div>
|
||||
</div><!-- fragment --><h3><a class="anchor" id="autotoc_md56"></a>
|
||||
Python callbacks</h3>
|
||||
<p>Just like in C++, python users can register callbacks to be called at the end of each successful timestep. Note that these may slow down code significantly as the interpreter needs to jump up into the slower python code therefore these should likely only be used for debugging purposes.</p>
|
||||
|
||||
Reference in New Issue
Block a user