@woosh/meep-engine
Version:
Pure JavaScript game engine. Fully featured and production ready.
18 lines • 965 B
TypeScript
/**
* Subtracts polynomial `a` from `target` in place.
*
* target(x) := target(x) - a(x)
*
* Coefficient layout: index i is the coefficient of x^i (ascending). If
* `a_len > target_len`, the excess coefficients in `target` at indices
* [target_len, a_len) are first cleared to zero, so the returned length
* (max of the two input lengths) reflects valid coefficients.
*
* @param {number[]|Float64Array|Float32Array} target receives the difference, length >= max(target_len, a_len)
* @param {number} target_len current number of coefficients in target
* @param {number[]|Float64Array|Float32Array} a
* @param {number} a_len number of coefficients in a
* @returns {number} new logical length of target = max(target_len, a_len)
*/
export function polynomial_sub_into(target: number[] | Float64Array | Float32Array, target_len: number, a: number[] | Float64Array | Float32Array, a_len: number): number;
//# sourceMappingURL=polynomial_sub_into.d.ts.map