materials_compendium.utils.Material.get_formula

Material.get_formula()[source]

Get the formula of the material.

Returns:

The formula of the material.

Return type:

str

Example

print(material.get_formula()) # Output: “H2O”