PHPackages                             terryds/express-math - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. terryds/express-math

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

terryds/express-math
====================

A parser for its own math or computational problem markup language

04PHP

Since Jul 8Pushed 7y ago1 watchersCompare

[ Source](https://github.com/terryds/express-math)[ Packagist](https://packagist.org/packages/terryds/express-math)[ RSS](/packages/terryds-express-math/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (1)Used By (0)

ExpressMath
===========

[](#expressmath)

ExpressMath is a parser for its own math/computational problem markup language.
The markup language is inspired from Jinja template. See example for better understanding of how this works

Installing
----------

[](#installing)

ExpressMath installation using Composer

```
composer require terrydjony/express-math

```

Example
-------

[](#example)

```
require 'vendor/autoload.php';

use ExpressMath\ExpressMath;

$mathlang = 'Jika Andi punya {{ a }} bola, dan Budi punya {{ b }} bola, maka jumlah bola mereka adalah {% a + b %}';
$config = [
    'a' => mt_rand(2,5)
];

$expressMath = new ExpressMath();

$eval = $expressMath->eval($mathlang, $config);

var_dump($eval->getProblem()); // Jika Andi punya 4 bola, dan Budi punya 56 bola, maka jumlah bola mereka adalah
var_dump($eval->getVariables()); //   ['a' => 4, 'b' => 56]
var_dump($eval->getValue()); // 60
```

###  Health Score

19

—

LowBetter than 9% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/227af899f51765827a4a539ba2aa577d5167d46f0170a3bdb0e0f3d0806604e8?d=identicon)[terryds](/maintainers/terryds)

---

Top Contributors

[![terryds](https://avatars.githubusercontent.com/u/11571395?v=4)](https://github.com/terryds "terryds (2 commits)")

### Embed Badge

![Health badge](/badges/terryds-express-math/health.svg)

```
[![Health](https://phpackages.com/badges/terryds-express-math/health.svg)](https://phpackages.com/packages/terryds-express-math)
```

###  Alternatives

[mck89/peast

Peast is PHP library that generates AST for JavaScript code

19139.2M45](/packages/mck89-peast)[sauladam/shipment-tracker

Parses tracking information for several carriers, like UPS, USPS, DHL and GLS by simply scraping the data. No need for any kind of API access.

9843.5k](/packages/sauladam-shipment-tracker)[moonshine/layouts-field

Field for repeating groups of fields for MoonShine

108.5k](/packages/moonshine-layouts-field)[tcds-io/php-jackson

A lightweight, flexible object serializer for PHP, inspired by FasterXML/jackson

113.2k10](/packages/tcds-io-php-jackson)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
