<divclass="center"><iframescrolling="no"frameborder="0"src="classfourdst_1_1composition_1_1_composition__inherit__graph.svg"width="155"height="126"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div>
Collaboration diagram for fourdst::composition::Composition:</div>
<divclass="dyncontent">
<divclass="center"><divclass="zoom"><iframescrolling="no"frameborder="0"src="classfourdst_1_1composition_1_1_composition__coll__graph.svg"width="100%"height="474"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div></div>
<trclass="memdesc:"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Caches computed properties of the composition to avoid redundant calculations. <ahref="structfourdst_1_1composition_1_1_composition_1_1_composition_cache.html#details">More...</a><br/></td></tr>
<trclass="memdesc:ae3cc2099efd7db8eec3d9af2294b75fa"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="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 vector. <br/></td></tr>
<trclass="memdesc:afa95dddfa88a101ad6ce261295a4460c"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="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 species from a vector. <br/></td></tr>
<trclass="memdesc:a2d6fbe5c8142b358641bbe7ffde51053"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="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>
<trclass="memdesc:a7d19fb3326e51c8fc8db5e0738e97d95"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="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 species from a set. <br/></td></tr>
<trclass="memdesc:a0b3c93ce7c9473ac4aa4c9ee04f78051"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from symbols and their corresponding molar abundances. <br/></td></tr>
<trclass="memdesc:a7f0798b3f1191561b38f336406acf62a"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from species and their corresponding molar abundances. <br/></td></tr>
<trclass="memdesc:ad6cdb28598267743f236d053cd5a62ae"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from symbols in a set and their corresponding molar abundances. <br/></td></tr>
<trclass="memdesc:a21369a80378d4c90438a34f0e4a275ca"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from another <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a>. <br/></td></tr>
<trclass="memdesc:a3ab4dcda0bfd1a35b169bcc57fe66725"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Registers a new symbol for inclusion in the composition. <br/></td></tr>
<trclass="memdesc:a156d1198ef47deed9689949f271969e2"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Registers multiple new symbols. <br/></td></tr>
<trclass="memdesc:a392a34c19f45d6c936cc7030e6cfaf3f"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Registers a new species by extracting its symbol. <br/></td></tr>
<trclass="memdesc:a2846f4ea0d6075ecdaf4334741a54750"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Registers a vector of new species. <br/></td></tr>
<trclass="memdesc:a194f715788e7921bd611579440de2ecd"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Checks if a given species is present in the composition. <br/></td></tr>
<trclass="memdesc:ac3bfb56a2587215a59894e76d4867ede"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Checks if a given symbol is present in the composition. <br/></td></tr>
<trclass="memdesc:a9d177d36b728442bcbd8cb66712c7c75"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the number of registered species in the composition. <br/></td></tr>
<trclass="memdesc:a262d7133035d4e6f45daa81827abf5e7"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Sets the molar abundance for a given symbol. <br/></td></tr>
<trclass="memdesc:ac386709ef1e872fa558b8e30fc8b4c44"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Sets the molar abundance for a given isotope. <br/></td></tr>
<trclass="memdesc:a6baa22b92a78fd43d10d4941f30c8ac2"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Sets the molar abundances for a list of symbols. <br/></td></tr>
<trclass="memdesc:ae908cda3a994292e2eb767fa476b666b"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Sets the molar abundances for a list of isotopes. <br/></td></tr>
<trclass="memdesc:a49b06737a50df9c25a234499a1431388"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Sets the molar abundances for a set of symbols. <br/></td></tr>
<trclass="memdesc:ad7af2f8f3050969a6c5b9a9ef5fead64"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Sets the molar abundances for a set of isotopes. <br/></td></tr>
<trclass="memdesc:a3ae885c28580ae15be8c16614bef3b0e"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the registered symbols. <br/></td></tr>
<trclass="memdesc:a33db253ca50431b5166d43412ff18f71"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Get a set of all species that are registered in the composition. <br/></td></tr>
<trclass="memdesc:a9ea2b673341fdc67afeb0f0517a54c8c"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the mass fractions of all species in the composition. <br/></td></tr>
<trclass="memdesc:ae5d8d21632fca2b35b0898f2b205cd10"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the mass fraction for a given symbol. See the overload for species-based lookup for more details on how mass fractions are calculated. <br/></td></tr>
<trclass="memdesc:ae8fe4e7158f8317bf29b5cd0c65a9524"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the mass fraction for a given species. <br/></td></tr>
<trclass="memdesc:a34f71d4d8f0297c576fd62fabd490305"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the number fraction for a given symbol. See the overload for species-based lookup for more details on how number fractions are calculated. <br/></td></tr>
<trclass="memdesc:a1aa79993925f16ba3c30a376aa39161b"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the number fraction for a given species. <br/></td></tr>
<trclass="memdesc:a1f87ed64a1be9a6091c852131d24e476"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the number fractions of all species in the composition. <br/></td></tr>
<trclass="memdesc:add67a92d73e3a57a2bbdb52bc9ca3bfe"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the molar abundances of all species in the composition. <br/></td></tr>
<trclass="memdesc:a78a43e9e77a9c1b0f27c50b9feb52449"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the molar abundance for a given species. <br/></td></tr>
<trclass="memdesc:afbbb5e51ad5ae5c0fa6bc0094195aecd"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Compute the mean particle mass of the composition. <br/></td></tr>
<trclass="memdesc:a90fc71d1fe03017ee4c7a1cac69d24fb"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Compute the electron abundance of the composition. <br/></td></tr>
<trclass="memdesc:aac5b214a3d1278e127422224cb9cee50"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Compute the canonical composition (X, Y, Z) of the composition. <br/></td></tr>
<trclass="memdesc:af4f44aaf8b7e0d63872a70b5e2131369"><tdclass="mdescLeft"> </td><tdclass="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>
<trclass="memdesc:ae4f72972cf4d1ff422d0790080e11473"><tdclass="mdescLeft"> </td><tdclass="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>
<trclass="memdesc:abcb391f5fca2b636127e48e681e4c3ee"><tdclass="mdescLeft"> </td><tdclass="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>
<trclass="memdesc:a0d94f62402bb90b5d12679faeaa8c5d7"><tdclass="mdescLeft"> </td><tdclass="mdescRight">get the index in the sorted vector representation for a given symbol <br/></td></tr>
<trclass="memdesc:a3d220b42fa06d7d3a43944ee2b8f6a5f"><tdclass="mdescLeft"> </td><tdclass="mdescRight">get the index in the sorted vector representation for a given symbol <br/></td></tr>
<trclass="memdesc:ae4f854ded38f5e6fcd157a74a57cbf0c"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Get the species at a given index in the sorted vector representation. <br/></td></tr>
<trclass="memdesc:ab1701644ff1c83c220dc04eb58d1621b"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Returns an iterator to the beginning of the molar abundance map. <br/></td></tr>
<trclass="memdesc:adf41a833e8b704daf4f581fca5c8cb9b"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Returns a const iterator to the beginning of the molar abundance map. <br/></td></tr>
<trclass="memdesc:adeaf6f1213e78cb1fe8a8317f0a8adc2"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Returns an iterator to the end of the molar abundance map. <br/></td></tr>
<trclass="memdesc:aed2f5676f8f742199f01e4d1e9664bdd"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Returns a const iterator to the end of the molar abundance map. <br/></td></tr>
<trclass="inherit_header pub_methods_class_composition_abstract"><tdcolspan="2"onclick="javascript:dynsection.toggleInherit('pub_methods_class_composition_abstract')"><imgsrc="closed.png"alt="-"/> Public Member Functions inherited from <aclass="el"href="class_composition_abstract.html">CompositionAbstract</a></td></tr>
<trclass="memdesc:a46a706f9e4c06a45b45ae3dffdde5e9e"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Gets the logger instance for the <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> class. This is static to ensure that all composition objects share the same logger instance. <br/></td></tr>
<trclass="memdesc:a452b0affb86dc971a96c80d01f4fcb2b"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Set of registered species in the composition. <br/></td></tr>
<trclass="memdesc:aa05a640e0ea80142682bf4ee30a93c7f"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Map of species to their molar abundances. <br/></td></tr>
<trclass="memdesc:a02cd9d9608da082a200fdfa86d14bf5d"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Cache for computed properties to avoid redundant calculations. <br/></td></tr>
<trclass="memdesc:a36c2525d21cd932065bb2bb30bc57fb4"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Overloaded output stream operator for <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a>. <br/></td></tr>
<p>This class is a primary interface for defining and manipulating material compositions. In order to use the <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> class a user must first register symbols or species. Symbols are the string representation of a species (i.e. deuterium would be "H-2" whereas Beryllium 7 would be "Be-7") and then set the molar abundances. Species are the data structure <aclass="el"href="structfourdst_1_1atomic_1_1_species.html"title="Represents an atomic species (isotope) with its fundamental physical properties.">fourdst::atomic::Species</a> version. Here Deuterium would be represented by the Species <aclass="el"href="namespacefourdst_1_1atomic.html#a0eac406fa90f2925ea40737380ce0d74">fourdst::atomic::H_2</a> whereas Beryllium 7 would be <aclass="el"href="namespacefourdst_1_1atomic.html#a800b0869c767928825a71ae0d2382a95">fourdst::atomic::Be_7</a>. Once the symbols/species have been registered the user can then set molar abundances.</p>
<p>Once the <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> object has been populated the user can query mass fractions, number fractions, electron abundances, mean particle mass, molar abundance, and Canonical (X, Y, Z) composition.</p>
<dlclass="section note"><dt>Note</dt><dd>This class only accepts molar abundances as input. If you wish to construct a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> using a vector of mass fractions, those must first be converted to molar abundances. There is a helper function <code><aclass="el"href="namespacefourdst_1_1composition.html#aa90b1ef07d607c0c829bedccf381cf54"title="Build a Composition object from symbols and their corresponding mass fractions.">fourdst::composition::buildCompositionFromMassFractions</a></code> which wll facilitate just that.</dd></dl>
<tr><tdclass="paramname">This</td><td>class throws various exceptions from <code><aclass="el"href="namespacefourdst_1_1composition_1_1exceptions.html">fourdst::composition::exceptions</a></code> for invalid operations, such as using unregistered symbols or providing invalid abundances.</td></tr>
<divclass="line">comp.<aclass="code hl_function"href="#a262d7133035d4e6f45daa81827abf5e7">setMolarAbundance</a>(<spanclass="stringliteral">"He-4"</span>, 0.25); <spanclass="comment">// Note Molar Abundances do not need to sum to 1</span></div>
<divclass="ttc"id="aclassfourdst_1_1composition_1_1_composition_html_a262d7133035d4e6f45daa81827abf5e7"><divclass="ttname"><ahref="#a262d7133035d4e6f45daa81827abf5e7">fourdst::composition::Composition::setMolarAbundance</a></div><divclass="ttdeci">void setMolarAbundance(const std::string &symbol, const double &molar_abundance)</div><divclass="ttdoc">Sets the molar abundance for a given symbol.</div><divclass="ttdef"><b>Definition</b><ahref="composition_8cpp_source.html#l00529">composition.cpp:529</a></div></div>
<divclass="ttc"id="aclassfourdst_1_1composition_1_1_composition_html_a3ab4dcda0bfd1a35b169bcc57fe66725"><divclass="ttname"><ahref="#a3ab4dcda0bfd1a35b169bcc57fe66725">fourdst::composition::Composition::registerSymbol</a></div><divclass="ttdeci">void registerSymbol(const std::string &symbol)</div><divclass="ttdoc">Registers a new symbol for inclusion in the composition.</div><divclass="ttdef"><b>Definition</b><ahref="composition_8cpp_source.html#l00178">composition.cpp:178</a></div></div>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00097">97</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<p>Creates an empty <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> object. No symbols or species are registered initially; however, the user can register symbols or species later using the provided methods. </p>
<p>Constructs a <aclass="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 vector. </p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is invalid. Symbols are invalid if they are not registered at compile time in the atomic species database (<code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code>). </td></tr>
<divclass="ttc"id="aclassfourdst_1_1composition_1_1_composition_html"><divclass="ttname"><ahref="classfourdst_1_1composition_1_1_composition.html">fourdst::composition::Composition</a></div><divclass="ttdoc">Manages a collection of chemical species and their abundances.</div><divclass="ttdef"><b>Definition</b><ahref="composition_8h_source.html#l00097">composition.h:97</a></div></div>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00084">84</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Constructs a <aclass="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 species from a vector. </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">species</td><td>The species to register. </td></tr>
</table>
</dd>
</dl>
<dlclass="section user"><dt>Example:</dt><dd><divclass="fragment"><divclass="line">std::vector<fourdst::atomic::Species> species = {<aclass="code hl_function"href="namespacefourdst_1_1atomic.html#a6766bc834fd656df51bdcf22f7d97877">fourdst::atomic::H_1</a>, <aclass="code hl_function"href="namespacefourdst_1_1atomic.html#af2588b97ce949e37c193d6a3e5cb84a0">fourdst::atomic::O_16</a>};</div>
<dlclass="section note"><dt>Note</dt><dd>Because species are strongly typed, this constructor does not need to check if the species is valid. that is to say that the compiler will only allow valid species to be passed in. Therefore, this constructor is marked noexcept and may therefore be slightly more performant than the symbol-based constructor. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00100">100</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Constructs a <aclass="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>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is invalid. Symbols are invalid if they are not registered at compile time in the atomic species database (<code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code>). </td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00092">92</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Constructs a <aclass="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 species from a set. </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">species</td><td>The species to register. </td></tr>
</table>
</dd>
</dl>
<dlclass="section user"><dt>Example:</dt><dd><divclass="fragment"><divclass="line">std::set<fourdst::atomic::Species> species = {<aclass="code hl_function"href="namespacefourdst_1_1atomic.html#a6766bc834fd656df51bdcf22f7d97877">fourdst::atomic::H_1</a>, <aclass="code hl_function"href="namespacefourdst_1_1atomic.html#af2588b97ce949e37c193d6a3e5cb84a0">fourdst::atomic::O_16</a>};</div>
<dlclass="section note"><dt>Note</dt><dd>Because species are strongly typed, this constructor does not need to check if the species is valid. that is to say that the compiler will only allow valid species to be passed in. Therefore, this constructor is marked noexcept and may therefore be slightly more performant than the symbol-based constructor. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00108">108</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from symbols and their corresponding molar abundances. </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">symbols</td><td>The symbols to register. </td></tr>
<tr><tdclass="paramname">molarAbundances</td><td>The corresponding molar abundances for each symbol. </td></tr>
</table>
</dd>
</dl>
<dlclass="exception"><dt>Exceptions</dt><dd>
<tableclass="exception">
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is invalid. Symbols are invalid if they are not registered at compile time in the atomic species database (<code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code>). </td></tr>
<tr><tdclass="paramname"><aclass="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 does not match the number of molar abundances. </td></tr>
<dlclass="section note"><dt>Note</dt><dd>Molar abundances do not need to sum to 1.0, they are an absolute quantity. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00116">116</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from species and their corresponding molar abundances. </p>
<tr><tdclass="paramname"><aclass="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 species does not match the number of molar abundances. </td></tr>
<dlclass="section note"><dt>Note</dt><dd>Molar abundances do not need to sum to 1.0, they are an absolute quantity. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00131">131</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from symbols in a set and their corresponding molar abundances. </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">symbols</td><td>The symbols to register. </td></tr>
<tr><tdclass="paramname">molarAbundances</td><td>The corresponding molar abundances for each symbol. </td></tr>
</table>
</dd>
</dl>
<dlclass="exception"><dt>Exceptions</dt><dd>
<tableclass="exception">
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is invalid. Symbols are invalid if they are not registered at compile time in the atomic species database (<code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code>). </td></tr>
<tr><tdclass="paramname"><aclass="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 does not match the number of molar abundances. </td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00146">146</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Constructs a <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> from another <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a>. </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">composition</td><td>The <aclass="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>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00161">161</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<dlclass="section note"><dt>Note</dt><dd>Because we store molar abundances as a sorted map, keyed by species. And Because the < and > operators for species are defined based on their atomic mass. When iterating over the molar abundance map, species will be seen in order from lightest to heaviest. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00753">753</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<dlclass="section note"><dt>Note</dt><dd>Because we store molar abundances as a sorted map, keyed by species. And Because the < and > operators for species are defined based on their atomic mass. When iterating over the molar abundance map, species will be seen in order from lightest to heaviest. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00774">774</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00509">509</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Checks if a given symbol is present in the composition. </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramname">symbol</td><td>The symbol to check for. </td></tr>
</table>
</dd>
</dl>
<dlclass="section return"><dt>Returns</dt><dd>True if the symbol is in the composition, false otherwise. </dd></dl>
<dlclass="exception"><dt>Exceptions</dt><dd>
<tableclass="exception">
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if the symbol is not in the atomic species database. </td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00515">515</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<dlclass="section note"><dt>Note</dt><dd>Because we store molar abundances as a sorted map, keyed by species. And Because the < and > operators for species are defined based on their atomic mass. When iterating over the molar abundance map, species will be seen in order from lightest to heaviest. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00795">795</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<dlclass="section note"><dt>Note</dt><dd>Because we store molar abundances as a sorted map, keyed by species. And Because the < and > operators for species are defined based on their atomic mass. When iterating over the molar abundance map, species will be seen in order from lightest to heaviest. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00816">816</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<p>Compute the canonical composition (X, Y, Z) of the composition. </p>
<p>The canonical composition is defined as:</p><ul>
<li>X: mass fraction of hydrogen ( <imgclass="formulaInl"alt="$\sum_{i=1}^{7}X_{^{i}H}$"src="form_7.png"width="55"height="16"/>)</li>
<li>Y: mass fraction of helium ( <imgclass="formulaInl"alt="$\sum_{i=3}^{10}X_{^{i}He}$"src="form_8.png"width="60"height="16"/>)</li>
<li>Z: mass fraction of all other elements (Everything else)</li>
</ul>
<p>The canonical composition is computed by summing the mass fractions of all registered species in the composition according to their element type.</p>
<dlclass="section return"><dt>Returns</dt><dd>A <aclass="el"href="structfourdst_1_1composition_1_1_canonical_composition.html"title="Represents the canonical (X, Y, Z) composition of stellar material.">CanonicalComposition</a> struct containing the X, Y, and Z values.</dd></dl>
<dlclass="exception"><dt>Exceptions</dt><dd>
<tableclass="exception">
<tr><tdclass="paramname"><aclass="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, after constructing the canonical composition, the sum X + Y + Z is not approximately equal to 1.0 (within a tolerance of 1e-16) </td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00330">330</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00321">321</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Gets the logger instance for the <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> class. This is static to ensure that all composition objects share the same logger instance. </p>
<dlclass="section return"><dt>Returns</dt><dd>pointer to the logger instance. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00144">144</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00251">251</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="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>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00235">235</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if the symbol is not in the atomic species database. </td></tr>
<tr><tdclass="paramname"><aclass="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>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00227">227</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<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><dlclass="section return"><dt>Returns</dt><dd>the vector of mass fractions sorted by species mass (lightest to heaviest). </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00373">373</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00311">311</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="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>
<dlclass="section note"><dt>Note</dt><dd>These are the most performant quantities to retrieve since they are stored directly in the composition object and require no computation. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00302">302</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is not in the atomic species database. </td></tr>
<tr><tdclass="paramname"><aclass="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 symbol is not in the composition. </td></tr>
<dlclass="section return"><dt>Returns</dt><dd>The molar abundance of the symbol.</dd></dl>
<dlclass="section note"><dt>Note</dt><dd>These are the most performant quantities to retrieve since they are stored directly in the composition object and require no computation. This overload is slightly less performant than the species-based overload since it needs to validate the symbol exists in the atomic species database. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00291">291</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<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><dlclass="section return"><dt>Returns</dt><dd>the vector of molar abundances sorted by species mass (lightest to heaviest). </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00416">416</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00283">283</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<dlclass="section return"><dt>Returns</dt><dd>The number fraction for the given isotope. </dd></dl>
<dlclass="exception"><dt>Exceptions</dt><dd>
<tableclass="exception">
<tr><tdclass="paramname"><aclass="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>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00270">270</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Gets the number fraction for a given symbol. See the overload for species-based lookup for more details on how number fractions are calculated. </p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if the symbol is not in the atomic species database. </td></tr>
<tr><tdclass="paramname"><aclass="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>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00260">260</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<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><dlclass="section return"><dt>Returns</dt><dd>the vector of number fractions sorted by species mass (lightest to heaviest). </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00395">395</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<dlclass="section return"><dt>Returns</dt><dd>A set of <code><aclass="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>
<dlclass="section note"><dt>Note</dt><dd>This will return a constant reference to the internal m_registeredSpecies set, therefore the return value of this method will only be valid as long as the <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> object is valid (i.e. it cannot outlive the <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a> object it was called on). </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00222">222</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<dlclass="section return"><dt>Returns</dt><dd>A set of registered symbols.</dd></dl>
<dlclass="section note"><dt>Note</dt><dd>This method will construct a new set each time it is called. If you need just need access to the registered species, consider using <code><aclass="el"href="#a33db253ca50431b5166d43412ff18f71"title="Get a set of all species that are registered in the composition.">getRegisteredSpecies()</a></code> instead which returns a constant reference to the internal set. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00214">214</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dlclass="params"><dt>Parameters</dt><dd>
<tr><tdclass="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>
<dlclass="exception"><dt>Exceptions</dt><dd>
<tableclass="exception">
<tr><tdclass="paramname">std::out_of_range</td><td>if the index is out of range. </td></tr>
</table>
</dd>
</dl>
<dlclass="section return"><dt>Returns</dt><dd>The species at the given index in the sorted vector representation. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00483">483</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dlclass="params"><dt>Parameters</dt><dd>
<tr><tdclass="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 <aclass="el"href="#abcb391f5fca2b636127e48e681e4c3ee"title="Get a uniform vector representation of the molar abundances stored in the composition object sorted s...">getMolarAbundanceVector()</a>, <aclass="el"href="#af4f44aaf8b7e0d63872a70b5e2131369"title="Get a uniform vector representation of the mass fraction stored in the composition object sorted such...">getMassFractionVector()</a>, or <aclass="el"href="#ae4f72972cf4d1ff422d0790080e11473"title="Get a uniform vector representation of the number fractions stored in the composition object sorted s...">getNumberFractionVector()</a></td></tr>
<tr><tdclass="paramname"><aclass="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>
<dlclass="section return"><dt>Returns</dt><dd>The index of the symbol in the sorted vector representation. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00449">449</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>This is primarily useful for external libraries which need to ensure that vector representation uniformity is maintained </p><dlclass="params"><dt>Parameters</dt><dd>
<tr><tdclass="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 <aclass="el"href="#abcb391f5fca2b636127e48e681e4c3ee"title="Get a uniform vector representation of the molar abundances stored in the composition object sorted s...">getMolarAbundanceVector()</a>, <aclass="el"href="#af4f44aaf8b7e0d63872a70b5e2131369"title="Get a uniform vector representation of the mass fraction stored in the composition object sorted such...">getMassFractionVector()</a>, or <aclass="el"href="#ae4f72972cf4d1ff422d0790080e11473"title="Get a uniform vector representation of the number fractions stored in the composition object sorted s...">getNumberFractionVector()</a></td></tr>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if the symbol is not in the atomic species database. </td></tr>
<tr><tdclass="paramname"><aclass="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>
<dlclass="section return"><dt>Returns</dt><dd>The index of the symbol in the sorted vector representation. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00438">438</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname">other</td><td>The <aclass="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>
<dlclass="section return"><dt>Returns</dt><dd>A reference to this <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a>. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00168">168</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<divclass="ttc"id="aclassfourdst_1_1composition_1_1_composition_html_a392a34c19f45d6c936cc7030e6cfaf3f"><divclass="ttname"><ahref="#a392a34c19f45d6c936cc7030e6cfaf3f">fourdst::composition::Composition::registerSpecies</a></div><divclass="ttdeci">void registerSpecies(const atomic::Species &species) noexcept</div><divclass="ttdoc">Registers a new species by extracting its symbol.</div><divclass="ttdef"><b>Definition</b><ahref="composition_8cpp_source.html#l00197">composition.cpp:197</a></div></div>
<dlclass="section note"><dt>Note</dt><dd>Because species are strongly typed, this method does not need to check if the species is valid. that is to say that the compiler will only allow valid species to be passed in. Therefore, this method is marked noexcept and may therefore be slightly more performant than the symbol-based method.</dd>
<dd>
upon registering a species, its molar abundance is initialized to 0.0.</dd>
<dd>
All species are in the <code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code> header file. These can be accessed directly through their fully qualified names (e.g., <code><aclass="el"href="namespacefourdst_1_1atomic.html#a21ab5363d81d491f5230e8d90a149f31">fourdst::atomic::C_12</a></code> for Carbon-12). Alternatively, these can also be accessed through a string-indexed map located in <code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code> called <code><aclass="el"href="namespacefourdst_1_1atomic.html#a3f619cc8f8b2cd718a4082c6adb0de90"title="Map of species names to their corresponding Species objects.">fourdst::atomic::species</a></code> ( e.g., <code>fourdst::atomic::species.at("C-12")</code> for Carbon-12). </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00197">197</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<dlclass="section note"><dt>Note</dt><dd>upon registering a species, its molar abundance is initialized to 0.0. Therefore, registering a vector of species will initialize all their molar abundances to 0.0.</dd>
<dd>
All species are in the <code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code> header file. These can be accessed directly through their fully qualified names (e.g., <code><aclass="el"href="namespacefourdst_1_1atomic.html#a21ab5363d81d491f5230e8d90a149f31">fourdst::atomic::C_12</a></code> for Carbon-12). Alternatively, these can also be accessed through a string-indexed map located in <code><aclass="el"href="species_8h.html">fourdst/atomic/species.h</a></code> called <code><aclass="el"href="namespacefourdst_1_1atomic.html#a3f619cc8f8b2cd718a4082c6adb0de90"title="Map of species names to their corresponding Species objects.">fourdst::atomic::species</a></code> ( e.g., <code>fourdst::atomic::species.at("C-12")</code> for Carbon-12). </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00206">206</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if the symbol is not in the atomic species database. </td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00178">178</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is invalid. </td></tr>
<dlclass="section note"><dt>Note</dt><dd>upon registering a symbol, its molar abundance is initialized to 0.0. Therefore, registering a vector of symbols will initialize all their molar abundances to 0.0. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00189">189</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="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>
<tr><tdclass="paramname"><aclass="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 molar abundance is negative.</td></tr>
<dlclass="section note"><dt>Note</dt><dd>Since this method does not need to validate the species exists in the database, it will generally be slightly more performant than the symbol-based method. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00541">541</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="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 isotope is not registered in the composition. </td></tr>
<tr><tdclass="paramname"><aclass="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 any molar abundance is negative.</td></tr>
<dlclass="section note"><dt>Note</dt><dd>Since this method does not need to validate the species exists in the database, it will generally be slightly more performant than the symbol-based method. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00582">582</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is not in the atomic species database. </td></tr>
<tr><tdclass="paramname"><aclass="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 symbol is not in the composition. </td></tr>
<tr><tdclass="paramname"><aclass="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 any molar abundance is negative.</td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00573">573</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if the symbol is not in the atomic species database. </td></tr>
<tr><tdclass="paramname"><aclass="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>
<tr><tdclass="paramname"><aclass="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 molar abundance is negative.</td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00529">529</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="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 isotope is not registered in the composition. </td></tr>
<tr><tdclass="paramname"><aclass="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 any molar abundance is negative.</td></tr>
<dlclass="section note"><dt>Note</dt><dd>Since this method does not need to validate the species exists in the database, it will generally be slightly more performant than the symbol-based method. </dd></dl>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00564">564</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<tr><tdclass="paramname"><aclass="el"href="classfourdst_1_1composition_1_1exceptions_1_1_unknown_symbol_error.html"title="Exception thrown when an unknown symbol is encountered.">exceptions::UnknownSymbolError</a></td><td>if any symbol is not in the atomic species database. </td></tr>
<tr><tdclass="paramname"><aclass="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 symbol is not in the composition. </td></tr>
<tr><tdclass="paramname"><aclass="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 any molar abundance is negative.</td></tr>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00555">555</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00525">525</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<p>Overloaded output stream operator for <aclass="el"href="classfourdst_1_1composition_1_1_composition.html"title="Manages a collection of chemical species and their abundances.">Composition</a>. </p>
<tr><tdclass="paramname">composition</td><td>The <aclass="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>
<pclass="definition">Definition at line <aclass="el"href="composition_8cpp_source.html#l00593">593</a> of file <aclass="el"href="composition_8cpp_source.html">composition.cpp</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00152">152</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00150">150</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<pclass="definition">Definition at line <aclass="el"href="composition_8h_source.html#l00149">149</a> of file <aclass="el"href="composition_8h_source.html">composition.h</a>.</p>
<liclass="footer">Generated by <ahref="https://www.doxygen.org/index.html"><imgclass="footer"src="doxygen.svg"width="104"height="31"alt="doxygen"/></a> 1.13.2 </li>