// curve‑calc.js.txt (function(){ "use strict"; window.CurveCalc = { calcDaCurve:function(torque0, torque90, stepCount=45){ const pts = []; for(let i=0;i<=stepCount;i++){ const deg = 90 * i / stepCount; const t = torque0 + (torque90-torque0) * i / stepCount; pts.push({deg:deg, torque:t}); } return pts; }, calcSrCurve:function(air0, air90, spring0, spring90, stepCount=45){ const airPts = []; const springPts = []; for(let i=0;i<=stepCount;i++){ const deg = 90 * i / stepCount; const airTorque = air0 + (air90-air0)*i/stepCount; const springTorque = spring0 + (spring90-spring0)*i/stepCount; airPts.push({deg:deg, torque:airTorque}); springPts.push({deg:deg, torque:springTorque}); } return { airStroke: airPts, springStroke: springPts }; } }; })();