{
 "format": "robotparts-models/1",
 "definitions": [
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "coulomb_viscous",
   "rung": 2,
   "name": "M2.coulomb_viscous",
   "family": "fitted constant friction",
   "title": "Coulomb and viscous friction",
   "description": "Coulomb + viscous",
   "summary": "Constant (Coulomb) plus viscous friction at the output, fitted from measurements: MuJoCo's frictionloss and damping, so its simulator is optional.",
   "equation": "tau_r = coulomb_friction*sign(v) + viscous_friction*v",
   "since": "robotparts/2.3",
   "v2_3_kind": "coulomb_viscous",
   "inputs": {
    "v": {
     "definition": "The output's angular speed.",
     "unit": "rad/s"
    }
   },
   "state": {},
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "coulomb_friction": {
     "required": true,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "viscous_friction": {
     "required": true,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "output_inertia": {
     "required": false,
     "key": true,
     "measured_by": "chirps (or the datasheet)"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "python": {
     "how": "reference",
     "implementation": "model.py",
     "implementation_sha256": "e20d6f415822572bb89f305344dce3efc659a9db2822a34300141afa5665b095",
     "engine": null,
     "note": "The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI."
    },
    "js": {
     "how": "reference",
     "implementation": "model.js",
     "implementation_sha256": "5b8131ce0acd3f0d844985fb888d0ef91d553342ea2980896901b010db0c1e00",
     "engine": null,
     "note": "The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12."
    },
    "mujoco": {
     "how": "native",
     "engine": "mujoco",
     "maps": {
      "armature": "output_inertia",
      "frictionloss": "coulomb_friction",
      "damping": "viscous_friction"
     },
     "settings": {
      "friction_solref": {
       "definition": "The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.",
       "value": "number-list",
       "length": 2
      },
      "friction_solimp": {
       "definition": "The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.",
       "value": "number-list",
       "length": 5,
       "bounds": {
        "min": 0,
        "min_exclusive": true
       }
      }
     },
     "note": "frictionloss sticks at rest as a constraint (set friction_solref hard, or it creeps); damping is the viscous term."
    }
   },
   "validity": {
    "dims": {
     "output_speed": {
      "definition": "|v|, the output speed the terms were fitted or checked across.",
      "unit": "rad/s"
     }
    },
    "assumptions": [
     "Friction does not depend on speed beyond the viscous slope, on load, on temperature or on how long the part rested."
    ]
   },
   "readme": "README.md",
   "sha256": "1638a61405f7e54835d809633a899c652749fdd773780301e5ae1abff634e0a8",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "529c2bf1f968b67adf5806a6a49d9a192dfdeb36b1d805f99a04e02d18af6530",
     "url": "https://robotparts.dev/v2/models/actuator/coulomb_viscous/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/529c2bf1f968b67adf5806a6a49d9a192dfdeb36b1d805f99a04e02d18af6530.md",
     "bytes": 3497
    },
    "model.js": {
     "sha256": "5b8131ce0acd3f0d844985fb888d0ef91d553342ea2980896901b010db0c1e00",
     "url": "https://robotparts.dev/v2/models/actuator/coulomb_viscous/model.js",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/5b8131ce0acd3f0d844985fb888d0ef91d553342ea2980896901b010db0c1e00.js",
     "bytes": 651
    },
    "model.json": {
     "sha256": "1638a61405f7e54835d809633a899c652749fdd773780301e5ae1abff634e0a8",
     "url": "https://robotparts.dev/v2/models/actuator/coulomb_viscous/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/1638a61405f7e54835d809633a899c652749fdd773780301e5ae1abff634e0a8.json",
     "bytes": 3585
    },
    "model.py": {
     "sha256": "e20d6f415822572bb89f305344dce3efc659a9db2822a34300141afa5665b095",
     "url": "https://robotparts.dev/v2/models/actuator/coulomb_viscous/model.py",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/e20d6f415822572bb89f305344dce3efc659a9db2822a34300141afa5665b095.py",
     "bytes": 1124
    }
   },
   "units": {
    "coulomb_friction": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "viscous_friction": {
     "N·m·s/rad": 1,
     "mN·m·s/rad": 0.001
    },
    "output_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    }
   },
   "units_by_sha256": {
    "1638a61405f7e54835d809633a899c652749fdd773780301e5ae1abff634e0a8": {
     "coulomb_friction": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "viscous_friction": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "output_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     }
    }
   },
   "readme_markdown": "# M2.coulomb_viscous — Coulomb and viscous friction\n\n**Coulomb + viscous.** Family: fitted constant friction. Rung: 2, fitted constant friction. Category: actuator.\n\nConstant (Coulomb) friction that flips with direction, plus a viscous drag that grows with speed. MuJoCo expresses both natively (frictionloss and damping), so it runs anywhere with no plugin. On the rack it is the first fitted rung, and the backend matters more than the terms: MuJoCo's default friction constraint creeps below about 0.4 rad/s on a light hinge, and a hard solreffriction fixes it.\n\n**When to use it.** Use it as the first fitted model; measure it with velocity plateaus in both directions.\n\n## Equation\n\n```\ntau_r = coulomb_friction*sign(v) + viscous_friction*v\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `coulomb_friction` | yes | N·m | N·m, mN·m | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `viscous_friction` | yes | N·m·s/rad | N·m·s/rad, mN·m·s/rad | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `output_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | chirps (or the datasheet) |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- none\n\n## Inputs and state\n\n- input `v` (rad/s): The output's angular speed.\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| python | reference | — | `model.py` (sha256 `e20d6f415822…`). The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI. |\n| js | reference | — | `model.js` (sha256 `5b8131ce0acd…`). The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12. |\n| mujoco | native | mujoco, release named by the fit | frictionloss sticks at rest as a constraint (set friction_solref hard, or it creeps); damping is the viscous term. Maps: armature = `output_inertia`, frictionloss = `coulomb_friction`, damping = `viscous_friction`. |\n\n**mujoco settings** a fit may state:\n\n- `friction_solref`: 2 numbers. The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.\n- `friction_solimp`: 5 numbers, in (0, inf). The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.\n\n## Validity\n\n- A fit states the range of `output_speed` (rad/s) it holds across: |v|, the output speed the terms were fitted or checked across.\n- Friction does not depend on speed beyond the viscous slope, on load, on temperature or on how long the part rested.\n\n## Use it\n\n```python\nimport importlib.util\nspec = importlib.util.spec_from_file_location(\"coulomb_viscous\", \"model.py\")\nmodel = importlib.util.module_from_spec(spec); spec.loader.exec_module(model)\nterms = {...}  # a fit's terms in SI (robotparts.models.si_terms(fit, definition) converts them)\ntau_r, state = model.torque(terms, {\"v\": 0.0}, None, 0.001)\n```\n\nDefined since robotparts/2.3. It is robotparts/2.3's `coulomb_viscous` kind. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/coulomb_viscous/"
  },
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "datasheet",
   "rung": 1,
   "name": "M1.datasheet",
   "family": "datasheet",
   "title": "The datasheet",
   "description": "the stated values",
   "summary": "The datasheet's own model: the part's stated values and nothing fitted. Every term is a registry key and equals the part's spec in SI (relative tolerance 1e-6), and fitted_from is []. MJCF joint attributes express it (armature, frictionloss, damping), so its simulator is optional.",
   "equation": "tau_r = coulomb_friction*sign(v) + viscous_friction*v; armature = output_inertia, or gear_ratio^2*(rotor_inertia + gearbox_input_inertia)",
   "since": "robotparts/2.3",
   "v2_3_kind": "datasheet",
   "inputs": {
    "v": {
     "definition": "The output's angular speed.",
     "unit": "rad/s"
    }
   },
   "state": {},
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "output_inertia": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    },
    "rotor_inertia": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    },
    "gearbox_input_inertia": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    },
    "gear_ratio": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    },
    "kt": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    },
    "coulomb_friction": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    },
    "viscous_friction": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "python": {
     "how": "reference",
     "implementation": "model.py",
     "implementation_sha256": "3ed5e7d8d90d98efec0af84957f271ca20f365c62f660739be25b8ccad1ec2dc",
     "engine": null,
     "note": "The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI."
    },
    "js": {
     "how": "reference",
     "implementation": "model.js",
     "implementation_sha256": "bb054894e901a1d6464545efbbe0e81975c5be4cd8463eac105c01985e64c41e",
     "engine": null,
     "note": "The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12."
    },
    "mujoco": {
     "how": "native",
     "engine": "mujoco",
     "maps": {
      "armature": "output_inertia",
      "frictionloss": "coulomb_friction",
      "damping": "viscous_friction"
     },
     "derived": {
      "armature": {
       "if_absent": "output_inertia",
       "ratio_squared": "gear_ratio",
       "sum": [
        "rotor_inertia",
        "gearbox_input_inertia"
       ],
       "requires": [
        "gear_ratio",
        "rotor_inertia",
        "gearbox_input_inertia"
       ],
       "zero_when_drivetrain": {
        "gearbox_input_inertia": [
         "direct_drive",
         "motor"
        ]
       }
      }
     },
     "settings": {
      "friction_solref": {
       "definition": "The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.",
       "value": "number-list",
       "length": 2
      },
      "friction_solimp": {
       "definition": "The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.",
       "value": "number-list",
       "length": 5,
       "bounds": {
        "min": 0,
        "min_exclusive": true
       }
      }
     },
     "note": "The joint's armature, frictionloss and damping; a model stating rotor and gearbox inertia instead gives armature = gear_ratio^2 (rotor_inertia + gearbox_input_inertia)."
    }
   },
   "validity": {
    "dims": {},
    "assumptions": [
     "Every value is the maker's, as stated: the model is only as good as the datasheet."
    ]
   },
   "readme": "README.md",
   "sha256": "03b234a7f22220cd1eae425edca3af6d9ea19ab41a8af812fc91a9fdaeb74e6c",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "41119901a62f3d35bd1affa6052505141bcb4d37418896ca7f3249a16297c2b3",
     "url": "https://robotparts.dev/v2/models/actuator/datasheet/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/41119901a62f3d35bd1affa6052505141bcb4d37418896ca7f3249a16297c2b3.md",
     "bytes": 3835
    },
    "model.js": {
     "sha256": "bb054894e901a1d6464545efbbe0e81975c5be4cd8463eac105c01985e64c41e",
     "url": "https://robotparts.dev/v2/models/actuator/datasheet/model.js",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/bb054894e901a1d6464545efbbe0e81975c5be4cd8463eac105c01985e64c41e.js",
     "bytes": 655
    },
    "model.json": {
     "sha256": "03b234a7f22220cd1eae425edca3af6d9ea19ab41a8af812fc91a9fdaeb74e6c",
     "url": "https://robotparts.dev/v2/models/actuator/datasheet/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/03b234a7f22220cd1eae425edca3af6d9ea19ab41a8af812fc91a9fdaeb74e6c.json",
     "bytes": 4506
    },
    "model.py": {
     "sha256": "3ed5e7d8d90d98efec0af84957f271ca20f365c62f660739be25b8ccad1ec2dc",
     "url": "https://robotparts.dev/v2/models/actuator/datasheet/model.py",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/3ed5e7d8d90d98efec0af84957f271ca20f365c62f660739be25b8ccad1ec2dc.py",
     "bytes": 1130
    }
   },
   "units": {
    "output_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    },
    "rotor_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    },
    "gearbox_input_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    },
    "gear_ratio": {
     ":1": 1,
     "": 1
    },
    "kt": {
     "N·m/A": 1,
     "mN·m/A": 0.001
    },
    "coulomb_friction": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "viscous_friction": {
     "N·m·s/rad": 1,
     "mN·m·s/rad": 0.001
    }
   },
   "units_by_sha256": {
    "03b234a7f22220cd1eae425edca3af6d9ea19ab41a8af812fc91a9fdaeb74e6c": {
     "output_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     },
     "rotor_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     },
     "gearbox_input_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     },
     "gear_ratio": {
      ":1": 1,
      "": 1
     },
     "kt": {
      "N·m/A": 1,
      "mN·m/A": 0.001
     },
     "coulomb_friction": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "viscous_friction": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     }
    }
   },
   "readme_markdown": "# M1.datasheet — The datasheet\n\n**the stated values.** Family: datasheet. Rung: 1, the datasheet. Category: actuator.\n\nThe datasheet model holds what the maker states and nothing fitted: inertia, ratio, torque constant, and friction only if the datasheet gives it. The build checks every term against the part's own specs, so a model called datasheet can never carry a fitted number.\n\n**When to use it.** Use it before anything is measured, and as the honest answer to \"what does the maker claim?\".\n\n## Equation\n\n```\ntau_r = coulomb_friction*sign(v) + viscous_friction*v; armature = output_inertia, or gear_ratio^2*(rotor_inertia + gearbox_input_inertia)\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `output_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | reading the datasheet |\n| `rotor_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | reading the datasheet |\n| `gearbox_input_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | reading the datasheet |\n| `gear_ratio` | no | 1 | :1, 1 | reading the datasheet |\n| `kt` | no | N·m/A | N·m/A, mN·m/A | reading the datasheet |\n| `coulomb_friction` | no | N·m | N·m, mN·m | reading the datasheet |\n| `viscous_friction` | no | N·m·s/rad | N·m·s/rad, mN·m·s/rad | reading the datasheet |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- none\n\n## Inputs and state\n\n- input `v` (rad/s): The output's angular speed.\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| python | reference | — | `model.py` (sha256 `3ed5e7d8d90d…`). The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI. |\n| js | reference | — | `model.js` (sha256 `bb054894e901…`). The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12. |\n| mujoco | native | mujoco, release named by the fit | The joint's armature, frictionloss and damping; a model stating rotor and gearbox inertia instead gives armature = gear_ratio^2 (rotor_inertia + gearbox_input_inertia). Maps: armature = `output_inertia`, frictionloss = `coulomb_friction`, damping = `viscous_friction`. Without `output_inertia`, armature = `gear_ratio`² × (`rotor_inertia` + `gearbox_input_inertia`), every one of `gear_ratio`, `rotor_inertia`, `gearbox_input_inertia` stated; `gearbox_input_inertia` counts as 0 only on drivetrain direct_drive or motor. |\n\n**mujoco settings** a fit may state:\n\n- `friction_solref`: 2 numbers. The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.\n- `friction_solimp`: 5 numbers, in (0, inf). The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.\n\n## Validity\n\n- A stated model is fitted from nothing, so it has no fitted range.\n- Every value is the maker's, as stated: the model is only as good as the datasheet.\n\n## Use it\n\n```python\nimport importlib.util\nspec = importlib.util.spec_from_file_location(\"datasheet\", \"model.py\")\nmodel = importlib.util.module_from_spec(spec); spec.loader.exec_module(model)\nterms = {...}  # a fit's terms in SI (robotparts.models.si_terms(fit, definition) converts them)\ntau_r, state = model.torque(terms, {\"v\": 0.0}, None, 0.001)\n```\n\nDefined since robotparts/2.3. It is robotparts/2.3's `datasheet` kind. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/datasheet/"
  },
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "dcmotor",
   "rung": 5,
   "name": "M5.dcmotor",
   "family": "motor electrics",
   "title": "MuJoCo's DC motor",
   "description": "DC motor electrics + heat + cogging + LuGre",
   "summary": "MuJoCo's DC motor actuator (the dcmotor shortcut, mjs_setToDCMotor, MuJoCo 3.16): electrical dynamics, gain and bias (back-EMF, cogging, LuGre friction), with its parameters named and shaped as MuJoCo takes them. The simulator pins the MuJoCo release and the code that sets them.",
   "equation": "MuJoCo's own: mjDYN_DCMOTOR (electrical dynamics), mjGAIN_DCMOTOR (K or K/R), mjBIAS_DCMOTOR (back-EMF, cogging, LuGre friction)",
   "since": "robotparts/2.3",
   "v2_3_kind": "mujoco_dcmotor",
   "inputs": {},
   "state": {},
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "motorconst": {
     "required": true,
     "definition": "MuJoCo dcmotor's motorconst (2 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 2,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "resistance": {
     "required": true,
     "definition": "MuJoCo dcmotor's resistance, the winding resistance the electrical model uses, as mjs_setToDCMotor takes it.",
     "value": "number",
     "si_unit": "Ω",
     "units": {
      "Ω": 1,
      "mΩ": 0.001
     },
     "positive": true,
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "nominal": {
     "required": false,
     "definition": "MuJoCo dcmotor's nominal (3 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 3,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "saturation": {
     "required": false,
     "definition": "MuJoCo dcmotor's saturation (3 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 3,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "inductance": {
     "required": false,
     "definition": "MuJoCo dcmotor's inductance (2 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 2,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "cogging": {
     "required": false,
     "definition": "MuJoCo dcmotor's cogging (3 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 3,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "controller": {
     "required": false,
     "definition": "MuJoCo dcmotor's controller (6 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 6,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "thermal": {
     "required": false,
     "definition": "MuJoCo dcmotor's thermal (6 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 6,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    },
    "lugre": {
     "required": false,
     "definition": "MuJoCo dcmotor's lugre (5 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.",
     "value": "number-list",
     "length": 5,
     "si_unit": null,
     "units": {
      "mujoco": null
     },
     "measured_by": "measure-only board calibration, then the envelope ladder"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "mujoco": {
     "how": "native",
     "engine": "mujoco",
     "engine_min": "3.16.0",
     "maps": {
      "motorconst": "motorconst",
      "resistance": "resistance",
      "nominal": "nominal",
      "saturation": "saturation",
      "inductance": "inductance",
      "cogging": "cogging",
      "controller": "controller",
      "thermal": "thermal",
      "lugre": "lugre"
     },
     "note": "MuJoCo 3.16's dcmotor actuator (mjs_setToDCMotor) takes the terms as they are; no other backend implements it."
    }
   },
   "validity": {
    "dims": {
     "output_speed": {
      "definition": "|v|, the output speed the terms were fitted or checked across.",
      "unit": "rad/s"
     },
     "current": {
      "definition": "|i|, the winding current the electrics were fitted across.",
      "unit": "A"
     }
    },
    "assumptions": [
     "MuJoCo's own DC motor equations, as its release documents them."
    ]
   },
   "readme": "README.md",
   "sha256": "cfae50f856db6518519ecc18817b5745361a3b0368b8586641096f4668405931",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "aabc9ebce725dcfb2b3ee41c16e01e32e85d43ea7c41c09cb212ed72949709f7",
     "url": "https://robotparts.dev/v2/models/actuator/dcmotor/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/aabc9ebce725dcfb2b3ee41c16e01e32e85d43ea7c41c09cb212ed72949709f7.md",
     "bytes": 4891
    },
    "model.json": {
     "sha256": "cfae50f856db6518519ecc18817b5745361a3b0368b8586641096f4668405931",
     "url": "https://robotparts.dev/v2/models/actuator/dcmotor/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/cfae50f856db6518519ecc18817b5745361a3b0368b8586641096f4668405931.json",
     "bytes": 5797
    }
   },
   "units": {
    "motorconst": {
     "mujoco": null
    },
    "resistance": {
     "Ω": 1,
     "mΩ": 0.001
    },
    "nominal": {
     "mujoco": null
    },
    "saturation": {
     "mujoco": null
    },
    "inductance": {
     "mujoco": null
    },
    "cogging": {
     "mujoco": null
    },
    "controller": {
     "mujoco": null
    },
    "thermal": {
     "mujoco": null
    },
    "lugre": {
     "mujoco": null
    }
   },
   "units_by_sha256": {
    "cfae50f856db6518519ecc18817b5745361a3b0368b8586641096f4668405931": {
     "motorconst": {
      "mujoco": null
     },
     "resistance": {
      "Ω": 1,
      "mΩ": 0.001
     },
     "nominal": {
      "mujoco": null
     },
     "saturation": {
      "mujoco": null
     },
     "inductance": {
      "mujoco": null
     },
     "cogging": {
      "mujoco": null
     },
     "controller": {
      "mujoco": null
     },
     "thermal": {
      "mujoco": null
     },
     "lugre": {
      "mujoco": null
     }
    }
   },
   "readme_markdown": "# M5.dcmotor — MuJoCo's DC motor\n\n**DC motor electrics + heat + cogging + LuGre.** Family: motor electrics. Rung: 5, the motor's electrics and heat. Category: actuator.\n\nMuJoCo's own DC motor actuator (3.16): the winding's electrical dynamics, the motor constant, heat, cogging and LuGre friction, with every parameter named and shaped as MuJoCo takes it. Only MuJoCo implements it.\n\n**When to use it.** Use it when current, voltage and heat limits matter: fast moves, long duty, a drive near its ceiling.\n\n## Equation\n\n```\nMuJoCo's own: mjDYN_DCMOTOR (electrical dynamics), mjGAIN_DCMOTOR (K or K/R), mjBIAS_DCMOTOR (back-EMF, cogging, LuGre friction)\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `motorconst` | yes | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n| `resistance` | yes | Ω | Ω, mΩ | measure-only board calibration, then the envelope ladder |\n| `nominal` | no | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n| `saturation` | no | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n| `inductance` | no | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n| `cogging` | no | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n| `controller` | no | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n| `thermal` | no | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n| `lugre` | no | engine-defined (the engine's own SI unit for each component) | `mujoco` (engine-defined) | measure-only board calibration, then the envelope ladder |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- `motorconst`: MuJoCo dcmotor's motorconst (2 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n- `resistance`: MuJoCo dcmotor's resistance, the winding resistance the electrical model uses, as mjs_setToDCMotor takes it.\n- `nominal`: MuJoCo dcmotor's nominal (3 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n- `saturation`: MuJoCo dcmotor's saturation (3 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n- `inductance`: MuJoCo dcmotor's inductance (2 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n- `cogging`: MuJoCo dcmotor's cogging (3 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n- `controller`: MuJoCo dcmotor's controller (6 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n- `thermal`: MuJoCo dcmotor's thermal (6 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n- `lugre`: MuJoCo dcmotor's lugre (5 numbers), as mjs_setToDCMotor takes it; unit mujoco means MuJoCo's own (SI) units for each entry.\n\n## Inputs and state\n\n- no per-step inputs\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| mujoco | native | mujoco ≥ 3.16.0, release named by the fit | MuJoCo 3.16's dcmotor actuator (mjs_setToDCMotor) takes the terms as they are; no other backend implements it. Maps: motorconst = `motorconst`, resistance = `resistance`, nominal = `nominal`, saturation = `saturation`, inductance = `inductance`, cogging = `cogging`, controller = `controller`, thermal = `thermal`, lugre = `lugre`. |\n\n## Validity\n\n- A fit states the range of `output_speed` (rad/s) it holds across: |v|, the output speed the terms were fitted or checked across.\n- A fit states the range of `current` (A) it holds across: |i|, the winding current the electrics were fitted across.\n- MuJoCo's own DC motor equations, as its release documents them.\n\n## Use it\n\nOnly MuJoCo implements this model: a fit's terms go into the dcmotor actuator as the backend's maps say.\n\nDefined since robotparts/2.3. It is robotparts/2.3's `mujoco_dcmotor` kind. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/dcmotor/"
  },
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "ideal",
   "rung": 0,
   "name": "M0.ideal",
   "family": "ideal",
   "title": "The ideal actuator",
   "description": "no losses",
   "summary": "The ablation baseline every rung is measured from: the stated inertia and ratio, no friction, no ripple.",
   "equation": "tau_r = 0; armature = output_inertia",
   "since": "robotparts/2.5",
   "v2_3_kind": null,
   "inputs": {
    "v": {
     "definition": "The output's angular speed.",
     "unit": "rad/s"
    }
   },
   "state": {},
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "output_inertia": {
     "required": true,
     "key": true,
     "measured_by": "chirps (or the datasheet)"
    },
    "gear_ratio": {
     "required": false,
     "key": true,
     "measured_by": "reading the datasheet"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "python": {
     "how": "reference",
     "implementation": "model.py",
     "implementation_sha256": "ba6b33a4cbd28aea7cb1874e6e646e9f5dd34c67a33290cb489296aeda0d4b76",
     "engine": null,
     "note": "The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI."
    },
    "js": {
     "how": "reference",
     "implementation": "model.js",
     "implementation_sha256": "533668d33e34e67d5e6d1dcc04fdf3f3f9d1b5d7d409f7f67c264d808a28e805",
     "engine": null,
     "note": "The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12."
    },
    "mujoco": {
     "how": "native",
     "engine": "mujoco",
     "maps": {
      "armature": "output_inertia"
     },
     "settings": {
      "friction_solref": {
       "definition": "The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.",
       "value": "number-list",
       "length": 2
      },
      "friction_solimp": {
       "definition": "The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.",
       "value": "number-list",
       "length": 5,
       "bounds": {
        "min": 0,
        "min_exclusive": true
       }
      }
     },
     "note": "MuJoCo expresses it as the joint's armature; nothing runs per step."
    }
   },
   "validity": {
    "dims": {},
    "assumptions": [
     "No losses of any kind: the model is a baseline, never a prediction of a real part."
    ]
   },
   "readme": "README.md",
   "sha256": "4bcee8de7d6f1390d9492115e05026d8a5d67f3734120ccc3de0b95d25fc82e2",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "23e453d4989df9f01d788714026655079ed4284c02a4683e204581815ecb7103",
     "url": "https://robotparts.dev/v2/models/actuator/ideal/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/23e453d4989df9f01d788714026655079ed4284c02a4683e204581815ecb7103.md",
     "bytes": 2836
    },
    "model.js": {
     "sha256": "533668d33e34e67d5e6d1dcc04fdf3f3f9d1b5d7d409f7f67c264d808a28e805",
     "url": "https://robotparts.dev/v2/models/actuator/ideal/model.js",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/533668d33e34e67d5e6d1dcc04fdf3f3f9d1b5d7d409f7f67c264d808a28e805.js",
     "bytes": 313
    },
    "model.json": {
     "sha256": "4bcee8de7d6f1390d9492115e05026d8a5d67f3734120ccc3de0b95d25fc82e2",
     "url": "https://robotparts.dev/v2/models/actuator/ideal/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/4bcee8de7d6f1390d9492115e05026d8a5d67f3734120ccc3de0b95d25fc82e2.json",
     "bytes": 2907
    },
    "model.py": {
     "sha256": "ba6b33a4cbd28aea7cb1874e6e646e9f5dd34c67a33290cb489296aeda0d4b76",
     "url": "https://robotparts.dev/v2/models/actuator/ideal/model.py",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/ba6b33a4cbd28aea7cb1874e6e646e9f5dd34c67a33290cb489296aeda0d4b76.py",
     "bytes": 701
    }
   },
   "units": {
    "output_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    },
    "gear_ratio": {
     ":1": 1,
     "": 1
    }
   },
   "units_by_sha256": {
    "4bcee8de7d6f1390d9492115e05026d8a5d67f3734120ccc3de0b95d25fc82e2": {
     "output_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     },
     "gear_ratio": {
      ":1": 1,
      "": 1
     }
    }
   },
   "readme_markdown": "# M0.ideal — The ideal actuator\n\n**no losses.** Family: ideal. Rung: 0, the ideal part. Category: actuator.\n\nThe ideal actuator is the zero every other model is measured from: the part's inertia and ratio, and no losses at all. Nobody should simulate a real robot with it. Its job is the ablation baseline: a rung's gain is how much better it tracks the real part than M0 does on the same runs.\n\n**When to use it.** Use it as the first row of every ladder, and to see how much of a twin's error is friction at all.\n\n## Equation\n\n```\ntau_r = 0; armature = output_inertia\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `output_inertia` | yes | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | chirps (or the datasheet) |\n| `gear_ratio` | no | 1 | :1, 1 | reading the datasheet |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- none\n\n## Inputs and state\n\n- input `v` (rad/s): The output's angular speed.\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| python | reference | — | `model.py` (sha256 `ba6b33a4cbd2…`). The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI. |\n| js | reference | — | `model.js` (sha256 `533668d33e34…`). The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12. |\n| mujoco | native | mujoco, release named by the fit | MuJoCo expresses it as the joint's armature; nothing runs per step. Maps: armature = `output_inertia`. |\n\n**mujoco settings** a fit may state:\n\n- `friction_solref`: 2 numbers. The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.\n- `friction_solimp`: 5 numbers, in (0, inf). The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.\n\n## Validity\n\n- A stated model is fitted from nothing, so it has no fitted range.\n- No losses of any kind: the model is a baseline, never a prediction of a real part.\n\n## Use it\n\n```python\nimport importlib.util\nspec = importlib.util.spec_from_file_location(\"ideal\", \"model.py\")\nmodel = importlib.util.module_from_spec(spec); spec.loader.exec_module(model)\nterms = {...}  # a fit's terms in SI (robotparts.models.si_terms(fit, definition) converts them)\ntau_r, state = model.torque(terms, {\"v\": 0.0}, None, 0.001)\n```\n\nDefined since robotparts/2.5. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/ideal/"
  },
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "load",
   "rung": 3,
   "name": "M3.load",
   "family": "static friction",
   "title": "Load-dependent friction",
   "description": "Coulomb + viscous + load",
   "summary": "Coulomb friction that grows with the load torque the part transmits (gear mesh friction), plus viscous friction.",
   "equation": "tau_r = (coulomb_friction + friction_load_coefficient*|tau_load|)*sign(v) + viscous_friction*v, tau_load the output load torque",
   "since": "robotparts/2.3",
   "v2_3_kind": "load_dependent",
   "inputs": {
    "v": {
     "definition": "The output's angular speed.",
     "unit": "rad/s"
    },
    "tau_load": {
     "definition": "The load torque the part transmits at the output (what it carries besides its own friction).",
     "unit": "N·m"
    }
   },
   "state": {},
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "coulomb_friction": {
     "required": true,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "viscous_friction": {
     "required": true,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "friction_load_coefficient": {
     "required": true,
     "key": true,
     "measured_by": "pendulum sweeps with 2-3 masses"
    },
    "output_inertia": {
     "required": false,
     "key": true,
     "measured_by": "chirps (or the datasheet)"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "python": {
     "how": "reference",
     "implementation": "model.py",
     "implementation_sha256": "03b5cb124ad4a66bffa3298b4fccf831f17c33c147d15c43d99ef44920587033",
     "engine": null,
     "note": "The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI."
    },
    "js": {
     "how": "reference",
     "implementation": "model.js",
     "implementation_sha256": "d50eb2222039019497aa11972aca5479a7517a429ef2b99c28cd8655c9b3a0d0",
     "engine": null,
     "note": "The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12."
    },
    "mujoco": {
     "how": "plugin",
     "implementation": "robotparts.mujoco",
     "engine": "mujoco",
     "maps": {
      "armature": "output_inertia",
      "frictionloss": "coulomb_friction",
      "damping": "viscous_friction"
     },
     "settings": {
      "friction_solref": {
       "definition": "The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.",
       "value": "number-list",
       "length": 2
      },
      "friction_solimp": {
       "definition": "The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.",
       "value": "number-list",
       "length": 5,
       "bounds": {
        "min": 0,
        "min_exclusive": true
       }
      }
     },
     "note": "The unloaded level sticks natively; the plugin raises the joint's frictionloss each step by friction_load_coefficient * |tau_load|."
    }
   },
   "validity": {
    "dims": {
     "output_speed": {
      "definition": "|v|, the output speed the terms were fitted or checked across.",
      "unit": "rad/s"
     },
     "load_torque": {
      "definition": "|tau_load|, the load the friction-load coefficient was fitted across.",
      "unit": "N·m"
     }
    },
    "assumptions": [
     "Friction grows linearly with the load the gear mesh carries, the same in both directions.",
     "Valid across the loads it was fitted on."
    ]
   },
   "readme": "README.md",
   "sha256": "fc915dd8f01476838ebb081de75b37b12b3ed2e002abbc0754789a8396f6d157",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "261bf3e5975117bb9b0dbff795183092848149697f63b9e580f4d2df2df7db0a",
     "url": "https://robotparts.dev/v2/models/actuator/load/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/261bf3e5975117bb9b0dbff795183092848149697f63b9e580f4d2df2df7db0a.md",
     "bytes": 3762
    },
    "model.js": {
     "sha256": "d50eb2222039019497aa11972aca5479a7517a429ef2b99c28cd8655c9b3a0d0",
     "url": "https://robotparts.dev/v2/models/actuator/load/model.js",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/d50eb2222039019497aa11972aca5479a7517a429ef2b99c28cd8655c9b3a0d0.js",
     "bytes": 789
    },
    "model.json": {
     "sha256": "fc915dd8f01476838ebb081de75b37b12b3ed2e002abbc0754789a8396f6d157",
     "url": "https://robotparts.dev/v2/models/actuator/load/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/fc915dd8f01476838ebb081de75b37b12b3ed2e002abbc0754789a8396f6d157.json",
     "bytes": 4133
    },
    "model.py": {
     "sha256": "03b5cb124ad4a66bffa3298b4fccf831f17c33c147d15c43d99ef44920587033",
     "url": "https://robotparts.dev/v2/models/actuator/load/model.py",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/03b5cb124ad4a66bffa3298b4fccf831f17c33c147d15c43d99ef44920587033.py",
     "bytes": 1266
    }
   },
   "units": {
    "coulomb_friction": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "viscous_friction": {
     "N·m·s/rad": 1,
     "mN·m·s/rad": 0.001
    },
    "friction_load_coefficient": {
     "": 1
    },
    "output_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    }
   },
   "units_by_sha256": {
    "fc915dd8f01476838ebb081de75b37b12b3ed2e002abbc0754789a8396f6d157": {
     "coulomb_friction": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "viscous_friction": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "friction_load_coefficient": {
      "": 1
     },
     "output_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     }
    }
   },
   "readme_markdown": "# M3.load — Load-dependent friction\n\n**Coulomb + viscous + load.** Family: static friction. Rung: 3, friction that changes with state. Category: actuator.\n\nCoulomb friction that grows with the load the gearbox carries (gear-mesh friction), plus viscous drag. The plugin raises the joint's friction level each step from the load torque it reads.\n\n**When to use it.** Use it for geared joints that carry gravity or payload; measure it with pendulum sweeps at 2-3 masses.\n\n## Equation\n\n```\ntau_r = (coulomb_friction + friction_load_coefficient*|tau_load|)*sign(v) + viscous_friction*v, tau_load the output load torque\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `coulomb_friction` | yes | N·m | N·m, mN·m | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `viscous_friction` | yes | N·m·s/rad | N·m·s/rad, mN·m·s/rad | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `friction_load_coefficient` | yes | 1 | 1 | pendulum sweeps with 2-3 masses |\n| `output_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | chirps (or the datasheet) |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- none\n\n## Inputs and state\n\n- input `v` (rad/s): The output's angular speed.\n- input `tau_load` (N·m): The load torque the part transmits at the output (what it carries besides its own friction).\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| python | reference | — | `model.py` (sha256 `03b5cb124ad4…`). The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI. |\n| js | reference | — | `model.js` (sha256 `d50eb2222039…`). The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12. |\n| mujoco | plugin | mujoco, release named by the fit | `robotparts.mujoco`. The unloaded level sticks natively; the plugin raises the joint's frictionloss each step by friction_load_coefficient * |tau_load|. Maps: armature = `output_inertia`, frictionloss = `coulomb_friction`, damping = `viscous_friction`. |\n\n**mujoco settings** a fit may state:\n\n- `friction_solref`: 2 numbers. The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.\n- `friction_solimp`: 5 numbers, in (0, inf). The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.\n\n## Validity\n\n- A fit states the range of `output_speed` (rad/s) it holds across: |v|, the output speed the terms were fitted or checked across.\n- A fit states the range of `load_torque` (N·m) it holds across: |tau_load|, the load the friction-load coefficient was fitted across.\n- Friction grows linearly with the load the gear mesh carries, the same in both directions.\n- Valid across the loads it was fitted on.\n\n## Use it\n\n```python\nimport importlib.util\nspec = importlib.util.spec_from_file_location(\"load\", \"model.py\")\nmodel = importlib.util.module_from_spec(spec); spec.loader.exec_module(model)\nterms = {...}  # a fit's terms in SI (robotparts.models.si_terms(fit, definition) converts them)\ntau_r, state = model.torque(terms, {\"v\": 0.0, \"tau_load\": 0.0}, None, 0.001)\n```\n\nDefined since robotparts/2.3. It is robotparts/2.3's `load_dependent` kind. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/load/"
  },
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "lugre",
   "rung": 3,
   "name": "M3.lugre",
   "family": "dynamic friction",
   "title": "LuGre friction",
   "description": "Coulomb + viscous + Stribeck + bristle state",
   "summary": "The LuGre dynamic friction model (Canudas de Wit, Olsson, Astrom and Lischinsky, IEEE TAC 1995): bristles of deflection z give pre-sliding displacement, the Stribeck curve and frictional lag.",
   "equation": "dz/dt = v - sigma0*|v|*z/g(v), g(v) = coulomb_friction + (breakaway_torque - coulomb_friction)*exp(-(|v|/stribeck_velocity)^stribeck_exponent); tau_r = sigma0*z + sigma1*dz/dt + sigma2*v; stribeck_exponent is 2 when absent",
   "since": "robotparts/2.3",
   "v2_3_kind": "lugre",
   "inputs": {
    "v": {
     "definition": "The output's angular speed.",
     "unit": "rad/s"
    },
    "dt": {
     "definition": "The step the simulator advances by (a stateful model integrates its state over it).",
     "unit": "s"
    }
   },
   "state": {
    "z": {
     "definition": "The bristles' mean deflection.",
     "unit": "rad",
     "initial": 0.0
    }
   },
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "coulomb_friction": {
     "required": true,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "breakaway_torque": {
     "required": true,
     "key": true,
     "measured_by": "slow plateaus below 0.5 rad/s"
    },
    "stribeck_velocity": {
     "required": true,
     "key": true,
     "measured_by": "slow plateaus below 0.5 rad/s"
    },
    "sigma0": {
     "required": true,
     "definition": "LuGre bristle stiffness sigma0: output torque per radian of bristle deflection z.",
     "value": "number",
     "si_unit": "N·m/rad",
     "units": {
      "N·m/rad": 1
     },
     "positive": true,
     "measured_by": "small reversals, recorded fast"
    },
    "sigma1": {
     "required": true,
     "definition": "LuGre bristle (micro-)damping sigma1: output torque per rad/s of bristle deflection rate.",
     "value": "number",
     "si_unit": "N·m·s/rad",
     "units": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "nonnegative": true,
     "measured_by": "small reversals, recorded fast"
    },
    "sigma2": {
     "required": true,
     "definition": "LuGre viscous coefficient sigma2: output torque per rad/s of output speed (the other kinds' viscous_friction).",
     "value": "number",
     "si_unit": "N·m·s/rad",
     "units": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "nonnegative": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "stribeck_exponent": {
     "required": false,
     "definition": "Shape exponent d of the Stribeck curve in g(v); 2 when absent.",
     "value": "number",
     "si_unit": "",
     "units": {
      "": 1
     },
     "positive": true,
     "measured_by": "slow plateaus below 0.5 rad/s",
     "default": 2
    },
    "output_inertia": {
     "required": false,
     "key": true,
     "measured_by": "chirps (or the datasheet)"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "python": {
     "how": "reference",
     "implementation": "model.py",
     "implementation_sha256": "63cb93d20325eb8bfe76e7fa2899928c725eb5de354b45619830c7ef4d59cde0",
     "engine": null,
     "note": "The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI."
    },
    "js": {
     "how": "reference",
     "implementation": "model.js",
     "implementation_sha256": "e8e42ee33d8acfef3fa7be6542c68ee06c165ff1dc2f3dd67787424a0009cb0a",
     "engine": null,
     "note": "The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12."
    },
    "mujoco": {
     "how": "plugin",
     "implementation": "robotparts.mujoco",
     "engine": "mujoco",
     "maps": {
      "armature": "output_inertia"
     },
     "settings": {
      "friction_solref": {
       "definition": "The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.",
       "value": "number-list",
       "length": 2
      },
      "friction_solimp": {
       "definition": "The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.",
       "value": "number-list",
       "length": 5,
       "bounds": {
        "min": 0,
        "min_exclusive": true
       }
      }
     },
     "note": "No native part: the plugin integrates z each step with the simulator's dt (semi-implicit, stable for any dt) and applies the whole torque."
    }
   },
   "validity": {
    "dims": {
     "output_speed": {
      "definition": "|v|, the output speed the terms were fitted or checked across.",
      "unit": "rad/s"
     }
    },
    "assumptions": [
     "One bristle state for the whole drivetrain.",
     "Pre-sliding is fitted from small reversals; larger stiction effects outside their amplitude are extrapolated."
    ]
   },
   "readme": "README.md",
   "sha256": "560a2029e8846474a357466fbcb584451a81c3f99dd5507015e9a06914fd88aa",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "657e977e53358fbb5324deaf059284b85693baea1c0355904e695aadb77ce552",
     "url": "https://robotparts.dev/v2/models/actuator/lugre/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/657e977e53358fbb5324deaf059284b85693baea1c0355904e695aadb77ce552.md",
     "bytes": 4484
    },
    "model.js": {
     "sha256": "e8e42ee33d8acfef3fa7be6542c68ee06c165ff1dc2f3dd67787424a0009cb0a",
     "url": "https://robotparts.dev/v2/models/actuator/lugre/model.js",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/e8e42ee33d8acfef3fa7be6542c68ee06c165ff1dc2f3dd67787424a0009cb0a.js",
     "bytes": 910
    },
    "model.json": {
     "sha256": "560a2029e8846474a357466fbcb584451a81c3f99dd5507015e9a06914fd88aa",
     "url": "https://robotparts.dev/v2/models/actuator/lugre/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/560a2029e8846474a357466fbcb584451a81c3f99dd5507015e9a06914fd88aa.json",
     "bytes": 5637
    },
    "model.py": {
     "sha256": "63cb93d20325eb8bfe76e7fa2899928c725eb5de354b45619830c7ef4d59cde0",
     "url": "https://robotparts.dev/v2/models/actuator/lugre/model.py",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/63cb93d20325eb8bfe76e7fa2899928c725eb5de354b45619830c7ef4d59cde0.py",
     "bytes": 1398
    }
   },
   "units": {
    "coulomb_friction": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "breakaway_torque": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "stribeck_velocity": {
     "rad/s": 1,
     "rpm": 0.10471975511965977,
     "deg/s": 0.017453292519943295
    },
    "sigma0": {
     "N·m/rad": 1
    },
    "sigma1": {
     "N·m·s/rad": 1,
     "mN·m·s/rad": 0.001
    },
    "sigma2": {
     "N·m·s/rad": 1,
     "mN·m·s/rad": 0.001
    },
    "stribeck_exponent": {
     "": 1
    },
    "output_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    }
   },
   "units_by_sha256": {
    "560a2029e8846474a357466fbcb584451a81c3f99dd5507015e9a06914fd88aa": {
     "coulomb_friction": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "breakaway_torque": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "stribeck_velocity": {
      "rad/s": 1,
      "rpm": 0.10471975511965977,
      "deg/s": 0.017453292519943295
     },
     "sigma0": {
      "N·m/rad": 1
     },
     "sigma1": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "sigma2": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "stribeck_exponent": {
      "": 1
     },
     "output_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     }
    }
   },
   "readme_markdown": "# M3.lugre — LuGre friction\n\n**Coulomb + viscous + Stribeck + bristle state.** Family: dynamic friction. Rung: 3, friction that changes with state. Category: actuator.\n\nThe LuGre dynamic friction model: the contact behaves like bristles that deflect before they slide, which gives pre-sliding motion, the Stribeck curve and frictional lag from one state variable. It is stateful, so every backend integrates z each step.\n\n**When to use it.** Use it when small reversals and holding position matter more than the plateaus explain.\n\n## Equation\n\n```\ndz/dt = v - sigma0*|v|*z/g(v), g(v) = coulomb_friction + (breakaway_torque - coulomb_friction)*exp(-(|v|/stribeck_velocity)^stribeck_exponent); tau_r = sigma0*z + sigma1*dz/dt + sigma2*v; stribeck_exponent is 2 when absent\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `coulomb_friction` | yes | N·m | N·m, mN·m | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `breakaway_torque` | yes | N·m | N·m, mN·m | slow plateaus below 0.5 rad/s |\n| `stribeck_velocity` | yes | rad/s | rad/s, rpm, deg/s | slow plateaus below 0.5 rad/s |\n| `sigma0` | yes | N·m/rad | N·m/rad | small reversals, recorded fast |\n| `sigma1` | yes | N·m·s/rad | N·m·s/rad, mN·m·s/rad | small reversals, recorded fast |\n| `sigma2` | yes | N·m·s/rad | N·m·s/rad, mN·m·s/rad | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `stribeck_exponent` | no | 1 | 1 | slow plateaus below 0.5 rad/s |\n| `output_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | chirps (or the datasheet) |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- `sigma0`: LuGre bristle stiffness sigma0: output torque per radian of bristle deflection z.\n- `sigma1`: LuGre bristle (micro-)damping sigma1: output torque per rad/s of bristle deflection rate.\n- `sigma2`: LuGre viscous coefficient sigma2: output torque per rad/s of output speed (the other kinds' viscous_friction).\n- `stribeck_exponent`: Shape exponent d of the Stribeck curve in g(v); 2 when absent.\n\n## Inputs and state\n\n- input `v` (rad/s): The output's angular speed.\n- input `dt` (s): The step the simulator advances by (a stateful model integrates its state over it).\n- state `z` (rad, starts at 0): The bristles' mean deflection.\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| python | reference | — | `model.py` (sha256 `63cb93d20325…`). The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI. |\n| js | reference | — | `model.js` (sha256 `e8e42ee33d8a…`). The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12. |\n| mujoco | plugin | mujoco, release named by the fit | `robotparts.mujoco`. No native part: the plugin integrates z each step with the simulator's dt (semi-implicit, stable for any dt) and applies the whole torque. Maps: armature = `output_inertia`. |\n\n**mujoco settings** a fit may state:\n\n- `friction_solref`: 2 numbers. The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.\n- `friction_solimp`: 5 numbers, in (0, inf). The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.\n\n## Validity\n\n- A fit states the range of `output_speed` (rad/s) it holds across: |v|, the output speed the terms were fitted or checked across.\n- One bristle state for the whole drivetrain.\n- Pre-sliding is fitted from small reversals; larger stiction effects outside their amplitude are extrapolated.\n\n## Use it\n\n```python\nimport importlib.util\nspec = importlib.util.spec_from_file_location(\"lugre\", \"model.py\")\nmodel = importlib.util.module_from_spec(spec); spec.loader.exec_module(model)\nterms = {...}  # a fit's terms in SI (robotparts.models.si_terms(fit, definition) converts them)\ntau_r, state = model.torque(terms, {\"v\": 0.0}, None, 0.001)\n```\n\nDefined since robotparts/2.3. It is robotparts/2.3's `lugre` kind. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/lugre/"
  },
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "ripple",
   "rung": 4,
   "name": "M4.ripple",
   "family": "grey box",
   "title": "Rotor ripple map",
   "description": "Coulomb + viscous + rotor-keyed ripple",
   "summary": "Cogging and commutation ripple as rotor-periodic torque harmonics at the output (the torque_ripple records in one map), optionally with Coulomb and viscous friction.",
   "equation": "tau_r = sum_k amplitude_k*sin(rotor_harmonic_k*theta_rotor + phase_k), theta_rotor = gear_ratio*theta_output in rad from the rotor zero the simulator uses (tau_r adds coulomb_friction*sign(v) + viscous_friction*v when stated)",
   "since": "robotparts/2.3",
   "v2_3_kind": "ripple_map",
   "inputs": {
    "v": {
     "definition": "The output's angular speed.",
     "unit": "rad/s"
    },
    "theta_rotor": {
     "definition": "The rotor's angle, gear_ratio times the output angle from the rotor zero the simulator uses.",
     "unit": "rad"
    }
   },
   "state": {},
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "harmonics": {
     "required": true,
     "definition": "The ripple harmonics: a list of {rotor_harmonic, amplitude, phase}, rotor_harmonic in cycles per rotor turn (an integer >= 1, each once), amplitude in the term's unit (>= 0, the torque at the output), phase in rad.",
     "value": "harmonic-list",
     "si_unit": "N·m",
     "units": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "measured_by": "a rotor-angle sweep (the plateaus, if they cover more than one rotor turn)"
    },
    "coulomb_friction": {
     "required": false,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "viscous_friction": {
     "required": false,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "output_inertia": {
     "required": false,
     "key": true,
     "measured_by": "chirps (or the datasheet)"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "python": {
     "how": "reference",
     "implementation": "model.py",
     "implementation_sha256": "e30eb5e3ed7c4ae09b06fc448e31e52c81e5a4cad9bd3e9d0e61b504c6d0395c",
     "engine": null,
     "note": "The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI."
    },
    "js": {
     "how": "reference",
     "implementation": "model.js",
     "implementation_sha256": "31f08577ba8ccdf3c12dd8bbe672a67ac870e94b1ccb6fc348fc64cb0640ddba",
     "engine": null,
     "note": "The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12."
    },
    "mujoco": {
     "how": "plugin",
     "implementation": "robotparts.mujoco",
     "engine": "mujoco",
     "maps": {
      "armature": "output_inertia",
      "frictionloss": "coulomb_friction",
      "damping": "viscous_friction"
     },
     "settings": {
      "friction_solref": {
       "definition": "The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.",
       "value": "number-list",
       "length": 2
      },
      "friction_solimp": {
       "definition": "The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.",
       "value": "number-list",
       "length": 5,
       "bounds": {
        "min": 0,
        "min_exclusive": true
       }
      }
     },
     "note": "Friction natively; the plugin applies the ripple from the rotor angle each step."
    }
   },
   "validity": {
    "dims": {
     "output_speed": {
      "definition": "|v|, the output speed the terms were fitted or checked across.",
      "unit": "rad/s"
     }
    },
    "assumptions": [
     "The ripple is periodic in the rotor angle and the same in both directions (cogging); direction-dependent ripple is not modelled.",
     "The harmonics hold wherever the joint goes, because the magnets turn with the rotor."
    ]
   },
   "readme": "README.md",
   "sha256": "426b7ff1b64c6c9c3f21c8fafd4ba209e1b23c8423f6d35782e20189d31e1b6e",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "de559c03e6c7dbe2ca3eeb2ec07e5ed0ce1b68b5bd246cadc2ee46ff374bb3af",
     "url": "https://robotparts.dev/v2/models/actuator/ripple/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/de559c03e6c7dbe2ca3eeb2ec07e5ed0ce1b68b5bd246cadc2ee46ff374bb3af.md",
     "bytes": 4089
    },
    "model.js": {
     "sha256": "31f08577ba8ccdf3c12dd8bbe672a67ac870e94b1ccb6fc348fc64cb0640ddba",
     "url": "https://robotparts.dev/v2/models/actuator/ripple/model.js",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/31f08577ba8ccdf3c12dd8bbe672a67ac870e94b1ccb6fc348fc64cb0640ddba.js",
     "bytes": 811
    },
    "model.json": {
     "sha256": "426b7ff1b64c6c9c3f21c8fafd4ba209e1b23c8423f6d35782e20189d31e1b6e",
     "url": "https://robotparts.dev/v2/models/actuator/ripple/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/426b7ff1b64c6c9c3f21c8fafd4ba209e1b23c8423f6d35782e20189d31e1b6e.json",
     "bytes": 4541
    },
    "model.py": {
     "sha256": "e30eb5e3ed7c4ae09b06fc448e31e52c81e5a4cad9bd3e9d0e61b504c6d0395c",
     "url": "https://robotparts.dev/v2/models/actuator/ripple/model.py",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/e30eb5e3ed7c4ae09b06fc448e31e52c81e5a4cad9bd3e9d0e61b504c6d0395c.py",
     "bytes": 1372
    }
   },
   "units": {
    "harmonics": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "coulomb_friction": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "viscous_friction": {
     "N·m·s/rad": 1,
     "mN·m·s/rad": 0.001
    },
    "output_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    }
   },
   "units_by_sha256": {
    "426b7ff1b64c6c9c3f21c8fafd4ba209e1b23c8423f6d35782e20189d31e1b6e": {
     "harmonics": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "coulomb_friction": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "viscous_friction": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "output_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     }
    }
   },
   "readme_markdown": "# M4.ripple — Rotor ripple map\n\n**Coulomb + viscous + rotor-keyed ripple.** Family: grey box. Rung: 4, the drivetrain (ripple, backlash, compliance). Category: actuator.\n\nCogging and commutation ripple: a torque that repeats with the rotor's angle, written as harmonics, plus optional Coulomb and viscous friction. Because the magnets and windings turn with the rotor, a map in rotor angle holds wherever the joint goes.\n\n**When to use it.** Use it when position holds and slow moves show a periodic error; one rotor-angle sweep fits it.\n\n## Equation\n\n```\ntau_r = sum_k amplitude_k*sin(rotor_harmonic_k*theta_rotor + phase_k), theta_rotor = gear_ratio*theta_output in rad from the rotor zero the simulator uses (tau_r adds coulomb_friction*sign(v) + viscous_friction*v when stated)\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `harmonics` | yes | N·m | N·m, mN·m | a rotor-angle sweep (the plateaus, if they cover more than one rotor turn) |\n| `coulomb_friction` | no | N·m | N·m, mN·m | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `viscous_friction` | no | N·m·s/rad | N·m·s/rad, mN·m·s/rad | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `output_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | chirps (or the datasheet) |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- `harmonics`: The ripple harmonics: a list of {rotor_harmonic, amplitude, phase}, rotor_harmonic in cycles per rotor turn (an integer >= 1, each once), amplitude in the term's unit (>= 0, the torque at the output), phase in rad.\n\n## Inputs and state\n\n- input `v` (rad/s): The output's angular speed.\n- input `theta_rotor` (rad): The rotor's angle, gear_ratio times the output angle from the rotor zero the simulator uses.\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| python | reference | — | `model.py` (sha256 `e30eb5e3ed7c…`). The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI. |\n| js | reference | — | `model.js` (sha256 `31f08577ba8c…`). The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12. |\n| mujoco | plugin | mujoco, release named by the fit | `robotparts.mujoco`. Friction natively; the plugin applies the ripple from the rotor angle each step. Maps: armature = `output_inertia`, frictionloss = `coulomb_friction`, damping = `viscous_friction`. |\n\n**mujoco settings** a fit may state:\n\n- `friction_solref`: 2 numbers. The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.\n- `friction_solimp`: 5 numbers, in (0, inf). The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.\n\n## Validity\n\n- A fit states the range of `output_speed` (rad/s) it holds across: |v|, the output speed the terms were fitted or checked across.\n- The ripple is periodic in the rotor angle and the same in both directions (cogging); direction-dependent ripple is not modelled.\n- The harmonics hold wherever the joint goes, because the magnets turn with the rotor.\n\n## Use it\n\n```python\nimport importlib.util\nspec = importlib.util.spec_from_file_location(\"ripple\", \"model.py\")\nmodel = importlib.util.module_from_spec(spec); spec.loader.exec_module(model)\nterms = {...}  # a fit's terms in SI (robotparts.models.si_terms(fit, definition) converts them)\ntau_r, state = model.torque(terms, {\"v\": 0.0, \"theta_rotor\": 0.0}, None, 0.001)\n```\n\nDefined since robotparts/2.3. It is robotparts/2.3's `ripple_map` kind. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/ripple/"
  },
  {
   "format": "robotparts-model-definition/1",
   "category": "actuator",
   "word": "stribeck",
   "rung": 3,
   "name": "M3.stribeck",
   "family": "static friction",
   "title": "Stribeck friction",
   "description": "Coulomb + viscous + Stribeck",
   "summary": "Friction that falls from its breakaway value to the Coulomb value as the output speeds up, plus viscous friction (the Stribeck curve).",
   "equation": "tau_r = (coulomb_friction + (breakaway_torque - coulomb_friction)*exp(-(|v|/stribeck_velocity)^stribeck_exponent))*sign(v) + viscous_friction*v; stribeck_exponent is 2 when absent",
   "since": "robotparts/2.3",
   "v2_3_kind": "stribeck",
   "inputs": {
    "v": {
     "definition": "The output's angular speed.",
     "unit": "rad/s"
    }
   },
   "state": {},
   "output": {
    "name": "tau_r",
    "definition": "The resisting torque at the output: what the motor must add to move the output as the inputs say.",
    "unit": "N·m",
    "sign": "The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle)."
   },
   "terms": {
    "coulomb_friction": {
     "required": true,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "viscous_friction": {
     "required": true,
     "key": true,
     "measured_by": "velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn"
    },
    "breakaway_torque": {
     "required": true,
     "key": true,
     "measured_by": "slow plateaus below 0.5 rad/s"
    },
    "stribeck_velocity": {
     "required": true,
     "key": true,
     "measured_by": "slow plateaus below 0.5 rad/s"
    },
    "stribeck_exponent": {
     "required": false,
     "definition": "Shape exponent d of the Stribeck curve, how sharply friction falls with speed; 2 when absent.",
     "value": "number",
     "si_unit": "",
     "units": {
      "": 1
     },
     "positive": true,
     "measured_by": "slow plateaus below 0.5 rad/s",
     "default": 2
    },
    "output_inertia": {
     "required": false,
     "key": true,
     "measured_by": "chirps (or the datasheet)"
    }
   },
   "together": [],
   "exclusive": [],
   "constraints": [],
   "variants": {},
   "backends": {
    "python": {
     "how": "reference",
     "implementation": "model.py",
     "implementation_sha256": "87f9bc8becd9dd5db7e1811b349fb96eb31e422435ab4c18ed43db7ab3952a5b",
     "engine": null,
     "note": "The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI."
    },
    "js": {
     "how": "reference",
     "implementation": "model.js",
     "implementation_sha256": "15bdb5ab166da818de23201e58f524d1cfb5e0604aa64ecad9f2ce51d68f1c34",
     "engine": null,
     "note": "The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12."
    },
    "mujoco": {
     "how": "plugin",
     "implementation": "robotparts.mujoco",
     "engine": "mujoco",
     "maps": {
      "armature": "output_inertia",
      "frictionloss": "breakaway_torque",
      "damping": "viscous_friction"
     },
     "settings": {
      "friction_solref": {
       "definition": "The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.",
       "value": "number-list",
       "length": 2
      },
      "friction_solimp": {
       "definition": "The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.",
       "value": "number-list",
       "length": 5,
       "bounds": {
        "min": 0,
        "min_exclusive": true
       }
      }
     },
     "note": "The static level sticks natively (frictionloss = breakaway_torque); the plugin adds back what friction falls by as the output speeds up, so sliding friction is the Stribeck curve."
    }
   },
   "validity": {
    "dims": {
     "output_speed": {
      "definition": "|v|, the output speed the terms were fitted or checked across.",
      "unit": "rad/s"
     }
    },
    "assumptions": [
     "Friction depends on speed only: not on load, temperature or rest time.",
     "The curve holds across the speeds it was fitted on; below the slowest plateau the breakaway level is extrapolated."
    ]
   },
   "readme": "README.md",
   "sha256": "336b22e8b61428b5cc58a24504d711778a59b455c29875152e0da7fefb77b8d8",
   "versions": [],
   "files": {
    "README.md": {
     "sha256": "5a1c264a105f1425b918710e6e478bc9980bffeb2e78c893273b1d72017b96cc",
     "url": "https://robotparts.dev/v2/models/actuator/stribeck/README.md",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/5a1c264a105f1425b918710e6e478bc9980bffeb2e78c893273b1d72017b96cc.md",
     "bytes": 3968
    },
    "model.js": {
     "sha256": "15bdb5ab166da818de23201e58f524d1cfb5e0604aa64ecad9f2ce51d68f1c34",
     "url": "https://robotparts.dev/v2/models/actuator/stribeck/model.js",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/15bdb5ab166da818de23201e58f524d1cfb5e0604aa64ecad9f2ce51d68f1c34.js",
     "bytes": 827
    },
    "model.json": {
     "sha256": "336b22e8b61428b5cc58a24504d711778a59b455c29875152e0da7fefb77b8d8",
     "url": "https://robotparts.dev/v2/models/actuator/stribeck/model.json",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/336b22e8b61428b5cc58a24504d711778a59b455c29875152e0da7fefb77b8d8.json",
     "bytes": 4476
    },
    "model.py": {
     "sha256": "87f9bc8becd9dd5db7e1811b349fb96eb31e422435ab4c18ed43db7ab3952a5b",
     "url": "https://robotparts.dev/v2/models/actuator/stribeck/model.py",
     "content_url": "https://robotparts.dev/v2/models/by-sha256/87f9bc8becd9dd5db7e1811b349fb96eb31e422435ab4c18ed43db7ab3952a5b.py",
     "bytes": 1400
    }
   },
   "units": {
    "coulomb_friction": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "viscous_friction": {
     "N·m·s/rad": 1,
     "mN·m·s/rad": 0.001
    },
    "breakaway_torque": {
     "N·m": 1,
     "mN·m": 0.001
    },
    "stribeck_velocity": {
     "rad/s": 1,
     "rpm": 0.10471975511965977,
     "deg/s": 0.017453292519943295
    },
    "stribeck_exponent": {
     "": 1
    },
    "output_inertia": {
     "kg·m²": 1,
     "kg·cm²": 0.0001,
     "kg·mm²": 1e-06,
     "g·cm²": 1e-07,
     "g·mm²": 1e-09
    }
   },
   "units_by_sha256": {
    "336b22e8b61428b5cc58a24504d711778a59b455c29875152e0da7fefb77b8d8": {
     "coulomb_friction": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "viscous_friction": {
      "N·m·s/rad": 1,
      "mN·m·s/rad": 0.001
     },
     "breakaway_torque": {
      "N·m": 1,
      "mN·m": 0.001
     },
     "stribeck_velocity": {
      "rad/s": 1,
      "rpm": 0.10471975511965977,
      "deg/s": 0.017453292519943295
     },
     "stribeck_exponent": {
      "": 1
     },
     "output_inertia": {
      "kg·m²": 1,
      "kg·cm²": 0.0001,
      "kg·mm²": 1e-06,
      "g·cm²": 1e-07,
      "g·mm²": 1e-09
     }
    }
   },
   "readme_markdown": "# M3.stribeck — Stribeck friction\n\n**Coulomb + viscous + Stribeck.** Family: static friction. Rung: 3, friction that changes with state. Category: actuator.\n\nFriction that is highest just as the output breaks away and falls to the Coulomb level as it speeds up (the Stribeck curve), plus viscous drag. In MuJoCo the breakaway level sticks natively and the plugin gives back the fall with speed each step.\n\n**When to use it.** Use it when slow motion and starts from rest matter: the plateaus below 0.5 rad/s show the curve.\n\n## Equation\n\n```\ntau_r = (coulomb_friction + (breakaway_torque - coulomb_friction)*exp(-(|v|/stribeck_velocity)^stribeck_exponent))*sign(v) + viscous_friction*v; stribeck_exponent is 2 when absent\n```\n\nOutput `tau_r` (N·m): The resisting torque at the output: what the motor must add to move the output as the inputs say. The joint feels -tau_r (a resisting torque opposes motion; ripple pushes and pulls with angle).\n\n## Terms\n\n| term | required | unit (SI) | units a fit may use | measured by |\n|---|---|---|---|---|\n| `coulomb_friction` | yes | N·m | N·m, mN·m | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `viscous_friction` | yes | N·m·s/rad | N·m·s/rad, mN·m·s/rad | velocity plateaus, both directions, 6-8 speeds, each at least one rotor turn |\n| `breakaway_torque` | yes | N·m | N·m, mN·m | slow plateaus below 0.5 rad/s |\n| `stribeck_velocity` | yes | rad/s | rad/s, rpm, deg/s | slow plateaus below 0.5 rad/s |\n| `stribeck_exponent` | no | 1 | 1 | slow plateaus below 0.5 rad/s |\n| `output_inertia` | no | kg·m² | kg·m², kg·cm², kg·mm², g·cm², g·mm² | chirps (or the datasheet) |\n\nDeclared terms (the rest are registry keys, defined in SCHEMA2.md §7.3):\n\n- `stribeck_exponent`: Shape exponent d of the Stribeck curve, how sharply friction falls with speed; 2 when absent.\n\n## Inputs and state\n\n- input `v` (rad/s): The output's angular speed.\n\n## Backends\n\n| backend | how | engine | what runs |\n|---|---|---|---|\n| python | reference | — | `model.py` (sha256 `87f9bc8becd9…`). The contract's own ruler: stdlib Python, torque(terms, inputs, state, dt) -> (tau_r, state), terms in SI. |\n| js | reference | — | `model.js` (sha256 `15bdb5ab166d…`). The same equation as model.py as an ES module (torque(terms, inputs, state, dt) -> {tau, state}); tests/acceptance_v2/test_amendment_2_5.py holds the two to 1e-12. |\n| mujoco | plugin | mujoco, release named by the fit | `robotparts.mujoco`. The static level sticks natively (frictionloss = breakaway_torque); the plugin adds back what friction falls by as the output speeds up, so sliding friction is the Stribeck curve. Maps: armature = `output_inertia`, frictionloss = `breakaway_torque`, damping = `viscous_friction`. |\n\n**mujoco settings** a fit may state:\n\n- `friction_solref`: 2 numbers. The joint's solreffriction (timeconst, dampratio): how hard frictionloss sticks; MuJoCo's soft default creeps below about 0.4 rad/s on a light hinge.\n- `friction_solimp`: 5 numbers, in (0, inf). The joint's solimpfriction (dmin, dmax, width, midpoint, power), every entry > 0.\n\n## Validity\n\n- A fit states the range of `output_speed` (rad/s) it holds across: |v|, the output speed the terms were fitted or checked across.\n- Friction depends on speed only: not on load, temperature or rest time.\n- The curve holds across the speeds it was fitted on; below the slowest plateau the breakaway level is extrapolated.\n\n## Use it\n\n```python\nimport importlib.util\nspec = importlib.util.spec_from_file_location(\"stribeck\", \"model.py\")\nmodel = importlib.util.module_from_spec(spec); spec.loader.exec_module(model)\nterms = {...}  # a fit's terms in SI (robotparts.models.si_terms(fit, definition) converts them)\ntau_r, state = model.torque(terms, {\"v\": 0.0}, None, 0.001)\n```\n\nDefined since robotparts/2.3. It is robotparts/2.3's `stribeck` kind. The contract is SCHEMA2.md §4.3.2; the fit format is `schemas/model.schema.json`.\n",
   "url": "https://robotparts.dev/v2/models/actuator/stribeck/"
  }
 ],
 "fits": [
  {
   "id": "5060097e72a8",
   "part": "aifitlab-8541438771336",
   "part_title": "SteadyWin GIM4305-10 Planetary Reducer Motor",
   "category": "actuator",
   "word": "datasheet",
   "name": "M1.datasheet",
   "sha256": "5060097e72a82cf70d498468b265be83ca116e8d7158956a27c9cae0bef69e74",
   "url": "https://robotparts.dev/v2/files/5060097e72a82cf70d498468b265be83ca116e8d7158956a27c9cae0bef69e74.json",
   "definition_sha256": "03b234a7f22220cd1eae425edca3af6d9ea19ab41a8af812fc91a9fdaeb74e6c",
   "view": {
    "title": "M1.datasheet — the stated values: SteadyWin states the ratio and no inertia or friction (BAM Robotics)",
    "license": "CC-BY-4.0",
    "attribution": "BAM Robotics",
    "made_by": "BAM Robotics",
    "source_url": "https://www.steadywin.cn/en/h-pd-9.html",
    "note": "A fit of the datasheet model (models/actuator/datasheet/). The CC-BY-4.0 licence is provisional, as the MJCF's (SCHEMA2.md §14.1)."
   },
   "fit": {
    "format": "robotparts-model/1",
    "part": "aifitlab-8541438771336",
    "category": "actuator",
    "name": "M1.datasheet",
    "definition_sha256": "03b234a7f22220cd1eae425edca3af6d9ea19ab41a8af812fc91a9fdaeb74e6c",
    "description": "the stated values: SteadyWin states the ratio and no inertia or friction",
    "terms": {
     "gear_ratio": {
      "value": 10.0,
      "unit": ":1",
      "source": "part.py gear_ratio (SteadyWin's spec table, 10:1)"
     }
    },
    "backends": [],
    "validity": {},
    "mjcf_sha256": "74ef7103f95899dd6a13dc7efbdb9f7bce1dbd2ffdd9a4afe15f2db9efe58d91",
    "fitted_from": [],
    "source_url": null,
    "note": "The datasheet holds no inertia, friction or ripple for this part, so this model adds nothing to the hosted MJCF; it is the honest answer to what the maker states."
   },
   "scores": []
  }
 ]
}
