Titan Engine
STANDARD LIBRARY · 43 NATIVE FUNCTIONS + INLINE OPERATORS

Formula & Bytecode Function Reference

Every function in Titan's standard library executes natively in Rust on stack-allocated VMValue enums. Click any formula example below to load it into the live WASM evaluator.

Live WASM Formula Tester Seed cells: A1=120, A2=280, A3=400 · B1="North", B2="South", B3="North"
fx
Result: 520

Math & Rounding

SUM(value1, [value2, ...])

Sums all numbers across scalars, arrays, and lazy ranges.

AVERAGE(value1, [value2, ...])

Arithmetic mean of numeric cells (automatically ignores empty cells).

MIN(range) / MAX(range)

Smallest or largest numeric value in one or more ranges.

ROUND / ROUNDUP / ROUNDDOWN(number, [digits])

Rounds to nearest, away from zero (ROUNDUP), or toward zero (ROUNDDOWN).

ABS(number) / MOD(number, divisor)

Absolute value and remainder after division.

Logical & Short-Circuit Branching

IF(condition, value_if_true, [value_if_false])

Compiles to JmpIfFalse bytecode so untaken branches never execute.

IFERROR(value, value_if_error)

Wraps expression in TryCatch / EndTry bytecode to intercept any error.

IFS(cond1, val1, [cond2, val2, ...])

Evaluates multiple conditions in order and returns the first match.

AND(...) / OR(...) / NOT(logical)

Boolean combinators over scalars and ranges (empty cells ignored).

Lookup & Reference

VLOOKUP(key, range, col_index, [is_sorted])

Vertical lookup with automatic O(1) FxHasher spatial indexing for exact matches.

XLOOKUP(key, lookup_range, return_range, [if_not_found])

Modern directional lookup supporting custom fallback values.

INDEX(range, row_num, [col_num]) / MATCH(key, range, [type]) / HLOOKUP(...)

Positional cell retrieval and 1-based index search.

Conditional Aggregation & Counters

SUMIF / COUNTIF / AVERAGEIF(range, criteria, [target_range])

Supports exact values and relational operators (">100", "<=400", "<>South").

SUMIFS / COUNTIFS / AVERAGEIFS(...)

Multi-column conditional aggregation with direct 32×32 SoA chunk scanning.

COUNT / COUNTA / COUNTBLANK(range)

Counts numeric cells, non-empty cells, or blank cells.

Text Manipulation

CONCATENATE(...) / TEXTJOIN(delimiter, ignore_empty, ...)

Joins strings and ranges into a reference-counted StringPool entry.

LEFT / RIGHT / MID / LEN / TRIM

UTF-8 character-aware slicing, length calculation, and whitespace normalization.

FIND / SEARCH / SUBSTITUTE / REPLACE

Case-sensitive (FIND) and case-insensitive (SEARCH) substring position and replacement.

Date & Time (Excel 1900 Serial System)

DATE(year, month, day) / YEAR / MONTH / DAY

Converts between calendar dates and Excel 1900 serial numbers.

EOMONTH(start_date, months) / DATEDIF(start, end, unit) / TODAY / NOW

End-of-month serial calculation and interval differences ("Y", "M", "D", "MD", "YM", "YD").