functionCalculateMolarMass_MoleFractionBased

Information

Returns the molar mass (kg/mol) of a chemical formula with mole fraction weighting.

For example, calling the function with


chemical formula = {"LiF","NaK","KF"}

x_i = {0.465,0.115,0.42}

yields

molarMass = 0.102031066 kg/mol.

Inputs

TypeNameDefaultDescription
StringchemicalFormula{""}Array of each species
Realx_i{1.0}Mole fraction of each species

Outputs

TypeNameDefaultDescription
SI.MolarMassmolarMassMolar mass