About the calculator
How to use each page, how the values are calculated, and where the element data come from.
- Calculator
- How the values are calculated
- Supported chemical formula formats
- Batch calculation
- Element information
- Plot
- Data sources
Calculator
The calculator calculates, as you type, the crustal abundance, the effective elemental scarcity (in inverse ppm), and the Herfindahl–Hirschman Index for production and reserves of a compound from its chemical formula.
You can type, paste, or edit a formula in the input field, or build it by clicking the periodic table. Each left click on an element raises its stoichiometric coefficient by one, and each right click lowers it. To edit an existing formula, place the cursor next to an element and click its tile.
For example, clicking lithium twice and oxygen once gives Li2O. Placing the cursor after the O and clicking oxygen again changes the formula to lithium peroxide, Li2O2.
The results appear below the input as five cards. Each HHI card also names the market-concentration band: unconcentrated below 1500, moderately concentrated from 1500 to 2500, and highly concentrated above 2500. A value reads “N/A” when an element in the formula lacks abundance or HHI data. The Copy button copies the values as tab-separated text that pastes directly into a spreadsheet. Adding ?f= and a formula to the page address, as in ?f=Li2O, opens the calculator with that formula filled in.
How the values are calculated
Every compound value is an average over its elements, weighted by the weight fraction wi = niMi/M, where ni is the stoichiometric coefficient, Mi the atomic mass of element i, and M the molar mass of the compound.
Abundance (ppm) = Σ wi Ai
Scarcity (ppm−1) = Σ wi / Ai
HHI (production) = Σ wi HHIP,i, and likewise for HHI (reserves)
Here Ai is the crustal abundance of element i. These are the definitions used by Gaultois et al. and the original publication of this calculator.
Supported chemical formula formats
The calculator accepts formulas containing:
- chemical symbols
- stoichiometric coefficients, including non-integer values such as 0.025 or 0.1
- charges, written as
+and-(ignored in the calculation) - parentheses for repeating units and square brackets for complex salts
- an underscore before a coefficient to denote a subscript
- hydrates and adducts separated by
·or*, such asCuSO4·5H2O
Examples of valid formulas:
Na
Na+
Li2O
Zn0.9975Al0.0025O1
C12H22O11
H(CO)(CHOH)5H
Ca(OH)2
Mg3(PO4)2
((((Pt)7)5))
NH4[Cr(SCN)4(NH3)2]3
(CH_3)_2CHOH
CuSO4·5H2O
A formula can contain any number of elements.
Batch calculation
The calculator also handles lists of compounds. Upload a text or CSV file in the Batch calculation section below the periodic table, or drag the file onto that box. Separate the formulas with new lines, commas, or both:
Cr2O7
Ca(OH)2
Mg3(PO4)2
Cr2O7,Ca(OH)2,Mg3(PO4)2
Output
The calculation finishes in the browser, displays a table of results, and downloads results.csv with these columns:
- Formula, as provided
- Molar mass of the compound
- Abundance (ppm), the weight-fraction average of crustal abundance
- Scarcity (1/ppm), the weight-fraction average of inverse crustal abundance
- HHI (production), the weight-fraction average of HHI production values
- HHI (reserves), the weight-fraction average of HHI reserves values
- error_message, which reads “OK” for a complete calculation and otherwise describes the problem, such as a formula that cannot be parsed or an element without data
The site rounds every value to three decimals and drops trailing zeros. Values below 0.01 appear in scientific notation with three decimals, such as 2.372 × 10−3 on screen and 2.372e-3 in the CSV file, so they keep their significant figures. The calculations themselves use full precision.
The abundance, scarcity, and HHI columns read “N/A” when an element in the compound lacks the corresponding data.
Element information
Clicking an element on the Element information page shows its atomic number, molar mass, symbol, name, abundance, scarcity, HHI (production), and HHI (reserves). The page also lists every element in one table, and the full data set downloads as a CSV file.
For the elements in the USGS data, a world map below the element card shades each country by its share of world production or reserves, next to a list of the leading countries and the resulting HHI. The Production and Reserves tabs switch between the two. Crustal abundance has no country breakdown, so scarcity has no map. For the rare earths and the platinum-group metals, the map shows the group as USGS reports it.
Plot
The Plot page places compounds on a scatter plot. Enter a formula and press “Add to plot” or Enter, or open “Build a formula from the periodic table” to click elements. Each compound appears as a dark diamond labeled with its formula. By default, the plot also shows every element with abundance data as a small tile bearing its symbol. The browser remembers the compounds you add until you remove them.
Any combination of molar mass, HHI (production), HHI (reserves), scarcity, and abundance can be assigned to the x axis, the y axis, and the marker size. Setting the marker size to “None” draws every marker at the same size. Scarcity and abundance use logarithmic axes, labeled with metric prefixes such as µ for micro (10−6) and m for milli (10−3). “Color by” shades each element tile by its supply risk (green below an HHI of 1500, amber from 1500 to 2500, red above 2500, for production or reserves), by element family, or not at all. Whenever an HHI value sits on an axis, the same three risk bands appear as shaded zones. Hovering over a marker shows all of its values.
The “Show elements” checkbox hides the element tiles, and “Element symbols” switches between labeled tiles and small unlabeled ones. The Export button saves the plot as a PDF, PNG, or SVG file, exactly as displayed.
Data sources
Atomic masses and crustal abundances come from the compilation of Gaultois et al. (reference 1), which draws on the CRC Handbook of Chemistry and Physics.
HHI values come from the most recent USGS Mineral Commodity Summaries (2026 edition, with 2025 estimates; reference 6). For each element, the HHI is the sum of the squared percentage shares of each country listed for mine production, or for refinery or smelter production where USGS reports no mine figure, and likewise for reserves. Shares are taken of the world total. The USGS “Other countries” entry counts toward that total but not as a single producer, because it combines many small ones. Elements that USGS reports as a group share its value: the rare earths apply to La–Lu and Y, and the platinum-group metal reserves apply to Ru, Rh, Pd, Os, Ir, and Pt. As in the 2013 compilation, Ru and Rh follow palladium production, and Os and Ir follow platinum.
Where USGS gives no country-level data, such as for O, C, Ca, B, Ge, Hf, and most reserves of by-product metals, the HHI values of Gaultois et al. (2013) apply. The element table on the Element information page names the source of each value, and the full data set is available as a CSV file.
The photo on the calculator page shows six rare-earth oxide powders, the elements with the most concentrated supply in this data set. Photo by Peggy Greb, U.S. Department of Agriculture Agricultural Research Service (public domain).
The calculator runs entirely in your browser. Formulas and files you enter are never uploaded.