MCPcopy
hub / github.com/franciscop/ola / ola.js

File ola.js

ola.js:None–None  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1// Calculate the position based on the current position, speed and time:
2// https://www.wolframalpha.com/input/?i=x+%3D+2+*+t+%5E+3+-+3+*+t+%5E+2+%2B+1+from+t+%3D+0+to+t+%3D+1
3const position = (x0, v0, t1, t) => {
4 const a = (v0 * t1 + 2 * x0) / t1 ** 3;

Callers

nothing calls this directly

Calls 2

positionFunction · 0.70
speedFunction · 0.70

Tested by

no test coverage detected