Files
libcomposition/docs/html/classfourdst_1_1composition_1_1_composition.html

2888 lines
192 KiB
HTML

<!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" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.13.2"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>fourdst::libcomposition: fourdst::composition::Composition Class 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>
<script type="text/javascript" src="clipboard.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="cookie.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>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
<link href="doxygen-awesome-sidebar-only.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 id="projectrow">
<td id="projectalign">
<div id="projectname">fourdst::libcomposition<span id="projectnumber">&#160;v1.5.2</span>
</div>
<div id="projectbrief">Robust atomic species information library</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.13.2 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() { codefold.init(0); });
/* @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:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
initMenu('',true,false,'search.php','Search',true);
$(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:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){initNavTree('classfourdst_1_1composition_1_1_composition.html',''); initResizable(true); });
/* @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">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-static-methods">Static Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="#friends">Friends</a> &#124;
<a href="classfourdst_1_1composition_1_1_composition-members.html">List of all members</a> </div>
<div class="headertitle"><div class="title">fourdst::composition::Composition Class Reference</div></div>
</div><!--header-->
<div class="contents">
<p>Manages a collection of chemical species and their abundances.
<a href="#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="composition_8h_source.html">composition.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a23b83b76ee025f6fc009184ee19bba88" id="r_a23b83b76ee025f6fc009184ee19bba88"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> ()=default</td></tr>
<tr class="memdesc:a23b83b76ee025f6fc009184ee19bba88"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default constructor. <br /></td></tr>
<tr class="separator:a23b83b76ee025f6fc009184ee19bba88"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa3ff8ece122a9fad1252061148566749" id="r_aa3ff8ece122a9fad1252061148566749"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa3ff8ece122a9fad1252061148566749">~Composition</a> ()=default</td></tr>
<tr class="memdesc:aa3ff8ece122a9fad1252061148566749"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default destructor. <br /></td></tr>
<tr class="separator:aa3ff8ece122a9fad1252061148566749"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a72d063a74a9d2197065884a2cea57a14" id="r_a72d063a74a9d2197065884a2cea57a14"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a72d063a74a9d2197065884a2cea57a14">finalize</a> (bool norm=false)</td></tr>
<tr class="memdesc:a72d063a74a9d2197065884a2cea57a14"><td class="mdescLeft">&#160;</td><td class="mdescRight">Finalizes the composition, making it ready for querying. <br /></td></tr>
<tr class="separator:a72d063a74a9d2197065884a2cea57a14"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae3cc2099efd7db8eec3d9af2294b75fa" id="r_ae3cc2099efd7db8eec3d9af2294b75fa"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ae3cc2099efd7db8eec3d9af2294b75fa">Composition</a> (const std::vector&lt; std::string &gt; &amp;symbols)</td></tr>
<tr class="memdesc:ae3cc2099efd7db8eec3d9af2294b75fa"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> and registers the given symbols. <br /></td></tr>
<tr class="separator:ae3cc2099efd7db8eec3d9af2294b75fa"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2d6fbe5c8142b358641bbe7ffde51053" id="r_a2d6fbe5c8142b358641bbe7ffde51053"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a2d6fbe5c8142b358641bbe7ffde51053">Composition</a> (const std::set&lt; std::string &gt; &amp;symbols)</td></tr>
<tr class="memdesc:a2d6fbe5c8142b358641bbe7ffde51053"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> and registers the given symbols from a set. <br /></td></tr>
<tr class="separator:a2d6fbe5c8142b358641bbe7ffde51053"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af4d4cc5875cba931a91faee13f55594e" id="r_af4d4cc5875cba931a91faee13f55594e"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#af4d4cc5875cba931a91faee13f55594e">Composition</a> (const std::vector&lt; std::string &gt; &amp;symbols, const std::vector&lt; double &gt; &amp;fractions, bool massFracMode=true)</td></tr>
<tr class="memdesc:af4d4cc5875cba931a91faee13f55594e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs and finalizes a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> with the given symbols and fractions. <br /></td></tr>
<tr class="separator:af4d4cc5875cba931a91faee13f55594e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a21369a80378d4c90438a34f0e4a275ca" id="r_a21369a80378d4c90438a34f0e4a275ca"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a21369a80378d4c90438a34f0e4a275ca">Composition</a> (const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;composition)</td></tr>
<tr class="memdesc:a21369a80378d4c90438a34f0e4a275ca"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> from another <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a>. <br /></td></tr>
<tr class="separator:a21369a80378d4c90438a34f0e4a275ca"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4ec1e23cfecef764cb831171fed62fc2" id="r_a4ec1e23cfecef764cb831171fed62fc2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a4ec1e23cfecef764cb831171fed62fc2">operator=</a> (<a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> const &amp;other)</td></tr>
<tr class="memdesc:a4ec1e23cfecef764cb831171fed62fc2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assignment operator. <br /></td></tr>
<tr class="separator:a4ec1e23cfecef764cb831171fed62fc2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1bc2e64f87c12befdc2bc767e7405661" id="r_a1bc2e64f87c12befdc2bc767e7405661"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a> (const std::string &amp;symbol, bool massFracMode=true)</td></tr>
<tr class="memdesc:a1bc2e64f87c12befdc2bc767e7405661"><td class="mdescLeft">&#160;</td><td class="mdescRight">Registers a new symbol for inclusion in the composition. <br /></td></tr>
<tr class="separator:a1bc2e64f87c12befdc2bc767e7405661"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9b422156600823276a9606bfa07ad4db" id="r_a9b422156600823276a9606bfa07ad4db"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a9b422156600823276a9606bfa07ad4db">registerSymbol</a> (const std::vector&lt; std::string &gt; &amp;symbols, bool massFracMode=true)</td></tr>
<tr class="memdesc:a9b422156600823276a9606bfa07ad4db"><td class="mdescLeft">&#160;</td><td class="mdescRight">Registers multiple new symbols. <br /></td></tr>
<tr class="separator:a9b422156600823276a9606bfa07ad4db"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4ce00f73cc133bb1bac2b030b93ab480" id="r_a4ce00f73cc133bb1bac2b030b93ab480"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a4ce00f73cc133bb1bac2b030b93ab480">registerSpecies</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;species, bool massFracMode=true)</td></tr>
<tr class="memdesc:a4ce00f73cc133bb1bac2b030b93ab480"><td class="mdescLeft">&#160;</td><td class="mdescRight">Registers a new species by extracting its symbol. <br /></td></tr>
<tr class="separator:a4ce00f73cc133bb1bac2b030b93ab480"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a057f2bf2e86bcc3c649c0ddf18cf3826" id="r_a057f2bf2e86bcc3c649c0ddf18cf3826"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a057f2bf2e86bcc3c649c0ddf18cf3826">registerSpecies</a> (const std::vector&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt; &amp;species, bool massFracMode=true)</td></tr>
<tr class="memdesc:a057f2bf2e86bcc3c649c0ddf18cf3826"><td class="mdescLeft">&#160;</td><td class="mdescRight">Registers a vector of new species. <br /></td></tr>
<tr class="separator:a057f2bf2e86bcc3c649c0ddf18cf3826"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a84c7b72c2aee46b94492d404855dd3e0" id="r_a84c7b72c2aee46b94492d404855dd3e0"><td class="memItemLeft" align="right" valign="top">std::set&lt; std::string &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a84c7b72c2aee46b94492d404855dd3e0">getRegisteredSymbols</a> () const</td></tr>
<tr class="memdesc:a84c7b72c2aee46b94492d404855dd3e0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the registered symbols. <br /></td></tr>
<tr class="separator:a84c7b72c2aee46b94492d404855dd3e0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3dee7b5e1f54920de9eab99f95a516ec" id="r_a3dee7b5e1f54920de9eab99f95a516ec"><td class="memItemLeft" align="right" valign="top">std::set&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a3dee7b5e1f54920de9eab99f95a516ec">getRegisteredSpecies</a> () const</td></tr>
<tr class="memdesc:a3dee7b5e1f54920de9eab99f95a516ec"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a set of all species that are registered in the composition. <br /></td></tr>
<tr class="separator:a3dee7b5e1f54920de9eab99f95a516ec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a493224656aa3ade68389250720ef09af" id="r_a493224656aa3ade68389250720ef09af"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a493224656aa3ade68389250720ef09af">setMassFraction</a> (const std::string &amp;symbol, const double &amp;mass_fraction)</td></tr>
<tr class="memdesc:a493224656aa3ade68389250720ef09af"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the mass fraction for a given symbol. <br /></td></tr>
<tr class="separator:a493224656aa3ade68389250720ef09af"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a66ce1012c12b0a83629eb09d451b68e3" id="r_a66ce1012c12b0a83629eb09d451b68e3"><td class="memItemLeft" align="right" valign="top">std::vector&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a66ce1012c12b0a83629eb09d451b68e3">setMassFraction</a> (const std::vector&lt; std::string &gt; &amp;symbols, const std::vector&lt; double &gt; &amp;mass_fractions)</td></tr>
<tr class="memdesc:a66ce1012c12b0a83629eb09d451b68e3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the mass fraction for multiple symbols. <br /></td></tr>
<tr class="separator:a66ce1012c12b0a83629eb09d451b68e3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa6c94269a5d16349c98860f3015b734a" id="r_aa6c94269a5d16349c98860f3015b734a"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa6c94269a5d16349c98860f3015b734a">setMassFraction</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;species, const double &amp;mass_fraction)</td></tr>
<tr class="memdesc:aa6c94269a5d16349c98860f3015b734a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the mass fraction for a given species. <br /></td></tr>
<tr class="separator:aa6c94269a5d16349c98860f3015b734a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abbae020d46c74708a7974c1ca755bb62" id="r_abbae020d46c74708a7974c1ca755bb62"><td class="memItemLeft" align="right" valign="top">std::vector&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#abbae020d46c74708a7974c1ca755bb62">setMassFraction</a> (const std::vector&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt; &amp;species, const std::vector&lt; double &gt; &amp;mass_fractions)</td></tr>
<tr class="memdesc:abbae020d46c74708a7974c1ca755bb62"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the mass fraction for multiple species. <br /></td></tr>
<tr class="separator:abbae020d46c74708a7974c1ca755bb62"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7d4d748f3ee25e68751fb143717ed080" id="r_a7d4d748f3ee25e68751fb143717ed080"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a7d4d748f3ee25e68751fb143717ed080">setNumberFraction</a> (const std::string &amp;symbol, const double &amp;number_fraction)</td></tr>
<tr class="memdesc:a7d4d748f3ee25e68751fb143717ed080"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the number fraction for a given symbol. <br /></td></tr>
<tr class="separator:a7d4d748f3ee25e68751fb143717ed080"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a48014a0a725ebd91ad1193c063b5b26f" id="r_a48014a0a725ebd91ad1193c063b5b26f"><td class="memItemLeft" align="right" valign="top">std::vector&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a48014a0a725ebd91ad1193c063b5b26f">setNumberFraction</a> (const std::vector&lt; std::string &gt; &amp;symbols, const std::vector&lt; double &gt; &amp;number_fractions)</td></tr>
<tr class="memdesc:a48014a0a725ebd91ad1193c063b5b26f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the number fraction for multiple symbols. <br /></td></tr>
<tr class="separator:a48014a0a725ebd91ad1193c063b5b26f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aaa822bb48a948d101fef759ffbefe31b" id="r_aaa822bb48a948d101fef759ffbefe31b"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aaa822bb48a948d101fef759ffbefe31b">setNumberFraction</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;species, const double &amp;number_fraction)</td></tr>
<tr class="memdesc:aaa822bb48a948d101fef759ffbefe31b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the number fraction for a given species. <br /></td></tr>
<tr class="separator:aaa822bb48a948d101fef759ffbefe31b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adc068778a1ef33cad67f5ca028b49bb8" id="r_adc068778a1ef33cad67f5ca028b49bb8"><td class="memItemLeft" align="right" valign="top">std::vector&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#adc068778a1ef33cad67f5ca028b49bb8">setNumberFraction</a> (const std::vector&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt; &amp;species, const std::vector&lt; double &gt; &amp;number_fractions)</td></tr>
<tr class="memdesc:adc068778a1ef33cad67f5ca028b49bb8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the number fraction for multiple species. <br /></td></tr>
<tr class="separator:adc068778a1ef33cad67f5ca028b49bb8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3aead72892606725a4149a5f65bd31ec" id="r_a3aead72892606725a4149a5f65bd31ec"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a3aead72892606725a4149a5f65bd31ec">mix</a> (const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;other, double fraction) const</td></tr>
<tr class="memdesc:a3aead72892606725a4149a5f65bd31ec"><td class="mdescLeft">&#160;</td><td class="mdescRight">Mixes this composition with another to produce a new composition. <br /></td></tr>
<tr class="separator:a3aead72892606725a4149a5f65bd31ec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad20bd541dd7c45274a2e586e6a0519a7" id="r_ad20bd541dd7c45274a2e586e6a0519a7"><td class="memItemLeft" align="right" valign="top">std::unordered_map&lt; std::string, double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ad20bd541dd7c45274a2e586e6a0519a7">getMassFraction</a> () const</td></tr>
<tr class="memdesc:ad20bd541dd7c45274a2e586e6a0519a7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the mass fractions of all species in the composition. <br /></td></tr>
<tr class="separator:ad20bd541dd7c45274a2e586e6a0519a7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7f6a6edf02b55eeecf147c3f1f7f55e7" id="r_a7f6a6edf02b55eeecf147c3f1f7f55e7"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a7f6a6edf02b55eeecf147c3f1f7f55e7">getMassFraction</a> (const std::string &amp;symbol) const</td></tr>
<tr class="memdesc:a7f6a6edf02b55eeecf147c3f1f7f55e7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the mass fraction for a given symbol. <br /></td></tr>
<tr class="separator:a7f6a6edf02b55eeecf147c3f1f7f55e7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa3ba0c742872384cff3ed03789c0a17d" id="r_aa3ba0c742872384cff3ed03789c0a17d"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa3ba0c742872384cff3ed03789c0a17d">getMassFraction</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;species) const</td></tr>
<tr class="memdesc:aa3ba0c742872384cff3ed03789c0a17d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the mass fraction for a given isotope. <br /></td></tr>
<tr class="separator:aa3ba0c742872384cff3ed03789c0a17d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a84fea38bc1c005e483910285f6800e15" id="r_a84fea38bc1c005e483910285f6800e15"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a84fea38bc1c005e483910285f6800e15">getNumberFraction</a> (const std::string &amp;symbol) const</td></tr>
<tr class="memdesc:a84fea38bc1c005e483910285f6800e15"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the number fraction for a given symbol. <br /></td></tr>
<tr class="separator:a84fea38bc1c005e483910285f6800e15"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa0ce4143a267e96ab7967538c76acdc3" id="r_aa0ce4143a267e96ab7967538c76acdc3"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa0ce4143a267e96ab7967538c76acdc3">getNumberFraction</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;species) const</td></tr>
<tr class="memdesc:aa0ce4143a267e96ab7967538c76acdc3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the number fraction for a given isotope. <br /></td></tr>
<tr class="separator:aa0ce4143a267e96ab7967538c76acdc3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7731df9b30f8c8f13231f7e1a17b105c" id="r_a7731df9b30f8c8f13231f7e1a17b105c"><td class="memItemLeft" align="right" valign="top">std::unordered_map&lt; std::string, double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a7731df9b30f8c8f13231f7e1a17b105c">getNumberFraction</a> () const</td></tr>
<tr class="memdesc:a7731df9b30f8c8f13231f7e1a17b105c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the number fractions of all species in the composition. <br /></td></tr>
<tr class="separator:a7731df9b30f8c8f13231f7e1a17b105c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a67a2ed844f3aee3d9cc1a3cb996eb56f" id="r_a67a2ed844f3aee3d9cc1a3cb996eb56f"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a67a2ed844f3aee3d9cc1a3cb996eb56f">getMolarAbundance</a> (const std::string &amp;symbol) const</td></tr>
<tr class="memdesc:a67a2ed844f3aee3d9cc1a3cb996eb56f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the molar abundance (X_i / A_i) for a given symbol. <br /></td></tr>
<tr class="separator:a67a2ed844f3aee3d9cc1a3cb996eb56f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a84d6552e2b762fabb7bddf68b05c4022" id="r_a84d6552e2b762fabb7bddf68b05c4022"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a84d6552e2b762fabb7bddf68b05c4022">getMolarAbundance</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;species) const</td></tr>
<tr class="memdesc:a84d6552e2b762fabb7bddf68b05c4022"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the molar abundance for a given isotope. <br /></td></tr>
<tr class="separator:a84d6552e2b762fabb7bddf68b05c4022"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a092d3536b04167ea2e6e3a3b1446c377" id="r_a092d3536b04167ea2e6e3a3b1446c377"><td class="memItemLeft" align="right" valign="top">std::pair&lt; <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a>, <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html">GlobalComposition</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a092d3536b04167ea2e6e3a3b1446c377">getComposition</a> (const std::string &amp;symbol) const</td></tr>
<tr class="memdesc:a092d3536b04167ea2e6e3a3b1446c377"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the composition entry and global composition data for a given symbol. <br /></td></tr>
<tr class="separator:a092d3536b04167ea2e6e3a3b1446c377"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afe5f1086027044c84ff35a366b2e8e2d" id="r_afe5f1086027044c84ff35a366b2e8e2d"><td class="memItemLeft" align="right" valign="top">std::pair&lt; <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a>, <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html">GlobalComposition</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#afe5f1086027044c84ff35a366b2e8e2d">getComposition</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;species) const</td></tr>
<tr class="memdesc:afe5f1086027044c84ff35a366b2e8e2d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the composition entry and global composition data for a given species. <br /></td></tr>
<tr class="separator:afe5f1086027044c84ff35a366b2e8e2d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1138c86f7ccd39594601c2ec63ad89e9" id="r_a1138c86f7ccd39594601c2ec63ad89e9"><td class="memItemLeft" align="right" valign="top">std::pair&lt; std::unordered_map&lt; std::string, <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a> &gt;, <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html">GlobalComposition</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a1138c86f7ccd39594601c2ec63ad89e9">getComposition</a> () const</td></tr>
<tr class="memdesc:a1138c86f7ccd39594601c2ec63ad89e9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets all composition entries and the global composition data. <br /></td></tr>
<tr class="separator:a1138c86f7ccd39594601c2ec63ad89e9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a66401fed7054172e9b1a2687e5cc8eff" id="r_a66401fed7054172e9b1a2687e5cc8eff"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a66401fed7054172e9b1a2687e5cc8eff">getMeanParticleMass</a> () const</td></tr>
<tr class="memdesc:a66401fed7054172e9b1a2687e5cc8eff"><td class="mdescLeft">&#160;</td><td class="mdescRight">Compute the mean particle mass of the composition. <br /></td></tr>
<tr class="separator:a66401fed7054172e9b1a2687e5cc8eff"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a98199f435cb553f5cf4f8e520fdb8a7a" id="r_a98199f435cb553f5cf4f8e520fdb8a7a"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a98199f435cb553f5cf4f8e520fdb8a7a">getMeanAtomicNumber</a> () const</td></tr>
<tr class="memdesc:a98199f435cb553f5cf4f8e520fdb8a7a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Compute the mean atomic number of the composition. <br /></td></tr>
<tr class="separator:a98199f435cb553f5cf4f8e520fdb8a7a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a17635cd21744c7cf86cb1eb75152c816" id="r_a17635cd21744c7cf86cb1eb75152c816"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a17635cd21744c7cf86cb1eb75152c816">subset</a> (const std::vector&lt; std::string &gt; &amp;symbols, const std::string &amp;method=&quot;norm&quot;) const</td></tr>
<tr class="memdesc:a17635cd21744c7cf86cb1eb75152c816"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a new <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> object containing a subset of species from this one. <br /></td></tr>
<tr class="separator:a17635cd21744c7cf86cb1eb75152c816"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a72a368f27094b03fdd9896844e075c94" id="r_a72a368f27094b03fdd9896844e075c94"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a72a368f27094b03fdd9896844e075c94">hasSymbol</a> (const std::string &amp;symbol) const</td></tr>
<tr class="memdesc:a72a368f27094b03fdd9896844e075c94"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if a symbol is registered in the composition. <br /></td></tr>
<tr class="separator:a72a368f27094b03fdd9896844e075c94"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acb08478f7032ecc13cb02283a18187e9" id="r_acb08478f7032ecc13cb02283a18187e9"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#acb08478f7032ecc13cb02283a18187e9">contains</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;isotope) const</td></tr>
<tr class="memdesc:acb08478f7032ecc13cb02283a18187e9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if a given isotope is present in the composition. <br /></td></tr>
<tr class="separator:acb08478f7032ecc13cb02283a18187e9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0af981ed1074b26c237cf6cf35f82c9e" id="r_a0af981ed1074b26c237cf6cf35f82c9e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a0af981ed1074b26c237cf6cf35f82c9e">setCompositionMode</a> (bool massFracMode)</td></tr>
<tr class="memdesc:a0af981ed1074b26c237cf6cf35f82c9e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the composition mode (mass fraction vs. number fraction). <br /></td></tr>
<tr class="separator:a0af981ed1074b26c237cf6cf35f82c9e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac75dbc8377556c835455991c7c7fe206" id="r_ac75dbc8377556c835455991c7c7fe206"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structfourdst_1_1composition_1_1_canonical_composition.html">CanonicalComposition</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ac75dbc8377556c835455991c7c7fe206">getCanonicalComposition</a> (bool harsh=false) const</td></tr>
<tr class="memdesc:ac75dbc8377556c835455991c7c7fe206"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the current canonical composition (X, Y, Z). <br /></td></tr>
<tr class="separator:ac75dbc8377556c835455991c7c7fe206"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acdbdf980297580e885ce3f124164315f" id="r_acdbdf980297580e885ce3f124164315f"><td class="memItemLeft" align="right" valign="top">std::vector&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#acdbdf980297580e885ce3f124164315f">getMassFractionVector</a> () const</td></tr>
<tr class="memdesc:acdbdf980297580e885ce3f124164315f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a uniform vector representation of the mass fraction stored in the composition object sorted such that the lightest species is at index 0 and the heaviest is at the last index. <br /></td></tr>
<tr class="separator:acdbdf980297580e885ce3f124164315f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2a41242de5d49b005e0b608e79e2f2d9" id="r_a2a41242de5d49b005e0b608e79e2f2d9"><td class="memItemLeft" align="right" valign="top">std::vector&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a2a41242de5d49b005e0b608e79e2f2d9">getNumberFractionVector</a> () const</td></tr>
<tr class="memdesc:a2a41242de5d49b005e0b608e79e2f2d9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a uniform vector representation of the number fractions stored in the composition object sorted such that the lightest species is at index 0 and the heaviest is at the last index. <br /></td></tr>
<tr class="separator:a2a41242de5d49b005e0b608e79e2f2d9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a84d62b971bee83d944d2792c6850bc0b" id="r_a84d62b971bee83d944d2792c6850bc0b"><td class="memItemLeft" align="right" valign="top">std::vector&lt; double &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a84d62b971bee83d944d2792c6850bc0b">getMolarAbundanceVector</a> () const</td></tr>
<tr class="memdesc:a84d62b971bee83d944d2792c6850bc0b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a uniform vector representation of the molar abundances stored in the composition object sorted such that the lightest species is at index 0 and the heaviest is at the last index. <br /></td></tr>
<tr class="separator:a84d62b971bee83d944d2792c6850bc0b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1204a6421205feaaed13937aefa158ba" id="r_a1204a6421205feaaed13937aefa158ba"><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a1204a6421205feaaed13937aefa158ba">getSpeciesIndex</a> (const std::string &amp;symbol) const</td></tr>
<tr class="memdesc:a1204a6421205feaaed13937aefa158ba"><td class="mdescLeft">&#160;</td><td class="mdescRight">get the index in the sorted vector representation for a given symbol <br /></td></tr>
<tr class="separator:a1204a6421205feaaed13937aefa158ba"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad49012cd6d78558d80198cc06ec164b1" id="r_ad49012cd6d78558d80198cc06ec164b1"><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ad49012cd6d78558d80198cc06ec164b1">getSpeciesIndex</a> (const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">atomic::Species</a> &amp;species) const</td></tr>
<tr class="memdesc:ad49012cd6d78558d80198cc06ec164b1"><td class="mdescLeft">&#160;</td><td class="mdescRight">get the index in the sorted vector representation for a given symbol <br /></td></tr>
<tr class="separator:ad49012cd6d78558d80198cc06ec164b1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa534a01f24074cc9edd7f41df228eb50" id="r_aa534a01f24074cc9edd7f41df228eb50"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structfourdst_1_1atomic_1_1_species.html">atomic::Species</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa534a01f24074cc9edd7f41df228eb50">getSpeciesAtIndex</a> (size_t index) const</td></tr>
<tr class="memdesc:aa534a01f24074cc9edd7f41df228eb50"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the species at a given index in the sorted vector representation. <br /></td></tr>
<tr class="separator:aa534a01f24074cc9edd7f41df228eb50"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a24a3bdeb8e8e55b54ecdee6dcb0d9561" id="r_a24a3bdeb8e8e55b54ecdee6dcb0d9561"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a24a3bdeb8e8e55b54ecdee6dcb0d9561">operator+</a> (const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;other) const</td></tr>
<tr class="memdesc:a24a3bdeb8e8e55b54ecdee6dcb0d9561"><td class="mdescLeft">&#160;</td><td class="mdescRight">Overloads the + operator to mix two compositions with a 50/50 fraction. <br /></td></tr>
<tr class="separator:a24a3bdeb8e8e55b54ecdee6dcb0d9561"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab1701644ff1c83c220dc04eb58d1621b" id="r_ab1701644ff1c83c220dc04eb58d1621b"><td class="memItemLeft" align="right" valign="top">auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ab1701644ff1c83c220dc04eb58d1621b">begin</a> ()</td></tr>
<tr class="memdesc:ab1701644ff1c83c220dc04eb58d1621b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns an iterator to the beginning of the composition map. <br /></td></tr>
<tr class="separator:ab1701644ff1c83c220dc04eb58d1621b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adf41a833e8b704daf4f581fca5c8cb9b" id="r_adf41a833e8b704daf4f581fca5c8cb9b"><td class="memItemLeft" align="right" valign="top">auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#adf41a833e8b704daf4f581fca5c8cb9b">begin</a> () const</td></tr>
<tr class="memdesc:adf41a833e8b704daf4f581fca5c8cb9b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a const iterator to the beginning of the composition map. <br /></td></tr>
<tr class="separator:adf41a833e8b704daf4f581fca5c8cb9b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adeaf6f1213e78cb1fe8a8317f0a8adc2" id="r_adeaf6f1213e78cb1fe8a8317f0a8adc2"><td class="memItemLeft" align="right" valign="top">auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#adeaf6f1213e78cb1fe8a8317f0a8adc2">end</a> ()</td></tr>
<tr class="memdesc:adeaf6f1213e78cb1fe8a8317f0a8adc2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns an iterator to the end of the composition map. <br /></td></tr>
<tr class="separator:adeaf6f1213e78cb1fe8a8317f0a8adc2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aed2f5676f8f742199f01e4d1e9664bdd" id="r_aed2f5676f8f742199f01e4d1e9664bdd"><td class="memItemLeft" align="right" valign="top">auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aed2f5676f8f742199f01e4d1e9664bdd">end</a> () const</td></tr>
<tr class="memdesc:aed2f5676f8f742199f01e4d1e9664bdd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a const iterator to the end of the composition map. <br /></td></tr>
<tr class="separator:aed2f5676f8f742199f01e4d1e9664bdd"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-methods" name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr class="memitem:addf03ba8b988970d341884d487aa94d5" id="r_addf03ba8b988970d341884d487aa94d5"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#addf03ba8b988970d341884d487aa94d5">isValidComposition</a> (const std::vector&lt; double &gt; &amp;fractions) const</td></tr>
<tr class="memdesc:addf03ba8b988970d341884d487aa94d5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if the given fractions are valid (sum to ~1.0). <br /></td></tr>
<tr class="separator:addf03ba8b988970d341884d487aa94d5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a86982685c34db4a8f079ddafc25c594e" id="r_a86982685c34db4a8f079ddafc25c594e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a86982685c34db4a8f079ddafc25c594e">validateComposition</a> (const std::vector&lt; double &gt; &amp;fractions) const</td></tr>
<tr class="memdesc:a86982685c34db4a8f079ddafc25c594e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Validates the given fractions, throwing an exception on failure. <br /></td></tr>
<tr class="separator:a86982685c34db4a8f079ddafc25c594e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a869dbae3db9d09c57b2df56a813a55fb" id="r_a869dbae3db9d09c57b2df56a813a55fb"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a869dbae3db9d09c57b2df56a813a55fb">finalizeMassFracMode</a> (bool norm)</td></tr>
<tr class="memdesc:a869dbae3db9d09c57b2df56a813a55fb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Finalizes the composition in mass fraction mode. <br /></td></tr>
<tr class="separator:a869dbae3db9d09c57b2df56a813a55fb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a461ab4e9cb5975cf865db5f16f03ddfe" id="r_a461ab4e9cb5975cf865db5f16f03ddfe"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a461ab4e9cb5975cf865db5f16f03ddfe">finalizeNumberFracMode</a> (bool norm)</td></tr>
<tr class="memdesc:a461ab4e9cb5975cf865db5f16f03ddfe"><td class="mdescLeft">&#160;</td><td class="mdescRight">Finalizes the composition in number fraction mode. <br /></td></tr>
<tr class="separator:a461ab4e9cb5975cf865db5f16f03ddfe"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-static-methods" name="pri-static-methods"></a>
Static Private Member Functions</h2></td></tr>
<tr class="memitem:a8fdac26e6298008aaeaa5b15f7fe244f" id="r_a8fdac26e6298008aaeaa5b15f7fe244f"><td class="memItemLeft" align="right" valign="top">static bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a8fdac26e6298008aaeaa5b15f7fe244f">isValidSymbol</a> (const std::string &amp;symbol)</td></tr>
<tr class="memdesc:a8fdac26e6298008aaeaa5b15f7fe244f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if the given symbol is valid by checking against the global species database. <br /></td></tr>
<tr class="separator:a8fdac26e6298008aaeaa5b15f7fe244f"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-attribs" name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:a8a8096863464338bc6e3c5124407dca4" id="r_a8a8096863464338bc6e3c5124407dca4"><td class="memItemLeft" align="right" valign="top">fourdst::config::Config &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a8a8096863464338bc6e3c5124407dca4">m_config</a> = fourdst::config::Config::getInstance()</td></tr>
<tr class="separator:a8a8096863464338bc6e3c5124407dca4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a695d37ec6cde63d86a20df1e9f26af19" id="r_a695d37ec6cde63d86a20df1e9f26af19"><td class="memItemLeft" align="right" valign="top">fourdst::logging::LogManager &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a695d37ec6cde63d86a20df1e9f26af19">m_logManager</a> = fourdst::logging::LogManager::getInstance()</td></tr>
<tr class="separator:a695d37ec6cde63d86a20df1e9f26af19"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab6c66f35e1fb05dd24aacaf90e115c5e" id="r_ab6c66f35e1fb05dd24aacaf90e115c5e"><td class="memItemLeft" align="right" valign="top">quill::Logger *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ab6c66f35e1fb05dd24aacaf90e115c5e">m_logger</a> = m_logManager.getLogger(&quot;log&quot;)</td></tr>
<tr class="separator:ab6c66f35e1fb05dd24aacaf90e115c5e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa00cbc0933d8a22bb900ac21a338e5ac" id="r_aa00cbc0933d8a22bb900ac21a338e5ac"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa00cbc0933d8a22bb900ac21a338e5ac">m_finalized</a> = false</td></tr>
<tr class="memdesc:aa00cbc0933d8a22bb900ac21a338e5ac"><td class="mdescLeft">&#160;</td><td class="mdescRight">True if the composition is finalized. <br /></td></tr>
<tr class="separator:aa00cbc0933d8a22bb900ac21a338e5ac"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:addae4484da7d5072ab66a721dbe04ced" id="r_addae4484da7d5072ab66a721dbe04ced"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#addae4484da7d5072ab66a721dbe04ced">m_specificNumberDensity</a> = 0.0</td></tr>
<tr class="memdesc:addae4484da7d5072ab66a721dbe04ced"><td class="mdescLeft">&#160;</td><td class="mdescRight">The specific number density of the composition (\sum_{i} X_i m_i. Where X_i is the number fraction of the ith species and m_i is the mass of the ith species). <br /></td></tr>
<tr class="separator:addae4484da7d5072ab66a721dbe04ced"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4a36c8d22ce61023e7bea1d9417577d4" id="r_a4a36c8d22ce61023e7bea1d9417577d4"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a4a36c8d22ce61023e7bea1d9417577d4">m_meanParticleMass</a> = 0.0</td></tr>
<tr class="memdesc:a4a36c8d22ce61023e7bea1d9417577d4"><td class="mdescLeft">&#160;</td><td class="mdescRight">The mean particle mass of the composition (\sum_{i} \frac{n_i}{m_i}. where n_i is the number fraction of the ith species and m_i is the mass of the ith species). <br /></td></tr>
<tr class="separator:a4a36c8d22ce61023e7bea1d9417577d4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a671f1ee8be00f4ff8c1d94fabb382380" id="r_a671f1ee8be00f4ff8c1d94fabb382380"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a671f1ee8be00f4ff8c1d94fabb382380">m_massFracMode</a> = true</td></tr>
<tr class="memdesc:a671f1ee8be00f4ff8c1d94fabb382380"><td class="mdescLeft">&#160;</td><td class="mdescRight">True if mass fraction mode, false if number fraction mode. <br /></td></tr>
<tr class="separator:a671f1ee8be00f4ff8c1d94fabb382380"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a39bfcb7d81d723cbd9d021abd533b4d6" id="r_a39bfcb7d81d723cbd9d021abd533b4d6"><td class="memItemLeft" align="right" valign="top">std::set&lt; std::string &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a39bfcb7d81d723cbd9d021abd533b4d6">m_registeredSymbols</a></td></tr>
<tr class="memdesc:a39bfcb7d81d723cbd9d021abd533b4d6"><td class="mdescLeft">&#160;</td><td class="mdescRight">The registered symbols. <br /></td></tr>
<tr class="separator:a39bfcb7d81d723cbd9d021abd533b4d6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa7f2753b10e85ae3bbf0c3d600a973db" id="r_aa7f2753b10e85ae3bbf0c3d600a973db"><td class="memItemLeft" align="right" valign="top">std::unordered_map&lt; std::string, <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa7f2753b10e85ae3bbf0c3d600a973db">m_compositions</a></td></tr>
<tr class="memdesc:aa7f2753b10e85ae3bbf0c3d600a973db"><td class="mdescLeft">&#160;</td><td class="mdescRight">The compositions. <br /></td></tr>
<tr class="separator:aa7f2753b10e85ae3bbf0c3d600a973db"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="friends" name="friends"></a>
Friends</h2></td></tr>
<tr class="memitem:a36c2525d21cd932065bb2bb30bc57fb4" id="r_a36c2525d21cd932065bb2bb30bc57fb4"><td class="memItemLeft" align="right" valign="top">std::ostream &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a36c2525d21cd932065bb2bb30bc57fb4">operator&lt;&lt;</a> (std::ostream &amp;os, const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;composition)</td></tr>
<tr class="memdesc:a36c2525d21cd932065bb2bb30bc57fb4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Overloaded output stream operator for <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a>. <br /></td></tr>
<tr class="separator:a36c2525d21cd932065bb2bb30bc57fb4"><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>Manages a collection of chemical species and their abundances. </p>
<p>This class is a primary interface for defining and manipulating material compositions. It can operate in two modes: mass fraction or number fraction.</p>
<p><b>Key Rules and Workflow:</b></p><ol type="1">
<li><b>Registration:</b> Before setting an abundance for a species, its symbol (e.g., "He-4") must be registered using <code><a class="el" href="#a1bc2e64f87c12befdc2bc767e7405661" title="Registers a new symbol for inclusion in the composition.">registerSymbol()</a></code> or <code><a class="el" href="#a4ce00f73cc133bb1bac2b030b93ab480" title="Registers a new species by extracting its symbol.">registerSpecies()</a></code>. All registered species must conform to the same abundance mode (mass or number fraction).</li>
<li><b>Setting Abundances:</b> Use <code><a class="el" href="#a493224656aa3ade68389250720ef09af" title="Sets the mass fraction for a given symbol.">setMassFraction()</a></code> or <code><a class="el" href="#a7d4d748f3ee25e68751fb143717ed080" title="Sets the number fraction for a given symbol.">setNumberFraction()</a></code> to define the composition.</li>
<li><b>Finalization:</b> Before querying any compositional data (e.g., <code><a class="el" href="#ad20bd541dd7c45274a2e586e6a0519a7" title="Gets the mass fractions of all species in the composition.">getMassFraction()</a></code>, <code><a class="el" href="#a66401fed7054172e9b1a2687e5cc8eff" title="Compute the mean particle mass of the composition.">getMeanParticleMass()</a></code>), the composition must be <b>finalized</b> by calling <code><a class="el" href="#a72d063a74a9d2197065884a2cea57a14" title="Finalizes the composition, making it ready for querying.">finalize()</a></code>. This step validates the composition (abundances sum to ~1.0) and computes global properties.</li>
<li><b>Modification:</b> Any modification to abundances after finalization will un-finalize the composition, requiring another call to <code><a class="el" href="#a72d063a74a9d2197065884a2cea57a14" title="Finalizes the composition, making it ready for querying.">finalize()</a></code> before data can be retrieved again.</li>
<li><b>Construction:</b> A pre-finalized composition can be created by providing symbols and valid, normalized abundances to the constructor.</li>
</ol>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname">This</td><td>class throws various exceptions from <code><a class="el" href="namespacefourdst_1_1composition_1_1exceptions.html">fourdst::composition::exceptions</a></code> for invalid operations, such as using unregistered symbols, providing invalid abundances, or accessing data from a non-finalized composition.</td></tr>
</table>
</dd>
</dl>
<dl class="section user"><dt>Mass Fraction Example:</dt><dd><div class="fragment"><div class="line"><a class="code hl_function" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> comp;</div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(<span class="stringliteral">&quot;H-1&quot;</span>);</div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(<span class="stringliteral">&quot;He-4&quot;</span>);</div>
<div class="line">comp.<a class="code hl_function" href="#a493224656aa3ade68389250720ef09af">setMassFraction</a>(<span class="stringliteral">&quot;H-1&quot;</span>, 0.75);</div>
<div class="line">comp.<a class="code hl_function" href="#a493224656aa3ade68389250720ef09af">setMassFraction</a>(<span class="stringliteral">&quot;He-4&quot;</span>, 0.25);</div>
<div class="line"><span class="keywordflow">if</span> (comp.<a class="code hl_function" href="#a72d063a74a9d2197065884a2cea57a14">finalize</a>()) {</div>
<div class="line"> <span class="keywordtype">double</span> he_mass_frac = comp.<a class="code hl_function" href="#ad20bd541dd7c45274a2e586e6a0519a7">getMassFraction</a>(<span class="stringliteral">&quot;He-4&quot;</span>); <span class="comment">// Returns 0.25</span></div>
<div class="line">}</div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_a1bc2e64f87c12befdc2bc767e7405661"><div class="ttname"><a href="#a1bc2e64f87c12befdc2bc767e7405661">fourdst::composition::Composition::registerSymbol</a></div><div class="ttdeci">void registerSymbol(const std::string &amp;symbol, bool massFracMode=true)</div><div class="ttdoc">Registers a new symbol for inclusion in the composition.</div><div class="ttdef"><b>Definition</b> <a href="composition_8cpp_source.html#l00233">composition.cpp:233</a></div></div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_a23b83b76ee025f6fc009184ee19bba88"><div class="ttname"><a href="#a23b83b76ee025f6fc009184ee19bba88">fourdst::composition::Composition::Composition</a></div><div class="ttdeci">Composition()=default</div><div class="ttdoc">Default constructor.</div></div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_a493224656aa3ade68389250720ef09af"><div class="ttname"><a href="#a493224656aa3ade68389250720ef09af">fourdst::composition::Composition::setMassFraction</a></div><div class="ttdeci">double setMassFraction(const std::string &amp;symbol, const double &amp;mass_fraction)</div><div class="ttdoc">Sets the mass fraction for a given symbol.</div><div class="ttdef"><b>Definition</b> <a href="composition_8cpp_source.html#l00312">composition.cpp:312</a></div></div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_a72d063a74a9d2197065884a2cea57a14"><div class="ttname"><a href="#a72d063a74a9d2197065884a2cea57a14">fourdst::composition::Composition::finalize</a></div><div class="ttdeci">bool finalize(bool norm=false)</div><div class="ttdoc">Finalizes the composition, making it ready for querying.</div><div class="ttdef"><b>Definition</b> <a href="composition_8cpp_source.html#l00414">composition.cpp:414</a></div></div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_ad20bd541dd7c45274a2e586e6a0519a7"><div class="ttname"><a href="#ad20bd541dd7c45274a2e586e6a0519a7">fourdst::composition::Composition::getMassFraction</a></div><div class="ttdeci">std::unordered_map&lt; std::string, double &gt; getMassFraction() const</div><div class="ttdoc">Gets the mass fractions of all species in the composition.</div><div class="ttdef"><b>Definition</b> <a href="composition_8cpp_source.html#l00559">composition.cpp:559</a></div></div>
</div><!-- fragment --></dd></dl>
<dl class="section user"><dt>Number Fraction Example:</dt><dd><div class="fragment"><div class="line"><a class="code hl_function" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> comp;</div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(<span class="stringliteral">&quot;H-1&quot;</span>, <span class="keyword">false</span>); <span class="comment">// Register in number fraction mode</span></div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(<span class="stringliteral">&quot;He-4&quot;</span>, <span class="keyword">false</span>);</div>
<div class="line">comp.<a class="code hl_function" href="#a7d4d748f3ee25e68751fb143717ed080">setNumberFraction</a>(<span class="stringliteral">&quot;H-1&quot;</span>, 0.9);</div>
<div class="line">comp.<a class="code hl_function" href="#a7d4d748f3ee25e68751fb143717ed080">setNumberFraction</a>(<span class="stringliteral">&quot;He-4&quot;</span>, 0.1);</div>
<div class="line"><span class="keywordflow">if</span> (comp.<a class="code hl_function" href="#a72d063a74a9d2197065884a2cea57a14">finalize</a>()) {</div>
<div class="line"> <span class="keywordtype">double</span> he_num_frac = comp.<a class="code hl_function" href="#a84fea38bc1c005e483910285f6800e15">getNumberFraction</a>(<span class="stringliteral">&quot;He-4&quot;</span>); <span class="comment">// Returns 0.1</span></div>
<div class="line">}</div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_a7d4d748f3ee25e68751fb143717ed080"><div class="ttname"><a href="#a7d4d748f3ee25e68751fb143717ed080">fourdst::composition::Composition::setNumberFraction</a></div><div class="ttdeci">double setNumberFraction(const std::string &amp;symbol, const double &amp;number_fraction)</div><div class="ttdoc">Sets the number fraction for a given symbol.</div><div class="ttdef"><b>Definition</b> <a href="composition_8cpp_source.html#l00363">composition.cpp:363</a></div></div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_a84fea38bc1c005e483910285f6800e15"><div class="ttname"><a href="#a84fea38bc1c005e483910285f6800e15">fourdst::composition::Composition::getNumberFraction</a></div><div class="ttdeci">double getNumberFraction(const std::string &amp;symbol) const</div><div class="ttdoc">Gets the number fraction for a given symbol.</div><div class="ttdef"><b>Definition</b> <a href="composition_8cpp_source.html#l00568">composition.cpp:568</a></div></div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00258">258</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a23b83b76ee025f6fc009184ee19bba88" name="a23b83b76ee025f6fc009184ee19bba88"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a23b83b76ee025f6fc009184ee19bba88">&#9670;&#160;</a></span>Composition() <span class="overload">[1/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">fourdst::composition::Composition::Composition </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel default">default</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Default constructor. </p>
</div>
</div>
<a id="aa3ff8ece122a9fad1252061148566749" name="aa3ff8ece122a9fad1252061148566749"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa3ff8ece122a9fad1252061148566749">&#9670;&#160;</a></span>~Composition()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">fourdst::composition::Composition::~Composition </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel default">default</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Default destructor. </p>
</div>
</div>
<a id="ae3cc2099efd7db8eec3d9af2294b75fa" name="ae3cc2099efd7db8eec3d9af2294b75fa"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae3cc2099efd7db8eec3d9af2294b75fa">&#9670;&#160;</a></span>Composition() <span class="overload">[2/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">fourdst::composition::Composition::Composition </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; std::string &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>symbols</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel explicit">explicit</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> and registers the given symbols. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbols</td><td>The symbols to register. The composition will be in mass fraction mode by default. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_symbol_error.html" title="Exception thrown when a symbol used in a composition is invalid.">exceptions::InvalidSymbolError</a></td><td>if any symbol is invalid. </td></tr>
</table>
</dd>
</dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line">std::vector&lt;std::string&gt; symbols = {<span class="stringliteral">&quot;H-1&quot;</span>, <span class="stringliteral">&quot;O-16&quot;</span>};</div>
<div class="line"><a class="code hl_class" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> comp(symbols);</div>
<div class="line">comp.setMassFraction(<span class="stringliteral">&quot;H-1&quot;</span>, 0.11);</div>
<div class="line">comp.setMassFraction(<span class="stringliteral">&quot;O-16&quot;</span>, 0.89);</div>
<div class="line">comp.finalize();</div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html"><div class="ttname"><a href="classfourdst_1_1composition_1_1_composition.html">fourdst::composition::Composition</a></div><div class="ttdoc">Manages a collection of chemical species and their abundances.</div><div class="ttdef"><b>Definition</b> <a href="composition_8h_source.html#l00258">composition.h:258</a></div></div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00176">176</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a2d6fbe5c8142b358641bbe7ffde51053" name="a2d6fbe5c8142b358641bbe7ffde51053"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2d6fbe5c8142b358641bbe7ffde51053">&#9670;&#160;</a></span>Composition() <span class="overload">[3/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">fourdst::composition::Composition::Composition </td>
<td>(</td>
<td class="paramtype">const std::set&lt; std::string &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>symbols</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel explicit">explicit</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> and registers the given symbols from a set. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbols</td><td>The symbols to register. The composition will be in mass fraction mode by default. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_symbol_error.html" title="Exception thrown when a symbol used in a composition is invalid.">exceptions::InvalidSymbolError</a></td><td>if any symbol is invalid. </td></tr>
</table>
</dd>
</dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line">std::set&lt;std::string&gt; symbols = {<span class="stringliteral">&quot;H-1&quot;</span>, <span class="stringliteral">&quot;O-16&quot;</span>};</div>
<div class="line"><a class="code hl_class" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> comp(symbols);</div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00182">182</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="af4d4cc5875cba931a91faee13f55594e" name="af4d4cc5875cba931a91faee13f55594e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af4d4cc5875cba931a91faee13f55594e">&#9670;&#160;</a></span>Composition() <span class="overload">[4/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">fourdst::composition::Composition::Composition </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; std::string &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>symbols</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::vector&lt; double &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>fractions</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>massFracMode</em></span><span class="paramdefsep"> = </span><span class="paramdefval">true</span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs and finalizes a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> with the given symbols and fractions. </p>
<p>This constructor provides a convenient way to create a fully-formed, finalized composition in one step. The provided fractions must be valid and sum to 1.0. </p><dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbols</td><td>The symbols to initialize the composition with. </td></tr>
<tr><td class="paramname">fractions</td><td>The fractions (mass or number) corresponding to the symbols. </td></tr>
<tr><td class="paramname">massFracMode</td><td>True if <code>fractions</code> are mass fractions, false if they are number fractions. [Default: true] </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if the number of symbols and fractions do not match, or if the fractions do not sum to ~1.0. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_symbol_error.html" title="Exception thrown when a symbol used in a composition is invalid.">exceptions::InvalidSymbolError</a></td><td>if any symbol is invalid. </td></tr>
</table>
</dd>
</dl>
<dl class="section post"><dt>Postcondition</dt><dd>The composition is immediately finalized. </dd></dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line">std::vector&lt;std::string&gt; symbols = {<span class="stringliteral">&quot;H-1&quot;</span>, <span class="stringliteral">&quot;O-16&quot;</span>};</div>
<div class="line">std::vector&lt;double&gt; mass_fractions = {0.1119, 0.8881};</div>
<div class="line"><a class="code hl_function" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> comp(symbols, mass_fractions); <span class="comment">// Finalized on construction</span></div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00188">188</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a21369a80378d4c90438a34f0e4a275ca" name="a21369a80378d4c90438a34f0e4a275ca"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a21369a80378d4c90438a34f0e4a275ca">&#9670;&#160;</a></span>Composition() <span class="overload">[5/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">fourdst::composition::Composition::Composition </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;</td> <td class="paramname"><span class="paramname"><em>composition</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs a <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> from another <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">composition</td><td>The <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> to copy. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00210">210</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="ab1701644ff1c83c220dc04eb58d1621b" name="ab1701644ff1c83c220dc04eb58d1621b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab1701644ff1c83c220dc04eb58d1621b">&#9670;&#160;</a></span>begin() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">auto fourdst::composition::Composition::begin </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel inline">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns an iterator to the beginning of the composition map. </p>
<dl class="section return"><dt>Returns</dt><dd>An iterator to the beginning. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00821">821</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="adf41a833e8b704daf4f581fca5c8cb9b" name="adf41a833e8b704daf4f581fca5c8cb9b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adf41a833e8b704daf4f581fca5c8cb9b">&#9670;&#160;</a></span>begin() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">auto fourdst::composition::Composition::begin </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel inline">inline</span><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns a const iterator to the beginning of the composition map. </p>
<dl class="section return"><dt>Returns</dt><dd>A const iterator to the beginning. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00829">829</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="acb08478f7032ecc13cb02283a18187e9" name="acb08478f7032ecc13cb02283a18187e9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acb08478f7032ecc13cb02283a18187e9">&#9670;&#160;</a></span>contains()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::contains </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>isotope</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Checks if a given isotope is present in the composition. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">isotope</td><td>The isotope to check for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the isotope is in the composition, false otherwise. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00906">906</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="adeaf6f1213e78cb1fe8a8317f0a8adc2" name="adeaf6f1213e78cb1fe8a8317f0a8adc2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adeaf6f1213e78cb1fe8a8317f0a8adc2">&#9670;&#160;</a></span>end() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">auto fourdst::composition::Composition::end </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel inline">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns an iterator to the end of the composition map. </p>
<dl class="section return"><dt>Returns</dt><dd>An iterator to the end. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00837">837</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="aed2f5676f8f742199f01e4d1e9664bdd" name="aed2f5676f8f742199f01e4d1e9664bdd"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aed2f5676f8f742199f01e4d1e9664bdd">&#9670;&#160;</a></span>end() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">auto fourdst::composition::Composition::end </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel inline">inline</span><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns a const iterator to the end of the composition map. </p>
<dl class="section return"><dt>Returns</dt><dd>A const iterator to the end. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00845">845</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="a72d063a74a9d2197065884a2cea57a14" name="a72d063a74a9d2197065884a2cea57a14"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a72d063a74a9d2197065884a2cea57a14">&#9670;&#160;</a></span>finalize()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::finalize </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>norm</em></span><span class="paramdefsep"> = </span><span class="paramdefval">false</span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Finalizes the composition, making it ready for querying. </p>
<p>This method checks if the sum of all fractions (mass or number) is approximately 1.0. It also computes global properties like mean particle mass. This <b>must</b> be called before any <code>get...</code> method can be used. </p><dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">norm</td><td>If true, the composition will be normalized to sum to 1 before validation. [Default: false] </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the composition is valid and successfully finalized, false otherwise. </dd></dl>
<dl class="section post"><dt>Postcondition</dt><dd>If successful, <code>m_finalized</code> is true and global properties are computed. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00414">414</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a869dbae3db9d09c57b2df56a813a55fb" name="a869dbae3db9d09c57b2df56a813a55fb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a869dbae3db9d09c57b2df56a813a55fb">&#9670;&#160;</a></span>finalizeMassFracMode()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::finalizeMassFracMode </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>norm</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Finalizes the composition in mass fraction mode. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">norm</td><td>If true, the composition will be normalized to sum to 1. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the composition is successfully finalized, false otherwise. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00427">427</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a461ab4e9cb5975cf865db5f16f03ddfe" name="a461ab4e9cb5975cf865db5f16f03ddfe"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a461ab4e9cb5975cf865db5f16f03ddfe">&#9670;&#160;</a></span>finalizeNumberFracMode()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::finalizeNumberFracMode </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>norm</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Finalizes the composition in number fraction mode. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">norm</td><td>If true, the composition will be normalized to sum to 1. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the composition is successfully finalized, false otherwise. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00464">464</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="ac75dbc8377556c835455991c7c7fe206" name="ac75dbc8377556c835455991c7c7fe206"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac75dbc8377556c835455991c7c7fe206">&#9670;&#160;</a></span>getCanonicalComposition()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="structfourdst_1_1composition_1_1_canonical_composition.html">CanonicalComposition</a> fourdst::composition::Composition::getCanonicalComposition </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>harsh</em></span><span class="paramdefsep"> = </span><span class="paramdefval">false</span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the current canonical composition (X, Y, Z). </p>
<p>Calculates the total mass fractions for H, He, and metals. </p><dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">harsh</td><td>If true, this will throw an error if <code>1 - (X + Y)</code> is not equal to the directly summed <code>Z</code> (within a tolerance). If false, it will only log a warning. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The <code><a class="el" href="structfourdst_1_1composition_1_1_canonical_composition.html" title="Represents the canonical (X, Y, Z) composition of stellar material.">CanonicalComposition</a></code> struct. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname">std::runtime_error</td><td>if <code>harsh</code> is true and the canonical composition is not self-consistent. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00715">715</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a1138c86f7ccd39594601c2ec63ad89e9" name="a1138c86f7ccd39594601c2ec63ad89e9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1138c86f7ccd39594601c2ec63ad89e9">&#9670;&#160;</a></span>getComposition() <span class="overload">[1/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::pair&lt; std::unordered_map&lt; std::string, <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a> &gt;, <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html">GlobalComposition</a> &gt; fourdst::composition::Composition::getComposition </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets all composition entries and the global composition data. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>A pair containing an unordered map of all CompositionEntries and the <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html" title="Represents global properties of a finalized composition.">GlobalComposition</a>. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00630">630</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="afe5f1086027044c84ff35a366b2e8e2d" name="afe5f1086027044c84ff35a366b2e8e2d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afe5f1086027044c84ff35a366b2e8e2d">&#9670;&#160;</a></span>getComposition() <span class="overload">[2/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::pair&lt; <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a>, <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html">GlobalComposition</a> &gt; fourdst::composition::Composition::getComposition </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the composition entry and global composition data for a given species. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The species to get the composition for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A pair containing the <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html" title="Represents a single entry (an isotope) within a composition.">CompositionEntry</a> and <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html" title="Represents global properties of a finalized composition.">GlobalComposition</a> for the given species. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the species is not in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00625">625</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a092d3536b04167ea2e6e3a3b1446c377" name="a092d3536b04167ea2e6e3a3b1446c377"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a092d3536b04167ea2e6e3a3b1446c377">&#9670;&#160;</a></span>getComposition() <span class="overload">[3/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::pair&lt; <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a>, <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html">GlobalComposition</a> &gt; fourdst::composition::Composition::getComposition </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the composition entry and global composition data for a given symbol. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to get the composition for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A pair containing the <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html" title="Represents a single entry (an isotope) within a composition.">CompositionEntry</a> and <a class="el" href="structfourdst_1_1composition_1_1_global_composition.html" title="Represents global properties of a finalized composition.">GlobalComposition</a> for the given symbol. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00613">613</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="ad20bd541dd7c45274a2e586e6a0519a7" name="ad20bd541dd7c45274a2e586e6a0519a7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad20bd541dd7c45274a2e586e6a0519a7">&#9670;&#160;</a></span>getMassFraction() <span class="overload">[1/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::unordered_map&lt; std::string, double &gt; fourdst::composition::Composition::getMassFraction </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the mass fractions of all species in the composition. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>An unordered map of symbols to their mass fractions. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00559">559</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="aa3ba0c742872384cff3ed03789c0a17d" name="aa3ba0c742872384cff3ed03789c0a17d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa3ba0c742872384cff3ed03789c0a17d">&#9670;&#160;</a></span>getMassFraction() <span class="overload">[2/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getMassFraction </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the mass fraction for a given isotope. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The isotope to get the mass fraction for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The mass fraction for the given isotope. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the isotope is not registered in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00555">555</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a7f6a6edf02b55eeecf147c3f1f7f55e7" name="a7f6a6edf02b55eeecf147c3f1f7f55e7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7f6a6edf02b55eeecf147c3f1f7f55e7">&#9670;&#160;</a></span>getMassFraction() <span class="overload">[3/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getMassFraction </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the mass fraction for a given symbol. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to get the mass fraction for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The mass fraction for the given symbol. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00528">528</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="acdbdf980297580e885ce3f124164315f" name="acdbdf980297580e885ce3f124164315f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acdbdf980297580e885ce3f124164315f">&#9670;&#160;</a></span>getMassFractionVector()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; double &gt; fourdst::composition::Composition::getMassFractionVector </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get a uniform vector representation of the mass fraction stored in the composition object sorted such that the lightest species is at index 0 and the heaviest is at the last index. </p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dl class="section return"><dt>Returns</dt><dd>the vector of mass fractions sorted by species mass (lightest to heaviest). </dd></dl>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00762">762</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a98199f435cb553f5cf4f8e520fdb8a7a" name="a98199f435cb553f5cf4f8e520fdb8a7a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a98199f435cb553f5cf4f8e520fdb8a7a">&#9670;&#160;</a></span>getMeanAtomicNumber()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getMeanAtomicNumber </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Compute the mean atomic number of the composition. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>Mean atomic number &lt;Z&gt;. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00646">646</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a66401fed7054172e9b1a2687e5cc8eff" name="a66401fed7054172e9b1a2687e5cc8eff"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a66401fed7054172e9b1a2687e5cc8eff">&#9670;&#160;</a></span>getMeanParticleMass()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getMeanParticleMass </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Compute the mean particle mass of the composition. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>Mean particle mass in atomic mass units (g/mol). </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00638">638</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a84d6552e2b762fabb7bddf68b05c4022" name="a84d6552e2b762fabb7bddf68b05c4022"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a84d6552e2b762fabb7bddf68b05c4022">&#9670;&#160;</a></span>getMolarAbundance() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getMolarAbundance </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the molar abundance for a given isotope. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The isotope to get the molar abundance for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The molar abundance for the given isotope. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the isotope is not registered in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00609">609</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a67a2ed844f3aee3d9cc1a3cb996eb56f" name="a67a2ed844f3aee3d9cc1a3cb996eb56f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a67a2ed844f3aee3d9cc1a3cb996eb56f">&#9670;&#160;</a></span>getMolarAbundance() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getMolarAbundance </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the molar abundance (X_i / A_i) for a given symbol. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to get the molar abundance for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The molar abundance for the given symbol. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00596">596</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a84d62b971bee83d944d2792c6850bc0b" name="a84d62b971bee83d944d2792c6850bc0b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a84d62b971bee83d944d2792c6850bc0b">&#9670;&#160;</a></span>getMolarAbundanceVector()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; double &gt; fourdst::composition::Composition::getMolarAbundanceVector </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get a uniform vector representation of the molar abundances stored in the composition object sorted such that the lightest species is at index 0 and the heaviest is at the last index. </p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dl class="section return"><dt>Returns</dt><dd>the vector of molar abundances sorted by species mass (lightest to heaviest). </dd></dl>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00803">803</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a7731df9b30f8c8f13231f7e1a17b105c" name="a7731df9b30f8c8f13231f7e1a17b105c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7731df9b30f8c8f13231f7e1a17b105c">&#9670;&#160;</a></span>getNumberFraction() <span class="overload">[1/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::unordered_map&lt; std::string, double &gt; fourdst::composition::Composition::getNumberFraction </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the number fractions of all species in the composition. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>An unordered map of symbols to their number fractions. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00588">588</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="aa0ce4143a267e96ab7967538c76acdc3" name="aa0ce4143a267e96ab7967538c76acdc3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa0ce4143a267e96ab7967538c76acdc3">&#9670;&#160;</a></span>getNumberFraction() <span class="overload">[2/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getNumberFraction </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the number fraction for a given isotope. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The isotope to get the number fraction for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The number fraction for the given isotope. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the isotope is not registered in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00584">584</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a84fea38bc1c005e483910285f6800e15" name="a84fea38bc1c005e483910285f6800e15"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a84fea38bc1c005e483910285f6800e15">&#9670;&#160;</a></span>getNumberFraction() <span class="overload">[3/3]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::getNumberFraction </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the number fraction for a given symbol. </p>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to get the number fraction for. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The number fraction for the given symbol. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not in the composition. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00568">568</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a2a41242de5d49b005e0b608e79e2f2d9" name="a2a41242de5d49b005e0b608e79e2f2d9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2a41242de5d49b005e0b608e79e2f2d9">&#9670;&#160;</a></span>getNumberFractionVector()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; double &gt; fourdst::composition::Composition::getNumberFractionVector </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get a uniform vector representation of the number fractions stored in the composition object sorted such that the lightest species is at index 0 and the heaviest is at the last index. </p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dl class="section return"><dt>Returns</dt><dd>the vector of number fractions sorted by species mass (lightest to heaviest). </dd></dl>
<dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00783">783</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a3dee7b5e1f54920de9eab99f95a516ec" name="a3dee7b5e1f54920de9eab99f95a516ec"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3dee7b5e1f54920de9eab99f95a516ec">&#9670;&#160;</a></span>getRegisteredSpecies()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::set&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt; fourdst::composition::Composition::getRegisteredSpecies </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get a set of all species that are registered in the composition. </p>
<dl class="section return"><dt>Returns</dt><dd>A set of <code><a class="el" href="structfourdst_1_1atomic_1_1_species.html" title="Represents an atomic species (isotope) with its fundamental physical properties.">atomic::Species</a></code> objects registered in the composition. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00280">280</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a84c7b72c2aee46b94492d404855dd3e0" name="a84c7b72c2aee46b94492d404855dd3e0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a84c7b72c2aee46b94492d404855dd3e0">&#9670;&#160;</a></span>getRegisteredSymbols()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::set&lt; std::string &gt; fourdst::composition::Composition::getRegisteredSymbols </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the registered symbols. </p>
<dl class="section return"><dt>Returns</dt><dd>A set of registered symbols. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00276">276</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="aa534a01f24074cc9edd7f41df228eb50" name="aa534a01f24074cc9edd7f41df228eb50"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa534a01f24074cc9edd7f41df228eb50">&#9670;&#160;</a></span>getSpeciesAtIndex()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="structfourdst_1_1atomic_1_1_species.html">atomic::Species</a> fourdst::composition::Composition::getSpeciesAtIndex </td>
<td>(</td>
<td class="paramtype">size_t</td> <td class="paramname"><span class="paramname"><em>index</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the species at a given index in the sorted vector representation. </p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">index</td><td>The index in the sorted vector representation for which to return the species. Must be in [0, N-1] where N is the number of registered species. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname">std::out_of_range</td><td>if the index is out of range. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The species at the given index in the sorted vector representation. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00873">873</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="ad49012cd6d78558d80198cc06ec164b1" name="ad49012cd6d78558d80198cc06ec164b1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad49012cd6d78558d80198cc06ec164b1">&#9670;&#160;</a></span>getSpeciesIndex() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">size_t fourdst::composition::Composition::getSpeciesIndex </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>get the index in the sorted vector representation for a given symbol </p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd>
<dd>
symbol must be registered in the composition </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>the species to look up the index for. Note that this is the index species data will be at if you were to call <a class="el" href="#a84d62b971bee83d944d2792c6850bc0b" title="Get a uniform vector representation of the molar abundances stored in the composition object sorted s...">getMolarAbundanceVector()</a>, <a class="el" href="#acdbdf980297580e885ce3f124164315f" title="Get a uniform vector representation of the mass fraction stored in the composition object sorted such...">getMassFractionVector()</a>, or <a class="el" href="#a2a41242de5d49b005e0b608e79e2f2d9" title="Get a uniform vector representation of the number fractions stored in the composition object sorted s...">getNumberFractionVector()</a> </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not registered in the composition </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The index of the symbol in the sorted vector representation. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00848">848</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a1204a6421205feaaed13937aefa158ba" name="a1204a6421205feaaed13937aefa158ba"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1204a6421205feaaed13937aefa158ba">&#9670;&#160;</a></span>getSpeciesIndex() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">size_t fourdst::composition::Composition::getSpeciesIndex </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>get the index in the sorted vector representation for a given symbol </p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized. </dd>
<dd>
symbol must be registered in the composition </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>the symbol to look up the index for. Note that this is the index species data will be at if you were to call <a class="el" href="#a84d62b971bee83d944d2792c6850bc0b" title="Get a uniform vector representation of the molar abundances stored in the composition object sorted s...">getMolarAbundanceVector()</a>, <a class="el" href="#acdbdf980297580e885ce3f124164315f" title="Get a uniform vector representation of the mass fraction stored in the composition object sorted such...">getMassFractionVector()</a>, or <a class="el" href="#a2a41242de5d49b005e0b608e79e2f2d9" title="Get a uniform vector representation of the number fractions stored in the composition object sorted s...">getNumberFractionVector()</a> </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not registered in the composition </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The index of the symbol in the sorted vector representation. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00823">823</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a72a368f27094b03fdd9896844e075c94" name="a72a368f27094b03fdd9896844e075c94"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a72a368f27094b03fdd9896844e075c94">&#9670;&#160;</a></span>hasSymbol()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::hasSymbol </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Checks if a symbol is registered in the composition. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to check. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the symbol is registered, false otherwise. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00902">902</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="addf03ba8b988970d341884d487aa94d5" name="addf03ba8b988970d341884d487aa94d5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#addf03ba8b988970d341884d487aa94d5">&#9670;&#160;</a></span>isValidComposition()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::isValidComposition </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; double &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>fractions</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Checks if the given fractions are valid (sum to ~1.0). </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">fractions</td><td>The fractions to check. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the fractions are valid, false otherwise. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00295">295</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a8fdac26e6298008aaeaa5b15f7fe244f" name="a8fdac26e6298008aaeaa5b15f7fe244f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8fdac26e6298008aaeaa5b15f7fe244f">&#9670;&#160;</a></span>isValidSymbol()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::isValidSymbol </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel static">static</span><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Checks if the given symbol is valid by checking against the global species database. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to check. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the symbol is valid, false otherwise. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00308">308</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a3aead72892606725a4149a5f65bd31ec" name="a3aead72892606725a4149a5f65bd31ec"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3aead72892606725a4149a5f65bd31ec">&#9670;&#160;</a></span>mix()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> fourdst::composition::Composition::mix </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;</td> <td class="paramname"><span class="paramname"><em>other</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double</td> <td class="paramname"><span class="paramname"><em>fraction</em></span>&#160;) const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Mixes this composition with another to produce a new composition. </p>
<p>The mixing is performed linearly on the mass fractions. The formula for each species is: <code>new_X_i = fraction * this_X_i + (1 - fraction) * other_X_i</code>. The resulting composition is automatically finalized. </p><dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>The other composition to mix with. </td></tr>
<tr><td class="paramname">fraction</td><td>The mixing fraction. A value of 1.0 means the new composition is 100% <code>this</code>, 0.0 means 100% <code>other</code>. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A new, finalized <code><a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a></code> object representing the mixture. </dd></dl>
<dl class="section pre"><dt>Precondition</dt><dd>Both <code>this</code> and <code>other</code> compositions must be finalized. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if either composition is not finalized. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if the fraction is not between 0 and 1. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00498">498</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a24a3bdeb8e8e55b54ecdee6dcb0d9561" name="a24a3bdeb8e8e55b54ecdee6dcb0d9561"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a24a3bdeb8e8e55b54ecdee6dcb0d9561">&#9670;&#160;</a></span>operator+()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> fourdst::composition::Composition::operator+ </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;</td> <td class="paramname"><span class="paramname"><em>other</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Overloads the + operator to mix two compositions with a 50/50 fraction. </p>
<p>OVERLOADS.</p>
<p>This is a convenience operator that calls <code>mix(other, 0.5)</code>. </p><dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>The other composition to mix with. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The new, mixed composition. </dd></dl>
<dl class="section pre"><dt>Precondition</dt><dd>Both compositions must be finalized. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname">See</td><td><code><a class="el" href="#a3aead72892606725a4149a5f65bd31ec" title="Mixes this composition with another to produce a new composition.">mix()</a></code> for exceptions. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00921">921</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a4ec1e23cfecef764cb831171fed62fc2" name="a4ec1e23cfecef764cb831171fed62fc2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4ec1e23cfecef764cb831171fed62fc2">&#9670;&#160;</a></span>operator=()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp; fourdst::composition::Composition::operator= </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> const &amp;</td> <td class="paramname"><span class="paramname"><em>other</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Assignment operator. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>The <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> to assign from. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A reference to this <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a>. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00219">219</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a4ce00f73cc133bb1bac2b030b93ab480" name="a4ce00f73cc133bb1bac2b030b93ab480"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4ce00f73cc133bb1bac2b030b93ab480">&#9670;&#160;</a></span>registerSpecies() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void fourdst::composition::Composition::registerSpecies </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>massFracMode</em></span><span class="paramdefsep"> = </span><span class="paramdefval">true</span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Registers a new species by extracting its symbol. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The species to register. </td></tr>
<tr><td class="paramname">massFracMode</td><td>True for mass fraction mode, false for number fraction mode. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_symbol_error.html" title="Exception thrown when a symbol used in a composition is invalid.">exceptions::InvalidSymbolError</a></td><td>if the species' symbol is invalid. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if the mode conflicts. </td></tr>
</table>
</dd>
</dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line"><span class="preprocessor">#include &quot;<a class="code" href="species_8h.html">fourdst/composition/species.h</a>&quot;</span> <span class="comment">// Assuming species like H1 are defined here</span></div>
<div class="line"><a class="code hl_function" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> comp;</div>
<div class="line">comp.<a class="code hl_function" href="#a4ce00f73cc133bb1bac2b030b93ab480">registerSpecies</a>(<a class="code hl_variable" href="namespacefourdst_1_1atomic.html#a3f619cc8f8b2cd718a4082c6adb0de90">fourdst::atomic::species</a>.at(<span class="stringliteral">&quot;H-1&quot;</span>));</div>
<div class="ttc" id="aclassfourdst_1_1composition_1_1_composition_html_a4ce00f73cc133bb1bac2b030b93ab480"><div class="ttname"><a href="#a4ce00f73cc133bb1bac2b030b93ab480">fourdst::composition::Composition::registerSpecies</a></div><div class="ttdeci">void registerSpecies(const fourdst::atomic::Species &amp;species, bool massFracMode=true)</div><div class="ttdoc">Registers a new species by extracting its symbol.</div><div class="ttdef"><b>Definition</b> <a href="composition_8cpp_source.html#l00266">composition.cpp:266</a></div></div>
<div class="ttc" id="anamespacefourdst_1_1atomic_html_a3f619cc8f8b2cd718a4082c6adb0de90"><div class="ttname"><a href="namespacefourdst_1_1atomic.html#a3f619cc8f8b2cd718a4082c6adb0de90">fourdst::atomic::species</a></div><div class="ttdeci">static const std::unordered_map&lt; std::string, const Species &amp; &gt; species</div><div class="ttdef"><b>Definition</b> <a href="species_8h_source.html#l03581">species.h:3581</a></div></div>
<div class="ttc" id="aspecies_8h_html"><div class="ttname"><a href="species_8h.html">species.h</a></div></div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00266">266</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a057f2bf2e86bcc3c649c0ddf18cf3826" name="a057f2bf2e86bcc3c649c0ddf18cf3826"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a057f2bf2e86bcc3c649c0ddf18cf3826">&#9670;&#160;</a></span>registerSpecies() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void fourdst::composition::Composition::registerSpecies </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>massFracMode</em></span><span class="paramdefsep"> = </span><span class="paramdefval">true</span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Registers a vector of new species. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The vector of species to register. </td></tr>
<tr><td class="paramname">massFracMode</td><td>True for mass fraction mode, false for number fraction mode. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_symbol_error.html" title="Exception thrown when a symbol used in a composition is invalid.">exceptions::InvalidSymbolError</a></td><td>if any species' symbol is invalid. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if the mode conflicts. </td></tr>
</table>
</dd>
</dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line"><span class="preprocessor">#include &quot;<a class="code" href="species_8h.html">fourdst/composition/species.h</a>&quot;</span></div>
<div class="line"><a class="code hl_function" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> comp;</div>
<div class="line">std::vector&lt;fourdst::atomic::Species&gt; my_species = { ... };</div>
<div class="line">comp.<a class="code hl_function" href="#a4ce00f73cc133bb1bac2b030b93ab480">registerSpecies</a>(my_species, <span class="keyword">false</span>); <span class="comment">// Number fraction mode</span></div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00270">270</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a1bc2e64f87c12befdc2bc767e7405661" name="a1bc2e64f87c12befdc2bc767e7405661"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1bc2e64f87c12befdc2bc767e7405661">&#9670;&#160;</a></span>registerSymbol() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void fourdst::composition::Composition::registerSymbol </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>massFracMode</em></span><span class="paramdefsep"> = </span><span class="paramdefval">true</span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Registers a new symbol for inclusion in the composition. </p>
<p>A symbol must be registered before its abundance can be set. The first registration sets the mode (mass/number fraction) for the entire composition. </p><dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to register (e.g., "Fe-56"). </td></tr>
<tr><td class="paramname">massFracMode</td><td>True for mass fraction mode, false for number fraction mode. This is only effective for the first symbol registered. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_symbol_error.html" title="Exception thrown when a symbol used in a composition is invalid.">exceptions::InvalidSymbolError</a></td><td>if the symbol is not in the atomic species database. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if attempting to register with a mode that conflicts with the existing mode. </td></tr>
</table>
</dd>
</dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line"><a class="code hl_function" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> comp;</div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(<span class="stringliteral">&quot;H-1&quot;</span>); <span class="comment">// Now in mass fraction mode</span></div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(<span class="stringliteral">&quot;He-4&quot;</span>); <span class="comment">// Must also be mass fraction mode</span></div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00233">233</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a9b422156600823276a9606bfa07ad4db" name="a9b422156600823276a9606bfa07ad4db"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9b422156600823276a9606bfa07ad4db">&#9670;&#160;</a></span>registerSymbol() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void fourdst::composition::Composition::registerSymbol </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; std::string &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>symbols</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>massFracMode</em></span><span class="paramdefsep"> = </span><span class="paramdefval">true</span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Registers multiple new symbols. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbols</td><td>The symbols to register. </td></tr>
<tr><td class="paramname">massFracMode</td><td>True for mass fraction mode, false for number fraction mode. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_symbol_error.html" title="Exception thrown when a symbol used in a composition is invalid.">exceptions::InvalidSymbolError</a></td><td>if any symbol is invalid. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if the mode conflicts with an already set mode. </td></tr>
</table>
</dd>
</dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line">std::vector&lt;std::string&gt; symbols = {<span class="stringliteral">&quot;H-1&quot;</span>, <span class="stringliteral">&quot;O-16&quot;</span>};</div>
<div class="line"><a class="code hl_class" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> comp;</div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(symbols);</div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00260">260</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a0af981ed1074b26c237cf6cf35f82c9e" name="a0af981ed1074b26c237cf6cf35f82c9e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0af981ed1074b26c237cf6cf35f82c9e">&#9670;&#160;</a></span>setCompositionMode()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void fourdst::composition::Composition::setCompositionMode </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>massFracMode</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the composition mode (mass fraction vs. number fraction). </p>
<p>This function converts all entries in the composition to the specified mode. </p><dl class="section pre"><dt>Precondition</dt><dd>The composition must be finalized before the mode can be switched. </dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">massFracMode</td><td>True to switch to mass fraction mode, false for number fraction mode. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_not_finalized_error.html" title="Exception thrown when an operation is attempted on a composition that has not been finalized.">exceptions::CompositionNotFinalizedError</a></td><td>if the composition is not finalized. </td></tr>
<tr><td class="paramname">std::runtime_error</td><td>if the conversion fails for an unknown reason. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00694">694</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="aa6c94269a5d16349c98860f3015b734a" name="aa6c94269a5d16349c98860f3015b734a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa6c94269a5d16349c98860f3015b734a">&#9670;&#160;</a></span>setMassFraction() <span class="overload">[1/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::setMassFraction </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const double &amp;</td> <td class="paramname"><span class="paramname"><em>mass_fraction</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the mass fraction for a given species. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The species to set the mass fraction for. </td></tr>
<tr><td class="paramname">mass_fraction</td><td>The mass fraction to set. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The previous mass fraction that was set for the species. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the species is not registered. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if the composition is in number fraction mode. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if the mass fraction is not between 0 and 1. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00349">349</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a493224656aa3ade68389250720ef09af" name="a493224656aa3ade68389250720ef09af"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a493224656aa3ade68389250720ef09af">&#9670;&#160;</a></span>setMassFraction() <span class="overload">[2/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::setMassFraction </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const double &amp;</td> <td class="paramname"><span class="paramname"><em>mass_fraction</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the mass fraction for a given symbol. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to set the mass fraction for. </td></tr>
<tr><td class="paramname">mass_fraction</td><td>The mass fraction to set (must be in [0, 1]). </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The previous mass fraction that was set for the symbol. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not registered. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if the composition is in number fraction mode. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if the mass fraction is not between 0 and 1. </td></tr>
</table>
</dd>
</dl>
<dl class="section post"><dt>Postcondition</dt><dd>The composition is marked as not finalized. </dd></dl>
<dl class="section user"><dt>Usage Example:</dt><dd><div class="fragment"><div class="line"><a class="code hl_function" href="#a23b83b76ee025f6fc009184ee19bba88">Composition</a> comp;</div>
<div class="line">comp.<a class="code hl_function" href="#a1bc2e64f87c12befdc2bc767e7405661">registerSymbol</a>(<span class="stringliteral">&quot;H-1&quot;</span>);</div>
<div class="line">comp.<a class="code hl_function" href="#a493224656aa3ade68389250720ef09af">setMassFraction</a>(<span class="stringliteral">&quot;H-1&quot;</span>, 0.7);</div>
</div><!-- fragment --> </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00312">312</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="abbae020d46c74708a7974c1ca755bb62" name="abbae020d46c74708a7974c1ca755bb62"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abbae020d46c74708a7974c1ca755bb62">&#9670;&#160;</a></span>setMassFraction() <span class="overload">[3/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; double &gt; fourdst::composition::Composition::setMassFraction </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::vector&lt; double &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>mass_fractions</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the mass fraction for multiple species. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The vector of species to set the mass fractions for. </td></tr>
<tr><td class="paramname">mass_fractions</td><td>The vector of mass fractions corresponding to the species. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A vector of the previous mass fractions that were set. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname">See</td><td><code>setMassFraction(const std::vector&lt;std::string&gt;&amp;, const std::vector&lt;double&gt;&amp;)</code> for exceptions. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00353">353</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a66ce1012c12b0a83629eb09d451b68e3" name="a66ce1012c12b0a83629eb09d451b68e3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a66ce1012c12b0a83629eb09d451b68e3">&#9670;&#160;</a></span>setMassFraction() <span class="overload">[4/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; double &gt; fourdst::composition::Composition::setMassFraction </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; std::string &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>symbols</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::vector&lt; double &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>mass_fractions</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the mass fraction for multiple symbols. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbols</td><td>The symbols to set the mass fractions for. </td></tr>
<tr><td class="paramname">mass_fractions</td><td>The mass fractions corresponding to the symbols. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A vector of the previous mass fractions that were set. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if symbol and fraction counts differ. </td></tr>
<tr><td class="paramname">See</td><td><code>setMassFraction(const std::string&amp;, const double&amp;)</code> for other exceptions. </td></tr>
</table>
</dd>
</dl>
<dl class="section post"><dt>Postcondition</dt><dd>The composition is marked as not finalized. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00335">335</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="aaa822bb48a948d101fef759ffbefe31b" name="aaa822bb48a948d101fef759ffbefe31b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aaa822bb48a948d101fef759ffbefe31b">&#9670;&#160;</a></span>setNumberFraction() <span class="overload">[1/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::setNumberFraction </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const double &amp;</td> <td class="paramname"><span class="paramname"><em>number_fraction</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the number fraction for a given species. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The species to set the number fraction for. </td></tr>
<tr><td class="paramname">number_fraction</td><td>The number fraction to set for the species. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The previous number fraction that was set for the species. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the species is not registered. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if the composition is in mass fraction mode. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if the number fraction is not between 0 and 1. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00400">400</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a7d4d748f3ee25e68751fb143717ed080" name="a7d4d748f3ee25e68751fb143717ed080"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7d4d748f3ee25e68751fb143717ed080">&#9670;&#160;</a></span>setNumberFraction() <span class="overload">[2/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::setNumberFraction </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>symbol</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const double &amp;</td> <td class="paramname"><span class="paramname"><em>number_fraction</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the number fraction for a given symbol. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbol</td><td>The symbol to set the number fraction for. </td></tr>
<tr><td class="paramname">number_fraction</td><td>The number fraction to set (must be in [0, 1]). </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The previous number fraction that was set. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if the symbol is not registered. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_composition_mode_error.html" title="Exception thrown due to a conflict in composition modes at the entry level.">exceptions::CompositionModeError</a></td><td>if the composition is in mass fraction mode. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if the number fraction is not between 0 and 1. </td></tr>
</table>
</dd>
</dl>
<dl class="section post"><dt>Postcondition</dt><dd>The composition is marked as not finalized. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00363">363</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="adc068778a1ef33cad67f5ca028b49bb8" name="adc068778a1ef33cad67f5ca028b49bb8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adc068778a1ef33cad67f5ca028b49bb8">&#9670;&#160;</a></span>setNumberFraction() <span class="overload">[3/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; double &gt; fourdst::composition::Composition::setNumberFraction </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; <a class="el" href="structfourdst_1_1atomic_1_1_species.html">fourdst::atomic::Species</a> &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>species</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::vector&lt; double &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>number_fractions</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the number fraction for multiple species. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">species</td><td>The vector of species to set the number fractions for. </td></tr>
<tr><td class="paramname">number_fractions</td><td>The vector of number fractions corresponding to the species. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The vector of the previous number fractions that were set. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname">See</td><td><code>setNumberFraction(const std::vector&lt;std::string&gt;&amp;, const std::vector&lt;double&gt;&amp;)</code> for exceptions. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00404">404</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a48014a0a725ebd91ad1193c063b5b26f" name="a48014a0a725ebd91ad1193c063b5b26f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a48014a0a725ebd91ad1193c063b5b26f">&#9670;&#160;</a></span>setNumberFraction() <span class="overload">[4/4]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; double &gt; fourdst::composition::Composition::setNumberFraction </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; std::string &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>symbols</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::vector&lt; double &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>number_fractions</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the number fraction for multiple symbols. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbols</td><td>The symbols to set the number fractions for. </td></tr>
<tr><td class="paramname">number_fractions</td><td>The number fractions corresponding to the symbols. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A vector of the previous number fractions that were set. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if symbol and fraction counts differ. </td></tr>
<tr><td class="paramname">See</td><td><code>setNumberFraction(const std::string&amp;, const double&amp;)</code> for other exceptions. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00386">386</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a17635cd21744c7cf86cb1eb75152c816" name="a17635cd21744c7cf86cb1eb75152c816"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a17635cd21744c7cf86cb1eb75152c816">&#9670;&#160;</a></span>subset()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> fourdst::composition::Composition::subset </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; std::string &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>symbols</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>method</em></span><span class="paramdefsep"> = </span><span class="paramdefval">&quot;norm&quot;</span>&#160;) const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel nodiscard">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Creates a new <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> object containing a subset of species from this one. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">symbols</td><td>The symbols to include in the subset. </td></tr>
<tr><td class="paramname">method</td><td>The method for handling the abundances of the new subset. Can be "norm" (normalize abundances to sum to 1) or "none" (keep original abundances). </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A new <code><a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a></code> object containing the subset. </dd></dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_unregistered_symbol_error.html" title="Exception thrown when a symbol is used that has not been registered.">exceptions::UnregisteredSymbolError</a></td><td>if any requested symbol is not in the original composition. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_mixing_mode.html" title="Exception thrown for an invalid or unsupported mixing mode.">exceptions::InvalidMixingMode</a></td><td>if an invalid method is provided. </td></tr>
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_failed_to_finalize_composition_error.html" title="Exception thrown when the finalization process of a composition fails.">exceptions::FailedToFinalizeCompositionError</a></td><td>if normalization fails. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00665">665</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<a id="a86982685c34db4a8f079ddafc25c594e" name="a86982685c34db4a8f079ddafc25c594e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a86982685c34db4a8f079ddafc25c594e">&#9670;&#160;</a></span>validateComposition()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void fourdst::composition::Composition::validateComposition </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; double &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>fractions</em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Validates the given fractions, throwing an exception on failure. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">fractions</td><td>The fractions to validate. </td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classfourdst_1_1composition_1_1exceptions_1_1_invalid_composition_error.html" title="Exception thrown when a composition is in an invalid or inconsistent state.">exceptions::InvalidCompositionError</a></td><td>if the fractions are invalid. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00288">288</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Friends And Related Symbol Documentation</h2>
<a id="a36c2525d21cd932065bb2bb30bc57fb4" name="a36c2525d21cd932065bb2bb30bc57fb4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a36c2525d21cd932065bb2bb30bc57fb4">&#9670;&#160;</a></span>operator&lt;&lt;</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::ostream &amp; operator&lt;&lt; </td>
<td>(</td>
<td class="paramtype">std::ostream &amp;</td> <td class="paramname"><span class="paramname"><em>os</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a> &amp;</td> <td class="paramname"><span class="paramname"><em>composition</em></span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel friend">friend</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Overloaded output stream operator for <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">os</td><td>The output stream. </td></tr>
<tr><td class="paramname">composition</td><td>The <a class="el" href="classfourdst_1_1composition_1_1_composition.html" title="Manages a collection of chemical species and their abundances.">Composition</a> to output. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The output stream. </dd></dl>
<p class="definition">Definition at line <a class="el" href="composition_8cpp_source.html#l00937">937</a> of file <a class="el" href="composition_8cpp_source.html">composition.cpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a id="aa7f2753b10e85ae3bbf0c3d600a973db" name="aa7f2753b10e85ae3bbf0c3d600a973db"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa7f2753b10e85ae3bbf0c3d600a973db">&#9670;&#160;</a></span>m_compositions</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::unordered_map&lt;std::string, <a class="el" href="structfourdst_1_1composition_1_1_composition_entry.html">CompositionEntry</a>&gt; fourdst::composition::Composition::m_compositions</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>The compositions. </p>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00270">270</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="a8a8096863464338bc6e3c5124407dca4" name="a8a8096863464338bc6e3c5124407dca4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8a8096863464338bc6e3c5124407dca4">&#9670;&#160;</a></span>m_config</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">fourdst::config::Config&amp; fourdst::composition::Composition::m_config = fourdst::config::Config::getInstance()</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00260">260</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="aa00cbc0933d8a22bb900ac21a338e5ac" name="aa00cbc0933d8a22bb900ac21a338e5ac"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa00cbc0933d8a22bb900ac21a338e5ac">&#9670;&#160;</a></span>m_finalized</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::m_finalized = false</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>True if the composition is finalized. </p>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00264">264</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="ab6c66f35e1fb05dd24aacaf90e115c5e" name="ab6c66f35e1fb05dd24aacaf90e115c5e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab6c66f35e1fb05dd24aacaf90e115c5e">&#9670;&#160;</a></span>m_logger</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">quill::Logger* fourdst::composition::Composition::m_logger = m_logManager.getLogger(&quot;log&quot;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00262">262</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="a695d37ec6cde63d86a20df1e9f26af19" name="a695d37ec6cde63d86a20df1e9f26af19"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a695d37ec6cde63d86a20df1e9f26af19">&#9670;&#160;</a></span>m_logManager</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">fourdst::logging::LogManager&amp; fourdst::composition::Composition::m_logManager = fourdst::logging::LogManager::getInstance()</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00261">261</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="a671f1ee8be00f4ff8c1d94fabb382380" name="a671f1ee8be00f4ff8c1d94fabb382380"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a671f1ee8be00f4ff8c1d94fabb382380">&#9670;&#160;</a></span>m_massFracMode</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool fourdst::composition::Composition::m_massFracMode = true</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>True if mass fraction mode, false if number fraction mode. </p>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00267">267</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="a4a36c8d22ce61023e7bea1d9417577d4" name="a4a36c8d22ce61023e7bea1d9417577d4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4a36c8d22ce61023e7bea1d9417577d4">&#9670;&#160;</a></span>m_meanParticleMass</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::m_meanParticleMass = 0.0</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>The mean particle mass of the composition (\sum_{i} \frac{n_i}{m_i}. where n_i is the number fraction of the ith species and m_i is the mass of the ith species). </p>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00266">266</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="a39bfcb7d81d723cbd9d021abd533b4d6" name="a39bfcb7d81d723cbd9d021abd533b4d6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a39bfcb7d81d723cbd9d021abd533b4d6">&#9670;&#160;</a></span>m_registeredSymbols</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::set&lt;std::string&gt; fourdst::composition::Composition::m_registeredSymbols</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>The registered symbols. </p>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00269">269</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<a id="addae4484da7d5072ab66a721dbe04ced" name="addae4484da7d5072ab66a721dbe04ced"></a>
<h2 class="memtitle"><span class="permalink"><a href="#addae4484da7d5072ab66a721dbe04ced">&#9670;&#160;</a></span>m_specificNumberDensity</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double fourdst::composition::Composition::m_specificNumberDensity = 0.0</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel private">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>The specific number density of the composition (\sum_{i} X_i m_i. Where X_i is the number fraction of the ith species and m_i is the mass of the ith species). </p>
<p class="definition">Definition at line <a class="el" href="composition_8h_source.html#l00265">265</a> of file <a class="el" href="composition_8h_source.html">composition.h</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>src/composition/include/fourdst/composition/<a class="el" href="composition_8h_source.html">composition.h</a></li>
<li>src/composition/lib/<a class="el" href="composition_8cpp_source.html">composition.cpp</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
<ul>
<li class="navelem"><a class="el" href="namespacefourdst.html">fourdst</a></li><li class="navelem"><a class="el" href="namespacefourdst_1_1composition.html">composition</a></li><li class="navelem"><a class="el" href="classfourdst_1_1composition_1_1_composition.html">Composition</a></li>
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.13.2 </li>
</ul>
</div>
</body>
</html>