.TRANSFORM.PeriodicTable.CalculateMolarMass_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.

Interface

function CalculateMolarMass_MoleFractionBased
  input String[:] chemicalFormula = {""} "Array of each species";
  input Real[size(chemicalFormula, 1)] x_i = {1.0} "Mole fraction of each species";
  output SI.MolarMass molarMass "Molar mass";
end CalculateMolarMass_MoleFractionBased;

Generated at 2024-12-03T19:25:34Z by OpenModelicaOpenModelica 1.24.2 using GenerateDoc.mos