{"success":true,"version":"v1","request":{"tool":"get_calculator_schema","calculator_id":"mean-types"},"result":{"entity_type":"calculator","id":"mean-types","calculator_id":"mean-types","canonical_url":"https://tttkmbb.com/math/mean-types","name":"Mean Calculator (Arithmetic, Geometric, Harmonic, Quadratic)","title":"Mean Calculator – Arithmetic, Geometric, Harmonic, Quadratic (RMS), Contraharmonic Means and Midrange","category":"math","category_name":"Math","tool_name":"calculate_mean_types","featured_mcp_tool":false,"description":"Computes the Pythagorean means (arithmetic, geometric, harmonic) of a list of numbers together with the quadratic mean (root mean square), the contraharmonic mean, the midrange and the median.","use_when":"You need a specific kind of average, e.g. the geometric mean of growth factors, the harmonic mean of rates or speeds, or the RMS of signal values, or want to compare the different means of one data set.","do_not_use_when":"You need dispersion measures such as variance and standard deviation (use descriptive-statistics) or a weighted average (use weighted-average).","inputs":[{"name":"numbers","label":"Numbers","type":"number_list","required":true,"description":"The values, comma-separated. Geometric and harmonic means require all values to be positive.","example":[1,2,4,8]}],"outputs":[{"name":"arithmetic_mean","label":"Arithmetic mean","type":"number","decimals":6,"description":"Σx / n."},{"name":"geometric_mean","label":"Geometric mean","type":"number","decimals":6,"description":"(Πx)^(1/n), computed as exp(mean(ln x)); only for positive values."},{"name":"harmonic_mean","label":"Harmonic mean","type":"number","decimals":6,"description":"n / Σ(1/x); only for positive values."},{"name":"quadratic_mean","label":"Quadratic mean (RMS)","type":"number","decimals":6,"description":"√(Σx² / n), the root mean square."},{"name":"contraharmonic_mean","label":"Contraharmonic mean","type":"number","decimals":6,"description":"Σx² / Σx (requires Σx ≠ 0)."},{"name":"midrange","label":"Midrange","type":"number","decimals":6,"description":"(min + max) / 2."},{"name":"median","label":"Median","type":"number","decimals":6,"description":"Middle value of the sorted list (mean of the two middle values for an even count)."},{"name":"count","label":"Count","type":"integer","decimals":0,"description":"Number of values n."},{"name":"inequality","label":"Mean inequality","type":"string","decimals":4,"description":"For positive values: harmonic ≤ geometric ≤ arithmetic ≤ quadratic ≤ contraharmonic, with equality only when all values are equal."}],"input_schema":{"type":"object","properties":{"numbers":{"description":"The values, comma-separated. Geometric and harmonic means require all values to be positive.","type":"array","items":{"type":"number"},"minItems":1,"examples":[[1,2,4,8]]}},"additionalProperties":false,"required":["numbers"]},"output_schema":{"type":"object","properties":{"arithmetic_mean":{"description":"Σx / n.","type":"number"},"geometric_mean":{"description":"(Πx)^(1/n), computed as exp(mean(ln x)); only for positive values.","type":"number"},"harmonic_mean":{"description":"n / Σ(1/x); only for positive values.","type":"number"},"quadratic_mean":{"description":"√(Σx² / n), the root mean square.","type":"number"},"contraharmonic_mean":{"description":"Σx² / Σx (requires Σx ≠ 0).","type":"number"},"midrange":{"description":"(min + max) / 2.","type":"number"},"median":{"description":"Middle value of the sorted list (mean of the two middle values for an even count).","type":"number"},"count":{"description":"Number of values n.","type":"integer"},"inequality":{"description":"For positive values: harmonic ≤ geometric ≤ arithmetic ≤ quadratic ≤ contraharmonic, with equality only when all values are equal.","type":"string"}}},"formula":"A = Σx/n; G = (Πx)^(1/n); H = n/Σ(1/x); Q = √(Σx²/n); C = Σx²/Σx; midrange = (min + max)/2","sources":[{"name":"Wikipedia – Pythagorean means","url":"https://en.wikipedia.org/wiki/Pythagorean_means","type":"reference","retrieved_at":"2026-09-24"},{"name":"Wikipedia – Root mean square","url":"https://en.wikipedia.org/wiki/Root_mean_square","type":"reference","retrieved_at":"2026-09-24"},{"name":"Wikipedia – Contraharmonic mean","url":"https://en.wikipedia.org/wiki/Contraharmonic_mean","type":"reference","retrieved_at":"2026-09-24"}],"freshness":{"type":"static","max_age_seconds":null,"note":"Deterministic formula with fixed constants; results never go stale. Inputs supplied by the caller determine the output."},"examples":[{"name":"1, 2, 4, 8","inputs":{"numbers":[1,2,4,8]},"expected":{"arithmetic_mean":3.75,"geometric_mean":2.828427,"harmonic_mean":2.133333,"quadratic_mean":4.609772,"contraharmonic_mean":5.666667,"midrange":4.5,"median":3,"count":4},"url":"https://tttkmbb.com/api/v1/calculate/mean-types?numbers=1%2C2%2C4%2C8"},{"name":"4 and 9","inputs":{"numbers":[4,9]},"expected":{"arithmetic_mean":6.5,"geometric_mean":6,"harmonic_mean":5.538462,"quadratic_mean":6.964194,"contraharmonic_mean":7.461538,"midrange":6.5,"median":6.5,"count":2},"url":"https://tttkmbb.com/api/v1/calculate/mean-types?numbers=4%2C9"}],"faq":[{"q":"When should I use the geometric or harmonic mean?","a":"Geometric for quantities that multiply (growth rates, ratios, index numbers); harmonic for rates over a fixed quantity (average speed over equal distances, price/earnings ratios). The arithmetic mean overstates both."},{"q":"Why is the geometric mean missing?","a":"It is only defined for positive values (a zero makes it 0 and negatives make it complex), so it and the harmonic mean are omitted, with a note, when the list contains zero or negative numbers."}],"tags":["geometric mean","harmonic mean","arithmetic mean","root mean square","contraharmonic mean","types of average"],"related":[{"calculator_id":"descriptive-statistics","reason":"Full summary statistics including variance and quartiles."},{"calculator_id":"weighted-average","reason":"Average with different weights per value."},{"calculator_id":"cagr","reason":"The geometric mean growth rate of an investment."}],"links":{"html":"https://tttkmbb.com/math/mean-types","markdown":"https://tttkmbb.com/math/mean-types.md","json":"https://tttkmbb.com/math/mean-types.json","api":"https://tttkmbb.com/api/v1/calculate/mean-types","schema":"https://tttkmbb.com/api/v1/calculators/mean-types","openapi":"https://tttkmbb.com/openapi.json","mcp":"https://tttkmbb.com/mcp"},"version":"v1","updated_at":"2026-09-24"},"timestamp":"2026-09-24T01:51:01Z"}