User defined constants

TO SUPPORT MY WORK, ORDER A COMMERCIAL LICENSE
THANK YOU!

Tutorial Math Collection API spec Download

Below is the code for JAVA, the code for C# is almost identical.

import org.mariuszgromada.math.mxparser.*;
...
Constant a = new Constant("a", 5);
Constant b = new Constant("b = 10");        
Expression e = new Expression("a+b", a, b);

mXparser.consolePrintln(a.getConstantName() + " = " + a.getConstantValue());
mXparser.consolePrintln(b.getConstantName() + " = " + b.getConstantValue());
mXparser.consolePrintln("Res: " + e.getExpressionString() + " = " + e.calculate());
[mXparser-v.5.0.0] a = 5.0
[mXparser-v.5.0.0] b = 10.0
[mXparser-v.5.0.0] Res: a+b = 15.0
Nuget
Install-Package MathParser.org-mXparser -Version 5.0.2
Maven
<dependency>
<groupid>org.mariuszgromada.math</groupid>
<artifactid>MathParser.org-mXparser</artifactid>
<version>5.0.2</version>
</dependency>
Gradle
implementation 'org.mariuszgromada.math:MathParser.org-mXparser:5.0.2'
Gradle (Kotlin)
implementation("org.mariuszgromada.math:MathParser.org-mXparser:5.0.2")
GitHub
git clone https://github.com/mariuszgromada/MathParser.org-mXparser
OTHER DOWNLOAD OPTIONS

Download latest release – v.5.0.2 Leonis: bin + docDownload latest release – v.5.0.2 Leonis: bin only, includes separate binaries for various .NET platforms and Java versions
Source code .zipSource code .tar.gz
View on GitHubMathSpace.pl

DONATION
Did you find the software useful?
Please consider donation 🙂
DONATE