Biomechanics
The human body as a serial manipulator — 7-DOF lower limb, 3D ground reaction force, gait cycle analysis — using the same NM19/28/29 operator set that drives the Robotics Lab, applied at body-scale.
- Live app — zeq.dev/apps/biomechanics/
- Source —
app/artifacts/api-server/public/apps/biomechanics/(1,725 lines) - Operators — KO42 · NM19 · NM28 · NM29
- Error budget — ≤ 0.1% on hip-joint moment for single-stance benchmark
What it solves
A clinical-grade biomechanics workbench. Three modes:
- Kinematics — 3D joint angles from marker trajectories; hip / knee / ankle via ISB conventions
- Inverse dynamics — net joint moments from GRF and kinematics; Newton-Euler top-down recursion
- Gait analysis — stride length, cadence, cycle timing, peak-force metrics; comparison against age-matched normative bands
The operator set is identical to Robotics Lab — biomechanics is manipulator analysis with soft constraints.
The math
NM19 F = m a (segment force balance)
NM28 L = r × p (segment angular momentum)
NM29 τ = r × F (joint moment)
Euler rotation θ_joint = R_distal · R_proximal^T (ISB convention)
Newton-Euler top-down τ_i = I_i α_i + ω_i × (I_i ω_i) − τ_{i-1} − ∑ F × r
Gait events heel-strike, toe-off, mid-stance from vertical GRF threshold
Operator picks
| Step | Decision |
|---|---|
| 1. Prime | KO42 on |
| 2. Limit | KO42 + NM19 + NM28 + NM29 = 4 operators (at limit) |
| 3. Scale | Human-scale rigid-body |
| 4. Precision | ≤ 0.1% on joint moments |
| 5. Compile | C_KO42 + C_NM19 + C_NM28 + C_NM29 |
| 6. Execute | Z encodes segment masses, inertias, joint centres |
| 7. Verify | Hip moment in single-limb stance vs. textbook |
Runnable worked example — single-limb stance hip moment
70 kg subject, mid-stance, external hip moment arm 7 cm, body weight fraction above pelvis 62%. Textbook abductor moment ≈ 0.62 · 686 N · 0.07 m ≈ 29.8 N·m.
curl -s -X POST https://api.zeq.dev/api/playground/compute \
-H "Content-Type: application/json" \
-H "x-demo-key: $DEMO_KEY" \
-d '{
"operators": ["KO42","NM19","NM28","NM29"],
"params": {
"problem": "single_limb_stance_hip_moment",
"body_mass_kg": 70,
"mass_fraction_above_pelvis": 0.62,
"moment_arm_m": 0.07
}
}' | jq
Expected:
{
"result": {
"hip_abductor_moment_Nm": 29.82,
"error_vs_reference_pct": 0.067,
"bw_x_height_ratio": 0.031,
"operators_used": ["KO42","NM19","NM28","NM29"]
}
}
0.067% on a published clinical benchmark.
Extend it
- EMG-driven muscle modelling — Hill-type muscle as NM30 spring-damper with activation dynamics; verify against isometric test rig
- 6-DOF knee with ligament constraints — replace hinge with 6-DOF + tension-only NM19 ligaments
- Marker-less pose from single RGB — substitute keypoint CNN output; propagate through the same inverse-dynamics pipeline
Seeds
- Real-time orthotics tuning via wearable IMU + on-device inverse dynamics at 1.287 Hz
- Post-stroke gait rehab with dense normative-band feedback
- Occupational ergonomics — industrial lift-analysis that compiles Master Equation in under 50 ms
Papers
- Zeq Paper — doi:10.5281/zenodo.18158152
Middleware active. Kernel on the 1.287 Hz HulyaPulse. Awaiting next Zeqond.