nerdamer/solve
Equation solvers, system solvers, solution containers, and solver options.
nerdamer/solve. For functions used inside nerdamer('...'), see Nerdamer Notation.Functions
roots(input: ExpressionInput, variable?: ExpressionInput): VectorFunctionReturns polynomial roots as a Vector. Unlike solve(), which returns a SolutionSet with solver metadata, this function preserves the roots API's Vector return type. Numeric constants retain the historical square-root interpretation. Univariate polynomials delegate to PolynomialSolver and therefore return numerical roots.
solve(input: Equation | ExpressionInput, variable?: ExpressionInput, _options?: FunctionSolverOptions): SolutionSetFunctionSolves an equation or finds the zeros of an expression in one variable. The solver normalizes the input to expression = 0, tries direct symbolic transformations, factors numerator and denominator, and then applies symbolic, polynomial-numeric, and limited-range function-numeric strategies to the factors. Zeros of denominator factors are excluded from the result.
solveSystem(equations: Vector | Equation | ExpressionInput[], variables?: string[]): VectorFunctionSolves a system of expressions or equations for an ordered set of variables. Expressions are interpreted as equal to zero. The solver first tries exact linear reduction, then a lexicographic Groebner basis with symbolic back substitution for polynomial systems, and finally multivariate Newton-Raphson over a fixed search interval. Rational polynomial systems may have denominators cleared for symbolic work; candidates are checked against the original domain.
Classes
MultivariateSolverClassSearches numerically for isolated real solutions of a multivariate system. Each equation is interpreted as equation = 0. The solver starts Newton-Raphson at every point in a Cartesian grid, approximates the Jacobian with central differences, and merges nearby converged solutions.
PolynomialSolverClassFinds all complex roots of a univariate polynomial numerically. Coefficient arrays use ascending powers: the element at index k is the coefficient of x^k. Expression, Polynomial, and string inputs are converted directly to numerical complex coefficients before solving. Linear and quadratic inputs are handled directly; higher degrees use simultaneous Aberth iteration followed by Newton refinement.
SolutionSetClassA finite set of solution descriptors with solver-specific metadata.
SymbolicSolverClassApplies a defined set of exact transformations to one equation in one variable. Polynomial equations through degree four use closed-form formulas. Other recognized forms are solved by isolating and inverting elementary functions, exponentials, logarithmic sums, or a single square-root term. Unsupported input is reported by solve as unsolved so a caller can select a different strategy.
Interfaces
FunctionSolverOptions: unknownInterfaceOptions for numerical root searches over a fixed interval with FunctionSolver.
MultivariateSolverOptions: unknownInterfaceOptions for the finite-range multi-start search performed by MultivariateSolver.
Root: unknownInterfaceMetadata returned by a single numerical root-refinement attempt.
APIs
SolutionForm: "finite" | "parametric" | "all"APIDescribes whether the stored descriptors represent finite solutions, indexed families, or all values.
SolutionsType: "numeric" | "symbolic" | "mixed" | undefinedAPIDescribes whether accepted solutions were produced by numerical strategies, symbolic strategies, or both.
