nerdamer/core
Expressions, equations, numeric values, conversion helpers, errors, and other core building blocks.
nerdamer/core. For functions used inside nerdamer('...'), see Nerdamer Notation.Function
Classes
AssignmentErrorClassThrown when code attempts to assign to a reserved or otherwise non-assignable parser name.
CoeffObjectClassStores coefficients indexed by the power or multidegree collected from an expression.
ConverterClassFormats Nerdamer values as TeX or normalized text and imports supported TeX input.
DimensionErrorClassThrown when vector, matrix, or structured-entity dimensions are incompatible.
DivisionByZeroErrorClassThrown for exact division by zero. Small nonzero numerical values are not treated as zero.
EquationClassRepresents a symbolic equality between two expression sides.
ExpressionClassRepresents a symbolic expression in Nerdamer's canonical expression tree.
MathErrorClassGeneral mathematical precondition error for cases without a more specific error type.
MissingReferenceErrorClassThrown when a named converter or pattern reference cannot be resolved.
NaNErrorClassThrown when a required numeric conversion produces NaN.
NotImplementedErrorClassUsed for recognized operations that have not been implemented yet.
OperatorErrorClassUsed for invalid parser-operator definitions and operator dispatch failures.
ParserErrorClassGeneral parser error for construction, evaluation, and registered-function failures.
ParserSyntaxErrorClassParser syntax error kept separate from lower-level tokenization failures.
PolynomialErrorClassThrown when input cannot be represented as a polynomial under the requested requirements.
RationalClassRepresents an exact rational value as a bigint numerator and denominator.
UndefinedErrorClassUsed when a mathematical operation has no defined value in the handled domain.
UnexpectedDataTypeClassThrown when an operation receives a Nerdamer entity of the wrong runtime type.
UnexpectedInputErrorClassUsed when input parses successfully but does not have the form an operation requires.
UnexpectedTokenErrorClassThrown when tokenization encounters invalid adjacency, punctuation, or bracket structure.
UnsupportedOperationErrorClassThrown when an operation is known but unsupported for the supplied form or domain.
ZeroToZeroPowerErrorClassThrown for the indeterminate symbolic form 0^0.
Interface
Type
Variable
APIs
ElementsSortType(a: Expression, b: Expression): numberAPIAPI exported by Nerdamer.
ExpressionInput: number | string | Rational | Expression | bigint | DecimalAPIValues accepted by Nerdamer's expression-oriented parsing APIs.
JsFunction(...args: number[]): number | booleanAPINative JavaScript function produced or consumed by numerical compilation APIs. Arguments and numeric results use JavaScript number arithmetic rather than Nerdamer's exact rational or arbitrary-precision symbolic representation. Boolean results support compiled comparison expressions.
NerdamerInput: ExpressionInput | Vector | ValuesSet | Collection | Matrix | Dictionary | EquationAPIValues accepted across Nerdamer's root API and direct object model. This extends ExpressionInput with the structured parser entities and equations that can be passed back into supported operations. Individual functions may accept a narrower subset and should document that restriction locally.
OptionValue: string | boolean | number | string[] | OptionsObjectAPIValues currently accepted by Nerdamer's broad settings objects.
ParserConstants: Record<string, (): string | string>APIConstant definitions accepted by the parser's constant registry. String definitions are parsed when the constant is encountered. Function definitions are deferred factories that return parser text, allowing constants such as pi and e to reflect the active numerical precision. The registry itself is process-wide; this type does not imply isolated parser state.
ParserEntity: Expression | Vector | ValuesSet | Collection | Matrix | Equation | DictionaryAPIValues that can be produced by Nerdamer's parser.
ParserValuesObject: Record<string, NerdamerInput>APINamed values substituted while parsing or evaluating an input expression. Keys are parser variable names. This compatibility type accepts the same broad value union as the root API, but not every substitution path can consume every structured entity. The receiving operation's documentation defines the narrower requirements when one applies.
StructuredEntityType: Matrix | Vector | Collection | DictionaryAPIStructured parser entities that participate in aggregate operations. The union describes Nerdamer's supported matrix, vector, ordered collection, and keyed dictionary containers. It excludes value sets and equations, whose semantics are not ordinary elementwise structured operations.
