himari 0.1.0

Dimensioned formula IR: parse LaTeX/MATLAB/paper notation once, check kg·m·s·A·K·mol·cd at compile time, and emit Rust.
Documentation
  • Coverage
  • 45.29%
    178 out of 393 items documented0 out of 181 items with examples
  • Size
  • Source code size: 653.5 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 3.6 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 3s Average build duration of successful builds.
  • all releases: 3s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • celestia-island/himari
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • langyo

English · 简体中文 · 繁體中文 · 日本語 · 한국어 · Français · Español · Русский · العربية

Himari turns one formula asset — written in a LaTeX subset, paper notation, or MATLAB style — into checked Rust code. The source lowers to a single dimensioned IR, so the same formula can be evaluated, differentiated, formatted, and emitted as an f64/f32 Rust function, a WGSL kernel, or a checked-in build.rs artifact — with the seven base quantities (kg·m·s·A·K·mol·cd) checked at compile time: m + s does not compile. The capability list, the language guide and the error catalogue live in the documentation.

Quickstart

# once the first version is on crates.io (see Status in the docs):
cargo add himari himari-macros
use himari_macros::formula_matlab;

let v0 = 12.0f64;
let g = 9.80665f64;
let t = 3.0f64;
let v = formula_matlab! {
    decl { v0 : speed [m/s]; g : acceleration [m/s^2]; t : time [s]; }
    v0 + g * t
};
assert!((v - 41.41995).abs() < 1e-9); // dimensions checked at compile time

Seven runnable examples live in examples/ — inline macros, unit conversion, symbolic differentiation, WGSL emission, the error catalogue, matrix idioms and a cross-file .formula library with a build.rs lane:

cargo run -p himari-example-quickstart

Documentation

The full documentation is built from docs/ and published at https://celestia-island.github.io/himari/. The full English document — the canonical source every translation is checked against — is docs/en/README.md; each locale mirrors it:

English · 简体中文 · 繁體中文 · 日本語 · 한국어 · Français · Español · Русский · العربية

License

Licensed under SySL 1.0; the full SySL NOTICE text (including model disclosure requirements) lives in docs/en/README.md and LICENSE.txt.