Worked Examples
Apply dimensional analysis — Sustainable Catalyst Workbench
Apply dimensional analysis — Sustainable Catalyst Workbench Availability: The physical-quantity implementation and the local examples below were inspected/tested at the pinned source revision. Full application startup, browser con
Apply dimensional analysis — Sustainable Catalyst Workbench
Availability: The physical-quantity implementation and the local examples below were inspected/tested at the pinned source revision. Full application startup, browser controls, authentication, WordPress integration and deployed behavior remain UNVERIFIED. These are internal drafts, not approved public instructions. A local router test is not a production acceptance test.
The source module’s historical label is v11.7.0, but backend/app/release.py currently reports 14.0.0 and the README reports v10.4.0. Use the commit to identify this behavior; do not infer installed-version compatibility from those conflicting labels.
Goal and prerequisites
Reproduce a unit conversion and a force calculation, then inspect the dimensions. The verified beginner path here is a local, copyable Python exercise, not a sequence of website clicks. A maintainer must provide an isolated checkout of the pinned Workbench revision and a Python environment capable of importing its modules. Do not change a production installation to run this exercise.
The verification environment used Python 3.14.7, Pint 0.26.2, Pydantic 2.14.3, FastAPI 0.162.4 and httpx 0.28.1. These record the tested environment; they do not certify the repository’s complete dependency set or all supported Python versions. The repository requirements use ranges, so save the resolved package list when reproducing the exercise. Full application startup is currently blocked by a missing module; importing the inspected quantity module directly avoids asserting that the whole service works.
Run the worked example
- Open a terminal in the Workbench repository root. Confirm
git rev-parse HEADmatches the source commit cited in this article. - Use the maintainer-provided Python interpreter with the backend folder on its module search path. Run the following from that root; replace
pythonwith that environment’s executable if necessary.
PYTHONPATH=backend python - <<'PYCODE'
import math
from app.v1170 import PhysicalQuantityRequest, execute_quantity
def run(payload):
return execute_quantity(PhysicalQuantityRequest(**payload))
speed = run({"operation": "convert", "expression": "36 kilometer / hour",
"targetUnit": "meter / second"})
force = run({"operation": "multiply",
"left": {"magnitude": 2, "unit": "kilogram"},
"right": {"magnitude": 3, "unit": "meter / second ** 2"}})
dimensions = run({"operation": "dimensionality", "expression": "6 newton"})
assert math.isclose(speed["result"]["magnitude"], 10.0, abs_tol=1e-12, rel_tol=0)
assert force["result"]["baseUnits"]["magnitude"] == 6.0
assert dimensions["result"]["dimensionality"] == {
"[mass]": 1.0, "[length]": 1.0, "[time]": -2.0}
print(speed["result"]["text"])
print(force["result"]["baseUnits"])
print(dimensions["result"]["dimensionality"])
print("Result fingerprint:", force["resultHash"])
PYCODE
- Expect speed
10.0 meter / second, force base magnitude6.0with unitkilogram * meter / second ** 2or the equivalent Pint-normalized spelling, and the dimension map above. Compare numerical values and exponents rather than relying on typography. - Independently calculate 36 × 1,000 / 3,600 = 10 and 2 × 3 = 6. Record that speed and force are separate examples; the speed was not used to obtain acceleration.
- Save the requests, complete JSON responses, units, source commit, resolved environment and tolerances. The printed fingerprint identifies the result payload in this environment; it is not proof of an experiment’s truth or guaranteed stable across software versions.
Optional route form: locally checked contract
The actual inspected route is POST /calculation-engine/v1/quantities; it accepts the same JSON payloads used above. It was tested through a minimal local FastAPI app containing the real v1170.router. That fixture excludes full-app middleware and authentication. Before using HTTP on an installed service, an administrator must verify its base URL, release, authentication and error handling. No live service URL or UI menu is certified here.
Common mistakes and interpretation
Use ** for powers in expressions, as in second ** 2; supply a magnitude and unit for both operands. add converts compatible quantities to the left operand’s units: 1 meter + 50 centimeters gives 1.5 meters. Do not add meters to seconds. A successful result is a software check under a constant-mass classical model; uncertainty in measured mass or acceleration requires a separate analysis. Consult troubleshooting when a required field, unit name or service dependency fails.
Evidence and related reading
Physical-quantity request models, operations, result serialization and routes; Existing quantity tests; Canonical source release identity.
Verification on 2026-11-10: 23 focused local assertions passed against the actual quantity router in a minimal FastAPI application. Six existing upstream test functions passed in that isolated router context; the status test failed because it expects 11.7.0 rather than the returned 14.0.0. The normal upstream suite could not collect because full app.main imports missing app.v10110. Static tests: three passed, two failed on old release/image expectations. These failures were recorded, not patched away. No deployed endpoint, UI, permission or scientific peer-review acceptance was performed.
Related: overview, worked how-to, research protocol, developer reference, troubleshooting. Technical/scientific review owner remains unassigned; publication remains blocked.
