number: 352
slug: chinese-windlass-another-arrangement
name: Another arrangement of the Chinese windlass
brown: "Another arrangement of the Chinese windlass illustrated by 129 of this table."
units: cm
sim: {timestep: 0.001, integrator: implicitfast, iterations: 60, duration_s: 8.0, floor: false}
bodies:
  # the frame: the two legs, the head carrying the two fixed sheaves, and the barrel's bearings
  - {id: frame, shape: part, pos: [0, 0, 12.0], fixed: true, color: "#cdc0a4", pieces: [
      {kind: rod, from: [0, -36.0, -4.0], to: [0, -20.0, 74.0], radius: 1.1, collide: 0},
      {kind: rod, from: [0, 36.0, -4.0], to: [0, 20.0, 74.0], radius: 1.1, collide: 0},
      {kind: poly, points: [[-10.0, 73.5], [6.0, 73.5], [6.0, 76.5], [-10.0, 76.5]], y: [-23.0, 23.0], collide: 0},
      {kind: poly, points: [[-8.5, 70.0], [-7.5, 70.0], [-7.5, 73.5], [-8.5, 73.5]], y: [-19.8, -19.2], collide: 0},
      {kind: poly, points: [[-8.5, 70.0], [-7.5, 70.0], [-7.5, 73.5], [-8.5, 73.5]], y: [-16.8, -16.2], collide: 0},
      {kind: poly, points: [[3.5, 70.0], [4.5, 70.0], [4.5, 73.5], [3.5, 73.5]], y: [19.2, 19.8], collide: 0},
      {kind: poly, points: [[3.5, 70.0], [4.5, 70.0], [4.5, 73.5], [3.5, 73.5]], y: [16.2, 16.8], collide: 0},
      {kind: poly, points: [[-12, -5.0], [12, -5.0], [12, -4.0], [-12, -4.0]], y: [-40, 40], collide: 0, color: "#b9b09c"}]}
  - {id: barrel, shape: assembly, pos: [0, 0, 12.0], color: "#e6dcc6"}
  # the two fixed sheaves at the head, each in its rope's plane
  - {id: sheave_ta, shape: pulley, radius: 2.0, width: 2.0, pos: [-8.0, -18.0, 70.0], mass: 0.3, spokes: 0, hub: 0.6, flange: 0.5, color: "#e6dcc6", mount: frame}
  - {id: sheave_tb, shape: pulley, radius: 2.0, width: 2.0, pos: [4.0, 18.0, 70.0], mass: 0.3, spokes: 0, hub: 0.6, flange: 0.5, color: "#e6dcc6", mount: frame}
  # the hook pulley's block, with the weight on its hook
  - id: block
    shape: part
    pos: [-2.0, 0, 50.0]
    mass: 0.6
    color: "#b8ac92"
    pieces:
      - {kind: rod, from: [-2.0, -20.2, 50.0], to: [-2.0, 20.2, 50.0], radius: 0.4, collide: 0}
      - {kind: rod, from: [-2.0, -20.2, 50.0], to: [-2.0, -20.2, 43.5], radius: 0.35, collide: 0}
      - {kind: rod, from: [-2.0, 20.2, 50.0], to: [-2.0, 20.2, 43.5], radius: 0.35, collide: 0}
      - {kind: rod, from: [-2.0, -20.2, 43.5], to: [-2.0, 20.2, 43.5], radius: 0.35, collide: 0}
      - {kind: rod, from: [-2.0, 0, 43.5], to: [-2.0, 0, 40.0], radius: 0.3, collide: 0}
  - {id: sheave_a, shape: pulley, radius: 4.0, width: 2.0, pos: [-2.0, -18.0, 50.0], mass: 0.4, spokes: 0, hub: 1.0, flange: 0.5, color: "#e6dcc6", mount: block}
  - {id: sheave_b, shape: pulley, radius: 4.0, width: 2.0, pos: [-2.0, 18.0, 50.0], mass: 0.4, spokes: 0, hub: 1.0, flange: 0.5, color: "#e6dcc6", mount: block}
  - {id: bell, shape: weight, pos: [-2.0, 0, 36.0], mass: 10.0, size: [6.0, 6.0, 7.0], taper: 0.34, color: "#b9a179", mount: block}
