{"success":true,"version":"v1","request":{"tool":"get_calculator_schema","calculator_id":"density-mass-volume"},"result":{"entity_type":"calculator","id":"density-mass-volume","calculator_id":"density-mass-volume","canonical_url":"https://tttkmbb.com/physics/density-mass-volume","name":"Density Calculator","title":"Density Calculator – ρ = m / V, Solve for Density, Mass or Volume in kg/m³ and g/cm³","category":"physics","category_name":"Physics","tool_name":"solve_density","featured_mcp_tool":false,"description":"Solves ρ = m / V for whichever of density, mass or volume is omitted, and reports density in kg/m³ and g/cm³, volume in litres and cm³, and the specific gravity relative to water.","use_when":"You know two of mass, volume and density of an object or substance and need the third, e.g. the mass of a steel block, the volume of a litre of oil, or whether an object floats.","do_not_use_when":"The substance is a gas whose density depends strongly on pressure and temperature (use ideal-gas-law), or you need the volume of a shape first (use sphere, cylinder or rectangular-prism).","inputs":[{"name":"mass_kg","label":"Mass","type":"number","unit":"kg","required":false,"min":0,"description":"Mass in kilograms (1 g = 0.001 kg). Omit to solve for it.","example":2},{"name":"volume_m3","label":"Volume","type":"number","unit":"m³","required":false,"exclusive_min":0,"description":"Volume in cubic metres (1 L = 0.001 m³, 1 cm³ = 1e-6 m³). Omit to solve for it.","example":0.0025},{"name":"density_kg_m3","label":"Density","type":"number","unit":"kg/m³","required":false,"exclusive_min":0,"description":"Density in kg/m³ (1 g/cm³ = 1000 kg/m³; water ≈ 1000, steel ≈ 7850, aluminium ≈ 2700). Omit to solve for it."}],"outputs":[{"name":"solved_for","label":"Solved for","type":"string","decimals":4,"description":"Which quantity was computed: density_kg_m3, mass_kg or volume_m3."},{"name":"density_kg_m3","label":"Density","type":"number","unit":"kg/m³","decimals":4,"description":"ρ = m / V."},{"name":"density_g_cm3","label":"Density","type":"number","unit":"g/cm³","decimals":6,"description":"Density in grams per cubic centimetre (= kg/L)."},{"name":"mass_kg","label":"Mass","type":"number","unit":"kg","decimals":6,"description":"Mass in kilograms."},{"name":"mass_g","label":"Mass","type":"number","unit":"g","decimals":4,"description":"Mass in grams."},{"name":"volume_m3","label":"Volume","type":"number","unit":"m³","decimals":8,"description":"Volume in cubic metres."},{"name":"volume_l","label":"Volume","type":"number","unit":"L","decimals":6,"description":"Volume in litres."},{"name":"volume_cm3","label":"Volume","type":"number","unit":"cm³","decimals":4,"description":"Volume in cubic centimetres."},{"name":"specific_gravity","label":"Specific gravity","type":"number","decimals":6,"description":"Density relative to water at 1000 kg/m³; below 1 the object floats in water."},{"name":"floats_in_water","label":"Floats in water","type":"boolean","decimals":4,"description":"True when the density is below 1000 kg/m³."}],"input_schema":{"type":"object","properties":{"mass_kg":{"description":"Mass in kilograms (1 g = 0.001 kg). Omit to solve for it. Unit: kg.","type":"number","minimum":0,"examples":[2],"x-unit":"kg"},"volume_m3":{"description":"Volume in cubic metres (1 L = 0.001 m³, 1 cm³ = 1e-6 m³). Omit to solve for it. Unit: m³.","type":"number","exclusiveMinimum":0,"examples":[0.0025],"x-unit":"m³"},"density_kg_m3":{"description":"Density in kg/m³ (1 g/cm³ = 1000 kg/m³; water ≈ 1000, steel ≈ 7850, aluminium ≈ 2700). Omit to solve for it. Unit: kg/m³.","type":"number","exclusiveMinimum":0,"x-unit":"kg/m³"}},"additionalProperties":false},"output_schema":{"type":"object","properties":{"solved_for":{"description":"Which quantity was computed: density_kg_m3, mass_kg or volume_m3.","type":"string"},"density_kg_m3":{"description":"ρ = m / V. Unit: kg/m³.","type":"number","x-unit":"kg/m³"},"density_g_cm3":{"description":"Density in grams per cubic centimetre (= kg/L). Unit: g/cm³.","type":"number","x-unit":"g/cm³"},"mass_kg":{"description":"Mass in kilograms. Unit: kg.","type":"number","x-unit":"kg"},"mass_g":{"description":"Mass in grams. Unit: g.","type":"number","x-unit":"g"},"volume_m3":{"description":"Volume in cubic metres. Unit: m³.","type":"number","x-unit":"m³"},"volume_l":{"description":"Volume in litres. Unit: L.","type":"number","x-unit":"L"},"volume_cm3":{"description":"Volume in cubic centimetres. Unit: cm³.","type":"number","x-unit":"cm³"},"specific_gravity":{"description":"Density relative to water at 1000 kg/m³; below 1 the object floats in water.","type":"number"},"floats_in_water":{"description":"True when the density is below 1000 kg/m³.","type":"boolean"}}},"formula":"density_kg_m3 = mass_kg / volume_m3; mass_kg = density_kg_m3 × volume_m3; volume_m3 = mass_kg / density_kg_m3; density_g_cm3 = density_kg_m3 / 1000; specific_gravity = density_kg_m3 / 1000","sources":[{"name":"Wikipedia – Density","url":"https://en.wikipedia.org/wiki/Density","type":"reference","retrieved_at":"2026-09-23"},{"name":"NIST Special Publication 811 – Guide for the Use of the SI, Appendix B (conversion factors)","url":"https://www.nist.gov/pml/special-publication-811","type":"standard","retrieved_at":"2026-09-23"}],"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":"2 kg in 2.5 L","inputs":{"mass_kg":2,"volume_m3":0.0025},"expected":{"solved_for":"density_kg_m3","density_kg_m3":800,"density_g_cm3":0.8,"volume_l":2.5,"specific_gravity":0.8,"floats_in_water":true},"url":"https://tttkmbb.com/api/v1/calculate/density-mass-volume?mass_kg=2&volume_m3=0.0025"},{"name":"1 L of steel (7850 kg/m³)","inputs":{"density_kg_m3":7850,"volume_m3":0.001},"expected":{"solved_for":"mass_kg","mass_kg":7.85,"mass_g":7850,"floats_in_water":false},"url":"https://tttkmbb.com/api/v1/calculate/density-mass-volume?density_kg_m3=7850&volume_m3=0.001"}],"faq":[{"q":"How do I enter volume in litres or cm³?","a":"Convert to m³ first: litres ÷ 1000, cm³ ÷ 1,000,000. The outputs report the volume in L and cm³ as well."},{"q":"Is specific gravity the same as density in g/cm³?","a":"Numerically almost: specific gravity is density divided by that of water (about 1000 kg/m³ at 4 °C), so it is dimensionless while g/cm³ has units."}],"tags":["density","mass volume density","specific gravity","kg/m3","g/cm3","does it float"],"related":[{"calculator_id":"pressure-force-area","reason":"Force and pressure exerted by a mass."},{"calculator_id":"sphere","reason":"Volume of a sphere for the density formula."},{"calculator_id":"cylinder","reason":"Volume of a cylinder for the density formula."}],"links":{"html":"https://tttkmbb.com/physics/density-mass-volume","markdown":"https://tttkmbb.com/physics/density-mass-volume.md","json":"https://tttkmbb.com/physics/density-mass-volume.json","api":"https://tttkmbb.com/api/v1/calculate/density-mass-volume","schema":"https://tttkmbb.com/api/v1/calculators/density-mass-volume","openapi":"https://tttkmbb.com/openapi.json","mcp":"https://tttkmbb.com/mcp"},"version":"v1","updated_at":"2026-09-23"},"timestamp":"2026-09-23T23:30:00Z","next_actions":[{"tool":"run_calculator","calculator_id":"density-mass-volume","reason":"Run Density Calculator with the inputs above."}],"links":{"markdown":"https://tttkmbb.com/physics/density-mass-volume.md"}}