단위·차원 검사
check_unitsVerify the dimensions of physics or engineering formulas and convert values between units, including compound units, while flagging mismatched dimensions and returning numeric results.
Instructions
Check the units (dimensions) of a physics/engineering formula, or convert a value. Check: {"expr": "sqrt(2*h/g)", "units": {"h": "m", "g": "m/s^2"}, "expect": "s"} → matches; otherwise explanation says which dimensions differ. Units with values ("20 m") also give the numeric result. Convert: {"value": "72 km/h", "to": "m/s"} Use unit symbols (m, kg, N, J, km/h, m/s^2; dimensionless "1"). On failure: errors name the bad input; fix it and call again.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | No | Target unit (empty = SI) | |
| expr | No | Formula, sympy syntax | |
| units | No | Unit per variable, optionally with value | |
| value | No | Value to convert, e.g. "72 km/h" | |
| expect | No | Expected unit |