Skip to content

reenigneEsrever92/polymath-rs

Repository files navigation

polymath-rs

Polymath is an Asciimath implementation with bindings for c, java and javascript written in rust.

It can be used to turn Asciimath into mathml so it can be viewed in a browser for example.

Quick Start

Rust

cargo add polymath-rs
fn main() {
    println!("{}", polymath_rs::to_math_ml("sum_(i=1)^n i^3=((n(n+1))/2)^2"));
}

Javascript - Node / Web

npm i --save polymath-web
import * as wasm from "polymath-web";

console.log(wasm.asciimath_to_mathml("int_0^1 f(x)dx"));

Java

<dependency>
    <groupId>eu.reverseengineer</groupId>
    <artifactId>polymath-java</artifactId>
    <version>0.1.1</version>
</dependency>
import eu.reverseengineer.asciimath.AsciiMath;

public class App {
  public static void main(String[] args) {
    System.out.println(AsciiMath.of("obrace(ubrace(t)_(a))^ba").toMathMl());
  }
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published