mXparser - Hello World - JAVA

MathParser.org - mXparser - logo - JAVA

*** If you found the software useful donation is something you might consider 🙂 ***

If you found the software useful donation is something you might consider :-)

mXparser "Hello World!" JAVA tutorial using Eclipse Mars 1.

package mxparser.helloworld;

import org.mariuszgromada.math.mxparser.*;

public class HelloWorld {
   public static void main(String[] args) {
      Expression eh = new Expression("5^2 * 7^3 * 11^1 * 67^1 * 49201^1");
      Expression ew = new Expression("71^1 * 218549^1 * 6195547^1");
      String h = mXparser.numberToAsciiString( eh.calculate() );
      String w = mXparser.numberToAsciiString( ew.calculate() );
      mXparser.consolePrintln(h + " " + w);
   }
}

Step 1.1 Create new project.

01 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 1.2. Select "Java Project" on the "Wizards" list.

02 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 1.3. Input "Project name" and browse "Project location".

03 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 1.4. Reference "mxparser.jar" library.

04 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 1.5. Pickup location of the  "mxparser.jar" file.

05 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 1.6. Click "Finish" and your project is ready to code!

06 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 2.1. Create first class in the created project.

07 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 2.2. Set the class type / name and package name.

08 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 2.3. This is a code draft of your class.

09 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 2.4. Import "org.mariuszgromada.math.mxparser" package - you should see code completion hints while typing.

10 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 2.5. Write the full "Hello World!" code. Run the project and check whether "Hello World!" text was displayed!

11 - mXparser - Hello World - JAVA - Eclipse Mars 1

Step 4. Enjoy using mXparser 🙂

*** If you found the software useful donation is something you might consider 🙂 ***

If you found the software useful donation is something you might consider :-)

Best regards,

Mariusz Gromada

 

Download latest release – v.4.1.1 Aeries: bin + doc + src (.zip 13.4 MB)

Download latest release – v.4.1.1 Aeries: bin only (.zip 4.35 MB) – separate binaries for java: 1.5, 1.6, 1.7, 1.8; .NET: 2.0, 3.0, 3.5, 4.0, 4.5, 4.6, 4.7, .NET Core, .NET Standard, .NET PCL, Xamarin.Android, Xamarin.iOS

Source code .zipSource code .tar.gz View on GitHubMathSpace.pl