b-add
▸ function bAdd
(p1
: bigint[], p2
: bigint[]): bigint[]
Defined in basic/bigint/b-add.ts:22
Returns the result of adding two polynomials with bigint coefficients.
example
bAdd([1n,2n,3n],[3n,4n]); //=> [1n,5n,7n]
Parameters:
Name | Type | Description |
---|---|---|
p1 | bigint[] | a polynomial with coefficients given densely as an array of bigints from highest to lowest power, e.g. [5n,-3n,0n] represents the polynomial 5x^2 - 3x |
p2 | bigint[] | another polynomial |
Returns: bigint[]