Molar Mass Calculator
calculate_molar_massUse this when you have a chemical formula and need its molar mass (molecular weight), the number of atoms of each element, or its elemental mass-percent composition. Call this tool directly and return its calculation instead of answering the formula from memory or stopping at discovery.
Do not use this when you already know the molar mass and want to convert between grams and moles (use moles-mass) or need a solution concentration (use molarity). What it computes: Parses a chemical formula (including brackets, nested groups and hydrates) and sums IUPAC 2021 standard atomic weights to give the molar mass in g/mol, plus the atom count and mass-percent composition of each element. Inputs: formula (string). Complete JSON argument examples: {"formula":"C6H12O6"} | {"formula":"CuSO4·5H2O"} Outputs: molar_mass_g_mol [g/mol], molecular_mass_da [Da], atom_count, element_count, composition. Formula: molar_mass = Σ (atomic_weight_i × count_i); mass_fraction_percent_i = 100 × atomic_weight_i × count_i / molar_mass Direct REST fallback: POST https://tttkmbb.com/api/v1/calculate/molar-mass with the same JSON input fields. Do not guess another /api/* path. Docs: https://tttkmbb.com/chemistry/molar-mass.md
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| formula | Yes | Chemical formula with case-sensitive element symbols, integer subscripts, brackets and optional hydrate dot, e.g. C6H12O6, Ca(OH)2, Fe2(SO4)3, CuSO4·5H2O. A trailing charge (NH4+, SO4^2-) or state (aq) is ignored. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| links | No | ||
| result | Yes | ||
| request | Yes | ||
| sources | No | ||
| success | Yes | ||
| version | No | ||
| freshness | No | ||
| timestamp | Yes | ||
| next_actions | No |