UNPKG
@qbead/bloch-sphere
Version:
latest (0.3.0)
0.3.0
0.2.0
0.1.0
A 3D Bloch Sphere visualisation built with Three.js and TypeScript.
qbead.org
qbead/bloch-sphere
@qbead/bloch-sphere
/
src
/
math
/
interpolation.ts
7 lines
(6 loc)
•
133 B
text/typescript
View Raw
1
2
3
4
5
6
7
/** * Standard linear interpolation function */
export function lerp(
a
: number, b: number, t: number) { return
a
+ t * (
b
-
a
) }