joints:
  - {id: j_a, type: hinge, body: barrel, axis: [0, 1, 0], damping: 0.01}   # the barrel, turned by hand: the one driven joint; + : clockwise
  - {id: j_block, type: slide, body: block, axis: [0, 0, 1], damping: 0.05, range: [-16, 16]}   # + : up
  - {id: j_ta, type: hinge, body: sheave_ta, axis: [0, 1, 0], damping: 0.005}
  - {id: j_tb, type: hinge, body: sheave_tb, axis: [0, 1, 0], damping: 0.005}
  - {id: j_sa, type: hinge, body: sheave_a, axis: [0, 1, 0], damping: 0.01}
  - {id: j_sb, type: hinge, body: sheave_b, axis: [0, 1, 0], damping: 0.01}
pins:
  - {id: pin_sheave, a: sheave_a, b: sheave_b, at: [-0.3999999999999999, 0, 50.0]}   # the hook pulley's two sheaves are one
wheels:
  - {id: drum_a, body: barrel, pos: [0, -18.0, 0], radius: 10.0, width: 5.0, rim_width: 1.4, mass: 1.5, spokes: 4, hub: 1.0, flange: 0.6}
  - {id: drum_b, body: barrel, pos: [0, 18.0, 0], radius: 6.0, width: 5.0, rim_width: 1.4, mass: 1.0, spokes: 4, hub: 1.0, flange: 0.6}
shafts:
  - {id: axle, body: barrel, from: [0, -33.0, 0], to: [0, 33.0, 0], radius: 0.8}
  - {id: handspike, body: barrel, from: [0, -25.0, -6.0], to: [0, -25.0, 26.0], radius: 0.8}   # the bar through the barrel's end that the hand rocks (Brown's upright lever)
cords:
  - id: rope_a
    from: {body: barrel, at: [9.2665, -18.0, 6.65]}
    to: {body: sheave_a, at: [2.0703, -18.0, 52.35]}
    over: [drum_a, sheave_ta, sheave_a]
    under: [sheave_a]
    links: 72
    thickness: 0.8
    density: 1400
    stiffness: 40000.0
    pretension: 53.955
    damping: 12.0
    friction: 0.5
    model: capstan
  - id: rope_b
    from: {body: barrel, at: [-5.8024, 18.0, 8.65]}
    to: {body: sheave_b, at: [-6.0703, 18.0, 52.35]}
    over: [drum_b, sheave_tb, sheave_b]
    under: [drum_b, sheave_tb]
    links: 72
    thickness: 0.8
    density: 1400
    stiffness: 40000.0
    pretension: 53.955
    damping: 12.0
    friction: 0.5
    model: capstan
contact: {solref: [0.0006, 1], solimp: [0.95, 0.99, 0.0005], margin: 0}
driver: {joint: j_a, kind: velocity, rpm: 0, swing: {amplitude: 1.2, hz: 0.15}, kv: 200.0, max_torque: 50}
checks:
  # the hook falls half the difference of the drums' radii to the radian: half the difference of the circumferences a turn
  - {type: follow, out: j_block, in: j_a, expect: -0.02000, tol: 0.0016, min_r2: 0.99, settle_s: 1.0, window_s: 6.5}
  - {type: position, joint: j_block, min: -9.0, max: 3.0, settle_s: 0.0, window_s: 8}
camera: {target: [-1, 0, 33], position: [-215, -70, 52], fov: 31}
display:
  output: j_block
  labels: {j_a: "Windlass (driver)", j_block: "Hook pulley and weight", j_ta: Fixed sheave, j_sa: Hook pulley}

