-
Computes solutions for quadratic equation: ax^3 + bx^2 + c*x + d = 0
. Returns array of solutions, both real & imaginary. Note: a
MUST NOT be zero. If the cubic term is missing (i.e. zero), use solveQuadratic or solveLinear instead.
cubic coefficient
quadratic coefficient
linear coefficient
constant offset
tolerance to determine multiple roots
Computes solution for linear equation: ax + b = 0
.
Note: Returns 0 iff a == 0
slope
constant offset
Computes solutions for quadratic equation: ax^2 + bx + c = 0
. Returns array of real solutions. Note: a
MUST NOT be zero. If the quadratic term is missing, use solveLinear instead.
quadratic coefficient
linear coefficient
constant offset
tolerance to determine multiple roots
Generated using TypeDoc
Produces a new function which computes derivative of the given single-arg function. The extra optional arg
eps
is used to define the step width for computing derived values:f'(x) = (f(x + eps) - f(x)) / eps
The original function is assumed to be fully differentiable in the interval the returned function is going to be used. No validity checks of any form are done.
https://en.wikipedia.org/wiki/Derivative#Continuity_and_differentiability