A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mathparser.org/mxparser-tutorial/unicode-math/ below:

Unicode math | mXparser – Math Expressions Parser for JAVA, C#, C++, Kotlin, Android, .NET/MONO/Xamarin – Mathematical Formula Parser

TO SUPPORT MY WORK, ORDER A COMMERCIAL LICENSE THANK YOU! The tutorial consists of more than 200 live examples from 50 sections given separately for JAVA, C# and C++. Each of the examples can be copied and run on your own environment. In addition, mXparser provides an extensive collection of over 500 built-in math functions, expressions and symbols. Familiarize yourself with the scope and the syntax. Live testing is the best way to learn. Good luck! πŸ™‚

Tutorial Math Collection API spec Download

Below is the code for JAVA, C# (the code for C# is almost identical) and C++. To copy the code, double-click inside the frame. Case 1: The square root √ Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
Expression e = new Expression("√2");

mXparser.consolePrintln("Res: " + e.getExpressionString() + " = " + e.calculate());
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
ExpressionPtr e = new_Expression("√2");

mXparser::consolePrintln("Res: " + e->getExpressionString() + " = " + e->calculate());
Code result
[mXparser-v.5.2.1] Res: √2 = 1.4142135623730951
Case 2: The square root of the square root √√ Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
Expression e = new Expression("√√16");

mXparser.consolePrintln("Res: " + e.getExpressionString() + " = " + e.calculate());
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
ExpressionPtr e = new_Expression("√√16");

mXparser::consolePrintln("Res: " + e->getExpressionString() + " = " + e->calculate());
Code result
[mXparser-v.5.2.1] Res: √√16 = 2.0
Case 3: The square root and parenthesis √() Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
Expression e = new Expression("√√(8+8)");

mXparser.consolePrintln("Res: " + e.getExpressionString() + " = " + e.calculate());
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
ExpressionPtr e = new_Expression("√√(8+8)");

mXparser::consolePrintln("Res: " + e->getExpressionString() + " = " + e->calculate());
Code result
[mXparser-v.5.2.1] Res: √√(8+8) = 2.0
Case 4: The roots of various orders ∜ βˆ› √ Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
Expression e = new Expression("∜16 + βˆ›27 + √16");

mXparser.consolePrintln("Res: " + e.getExpressionString() + " = " + e.calculate());
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
ExpressionPtr e = new_Expression("∜16 + βˆ›27 + √16");

mXparser::consolePrintln("Res: " + e->getExpressionString() + " = " + e->calculate());
Code result
[mXparser-v.5.2.1] Res: ∜16 + βˆ›27 + √16 = 9.0
Case 5: SIGMA summation operator βˆ‘ Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
Expression e = new Expression("βˆ‘(i, 1, 5, i^2)");

mXparser.consolePrintln("Res: " + e.getExpressionString() + " = " + e.calculate());
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
ExpressionPtr e = new_Expression("βˆ‘(i, 1, 5, i^2)");

mXparser::consolePrintln("Res: " + e->getExpressionString() + " = " + e->calculate());
Code result
[mXparser-v.5.2.1] Res: βˆ‘(i, 1, 5, i^2) = 55.0
Case 6: Unicode name of a user defined argument Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
Argument a = new Argument("Ξ± = 2Ο€");
Argument b = new Argument("Ξ² = Ο€/2");

Expression e = new Expression("sin(Ξ±) + cos(Ξ²)", a, b);

mXparser.consolePrintln("Res: " + e.getExpressionString() + " = " + e.calculate());
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
ArgumentPtr a = new_Argument("Ξ± = 2Ο€");
ArgumentPtr b = new_Argument("Ξ² = Ο€/2");

ExpressionPtr e = new_Expression("sin(Ξ±) + cos(Ξ²)", a, b);

mXparser::consolePrintln("Res: " + e->getExpressionString() + " = " + e->calculate());
Code result
[mXparser-v.5.2.1] Res: sin(Ξ±) + cos(Ξ²) = 0.0
Case 7: Show all Unicode built-in keywords Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
mXparser.consolePrintHelp("unicode");
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
mXparser::consolePrintHelp("unicode");
Code result
[mXparser-v.5.2.1] Help content limited to query: 'unicode'
  #  Keyword             Type                    Syntax                                        Since Description
  -  --------            ----                    ------                                        ----- -----------
  1. Γ—                   <Operator>              a Γ— b                                         5.0   Multiplication - Operator - Unicode math symbol
  2. ⨉                   <Operator>              a ⨉ b                                         5.0   Multiplication - Operator - Unicode math symbol
  3. βˆ™                   <Operator>              a βˆ™ b                                         5.0   Multiplication - Operator - Unicode math symbol
  4. Γ·                   <Operator>              a Γ· b                                         5.0   Division - Operator - Unicode math symbol
  5. √                   <Operator>              √x                                            5.0   Square root - Operator - Unicode math symbol
  6. βˆ›                   <Operator>              βˆ›x                                            5.0   Cube root - Operator - Unicode math symbol
  7. ∜                   <Operator>              ∜x                                            5.0   Fourth root - Operator - Unicode math symbol
  8. ∧                   <Boolean operator>      p ∧ q                                         5.0   Logical conjunction AND - Boolean operator - Unicode math symbol
  9. ⊼                   <Boolean operator>      p ⊼ q                                         5.0   Sheffer stroke NAND - Boolean operator - Unicode math symbol
 10. ~∧                  <Boolean operator>      p ~∧ q                                        5.0   Sheffer stroke NAND - Boolean operator - Unicode math symbol
 11. Β¬&                  <Boolean operator>      p Β¬& q                                        5.0   Sheffer stroke NAND - Boolean operator - Unicode math symbol
 12. ¬∧                  <Boolean operator>      p ¬∧ q                                        5.0   Sheffer stroke NAND - Boolean operator - Unicode math symbol
 13. Β¬&&                 <Boolean operator>      p Β¬&& q                                       5.0   Sheffer stroke NAND - Boolean operator - Unicode math symbol
 14. Β¬/\                 <Boolean operator>      p Β¬/\ q                                       5.0   Sheffer stroke NAND - Boolean operator - Unicode math symbol
 15. ∨                   <Boolean operator>      p ∨ q                                         5.0   Logical disjunction OR - Boolean operator - Unicode math symbol
 16. ⊽                   <Boolean operator>      p ⊽ q                                         5.0   Logical not or (joint denial) NOR - Boolean operator - Unicode math symbol
 17. ~∨                  <Boolean operator>      p ~∨ q                                        5.0   Logical not or (joint denial) NOR - Boolean operator - Unicode math symbol
 18. Β¬|                  <Boolean operator>      p Β¬| q                                        5.0   Logical not or (joint denial) NOR - Boolean operator - Unicode math symbol
 19. ¬∨                  <Boolean operator>      p ¬∨ q                                        5.0   Logical not or (joint denial) NOR - Boolean operator - Unicode math symbol
 20. Β¬||                 <Boolean operator>      p Β¬|| q                                       5.0   Logical not or (joint denial) NOR - Boolean operator - Unicode math symbol
 21. Β¬\/                 <Boolean operator>      p Β¬\/ q                                       5.0   Logical not or (joint denial) NOR - Boolean operator - Unicode math symbol
 22. ⊻                   <Boolean operator>      p ⊻ q                                         5.0   Exclusive or XOR - Boolean operator - Unicode math symbol
 23. β‡’                   <Boolean operator>      p β‡’ q                                         5.0   Implication IMP - Boolean operator - Unicode math symbol
 24. ⇐                   <Boolean operator>      p ⇐ q                                         5.0   Converse implication CIMP - Boolean operator - Unicode math symbol
 25. ⇏                   <Boolean operator>      p ⇏ q                                         5.0   Material nonimplication NIMP - Boolean operator - Unicode math symbol
 26. ⇍                   <Boolean operator>      p ⇍ q                                         5.0   Converse nonimplication CNIMP - Boolean operator - Unicode math symbol
 27. ⇔                   <Boolean operator>      p ⇔ q                                         5.0   Logical biconditional EQV - Boolean operator - Unicode math symbol
 28. Β¬                   <Boolean operator>      Β¬p                                            5.0   Negation - Boolean operator - Unicode math symbol
 29. β‰                    <Binary relation>       a β‰  b                                         5.0   Inequation - Binary relation - Unicode math symbol
 30. ≀                   <Binary relation>       a ≀ b                                         5.0   Lower or equal - Binary relation - Unicode math symbol
 31. β‹œ                   <Binary relation>       a β‹œ b                                         5.0   Lower or equal - Binary relation - Unicode math symbol
 32. β‰₯                   <Binary relation>       a β‰₯ b                                         5.0   Greater or equal - Binary relation - Unicode math symbol
 33. ⋝                   <Binary relation>       a ⋝ b                                         5.0   Greater or equal - Binary relation - Unicode math symbol
 34. βˆ‘                   <Calculus operator>     βˆ‘(i, from, to, expr, <by>)                    5.0   Summation SIGMA - Iterated operator Ξ£ - Calculus operator - Unicode math symbol
 35. Ξ£                   <Calculus operator>     Ξ£(i, from, to, expr, <by>)                    5.0   Summation SIGMA - Iterated operator Ξ£ - Calculus operator - Unicode math symbol
 36. ∏                   <Calculus operator>     ∏(i, from, to, expr, <by>)                    5.0   Product PI - Iterated operator ∏ - Calculus operator - Unicode math symbol
 37. β„Ώ                   <Calculus operator>     β„Ώ(i, from, to, expr, <by>)                    5.0   Product PI - Iterated operator ∏ - Calculus operator - Unicode math symbol
 38. Π                   <Calculus operator>     Π(i, from, to, expr, <by>)                    5.0   Product PI - Iterated operator ∏ - Calculus operator - Unicode math symbol
 39. ∫                   <Calculus operator>     ∫(expr, arg, from, to)                        5.0   Definite integral ∫ - Calculus operator - Unicode math symbol
 40. βˆ‚                   <Calculus operator>     βˆ‚(expr, arg, <point>)                         5.0   Derivative βˆ‚ - Calculus operator - Unicode math symbol
 41. βˆ‚-                  <Calculus operator>     βˆ‚-(expr, arg, <point>)                        5.0   Left derivative βˆ‚- - Calculus operator - Unicode math symbol
 42. βˆ‚+                  <Calculus operator>     βˆ‚+(expr, arg, <point>)                        5.0   Right derivative βˆ‚+ - Calculus operator - Unicode math symbol
 43. βˆ†                   <Calculus operator>     βˆ†(expr, arg, <delta>)                         5.0   Forward difference βˆ† - Calculus operator - Unicode math symbol
 44. Ξ”                   <Calculus operator>     Ξ”(expr, arg, <delta>)                         5.0   Forward difference βˆ† - Calculus operator - Unicode math symbol
 45. βˆ‡                   <Calculus operator>     βˆ‡(expr, arg, <delta>)                         5.0   Backward difference βˆ‡ - Calculus operator - Unicode math symbol
 46. Ο€                   <Constant value>        Ο€                                             5.0   Pi, Archimedes' or Ludolph's number - Mathematical constant Ο€ - Constant value - Unicode math symbol
 47. β„Ό                   <Constant value>        β„Ό                                             5.0   Pi, Archimedes' or Ludolph's number - Mathematical constant Ο€ - Constant value - Unicode math symbol
 48. β„―                   <Constant value>        β„―                                             5.0   Napier's or Euler's number (base of Natural logarithm) - Mathematical constant e - Constant value - Unicode math symbol
 49. β…‡                   <Constant value>        β…‡                                             5.0   Napier's or Euler's number (base of Natural logarithm) - Mathematical constant e - Constant value - Unicode math symbol
[mXparser-v.5.2.1] 
Case 8: Enable / disable Unicode built-in keywords Java/C# code
// JAVA: import org.mariuszgromada.math.mxparser.*;
// C#: using org.mariuszgromada.math.mxparser;
// ...
mXparser.disableUnicodeBuiltinKeyWordsMode();
mXparser.consolePrintHelp("unicode");
C++ code
#include "org/mariuszgromada/math/mxparser.hpp"
// ...
mXparser::disableUnicodeBuiltinKeyWordsMode();
mXparser::consolePrintHelp("unicode");
Code result
[mXparser-v.5.2.1] Help content limited to query: 'unicode'
  #  Keyword             Type                    Syntax                                        Since Description
  -  --------            ----                    ------                                        ----- -----------
[mXparser-v.5.2.1] 
List of Unicode symbols that grammar accepts
"Ξ±" = "\u03b1": can be used as var name
"Ξ²" = "\u03b2": can be used as var name
"Ξ³" = "\u03b3": can be used as var name
"Ξ΄" = "\u03b4": can be used as var name
"Ξ΅" = "\u03b5": can be used as var name
"ΞΆ" = "\u03b6": can be used as var name
"Ξ·" = "\u03b7": can be used as var name
"ΞΈ" = "\u03b8": can be used as var name
"ΞΉ" = "\u03b9": can be used as var name
"ΞΊ" = "\u03ba": can be used as var name
"Ξ»" = "\u03bb": can be used as var name
"ΞΌ" = "\u03bc": can be used as var name
"Ξ½" = "\u03bd": can be used as var name
"ΞΎ" = "\u03be": can be used as var name
"ΞΏ" = "\u03bf": can be used as var name
"Ο€" = "\u03c0": pi constant
"ρ" = "\u03c1": can be used as var name
"Ο‚" = "\u03c2": can be used as var name
"Οƒ" = "\u03c3": can be used as var name
"Ο„" = "\u03c4": can be used as var name
"Ο…" = "\u03c5": can be used as var name
"Ο†" = "\u03c6": can be used as var name
"Ο‡" = "\u03c7": can be used as var name
"ψ" = "\u03c8": can be used as var name
"Ο‰" = "\u03c9": can be used as var name
"Ξ‘" = "\u0391": can be used as var name
"Ξ’" = "\u0392": can be used as var name
"Ξ“" = "\u0393": can be used as var name
"Ξ”" = "\u0394": Forward difference operator
"Ξ•" = "\u0395": can be used as var name
"Ξ–" = "\u0396": can be used as var name
"Ξ—" = "\u0397": can be used as var name
"Θ" = "\u0398": can be used as var name
"Ξ™" = "\u0399": can be used as var name
"Κ" = "\u039a": can be used as var name
"Ξ›" = "\u039b": can be used as var name
"Μ" = "\u039c": can be used as var name
"Ν" = "\u039d": can be used as var name
"Ξ" = "\u039e": can be used as var name
"Ο" = "\u039f": can be used as var name
"Ξ " = "\u03a0": Product operator - PI
"Ξ‘" = "\u03a1": can be used as var name
"Ξ£" = "\u03a3": Summation operator - SIGMA
"Ξ€" = "\u03a4": can be used as var name
"Ξ₯" = "\u03a5": can be used as var name
"Ξ¦" = "\u03a6": can be used as var name
"Ξ§" = "\u03a7": can be used as var name
"Ξ¨" = "\u03a8": can be used as var name
"Ξ©" = "\u03a9": can be used as var name
"βˆ‘" = "\u2211": Summation operator - SIGMA
"∏" = "\u220f": Product operator - PI
"β„Ώ" = "\u213f": Product operator - PI
"βˆ†" = "\u2206": Forward difference operator
"βˆ‡" = "\u2207": Backward difference operator
"∫" = "\u222b": Definite integral operator
"β„Ό" = "\u213c": pi constant
"ℇ" = "\u2107": can be used as var name
"β…‡" = "\u2147": Napier's constant, or Euler's number, base of Natural logarithm
"β„―" = "\u212f": Napier's constant, or Euler's number, base of Natural logarithm
"∜" = "\u221c": Fourth root function represented as unary left operator
"βˆ›" = "\u221b": Cube root function represented as unary left operator
"√" = "\u221a": Square root function represented as unary left operator
"βˆ‚" = "\u2202": Derivative operator
"⊻" = "\u22bb": Exclusive or (XOR)
"⊽" = "\u22bd": Logical NOR
"⊼" = "\u22bc": NAND - Sheffer stroke
"⇔" = "\u21d4": Logical biconditional (EQV)
"⇍" = "\u21cd": Converse nonimplication (CNIMP)
"⇏" = "\u21cf": Material nonimplication (NIMP)
"⇐" = "\u21d0": Converse implication (CIMP)
"β‡’" = "\u21d2": Implication (IMP)
"Β¬" = "\u00ac": Negation
"∧" = "\u2227": And
"∨" = "\u2228": Or
"⋝" = "\u22dd": Greater or equal
"β‰₯" = "\u2265": Greater or equal
"β‹œ" = "\u22dc": Lower or equal
"≀" = "\u2264": Lower or equal
"β‰ " = "\u2260": Inequation
"Γ·" = "\u00f7": Division
"βˆ™" = "\u2219": Multiplication
"⨉" = "\u2a09": Multiplication
"Γ—" = "\u00d7": Multiplication
Nuget – Package Manager (C#, F#, Visual Basic, …)

Install-Package MathParser.org-mXparser -Version 6.1.0

Nuget – .NET CLI

dotnet add package MathParser.org-mXparser --version 6.1.0

Nuget – Package Reference

<PackageReference Include="MathParser.org-mXparser" Version="6.1.0"/>

Maven – Dependency (Java, Kotlin, Scala, Groovy, …)

<dependency>
<groupid>
org.mariuszgromada.math</groupid>
<artifactid>
MathParser.org-mXparser</artifactid>
<version>
6.1.0</version>
</dependency>

Maven – Gradle

implementation 'org.mariuszgromada.math:MathParser.org-mXparser:6.1.0'

CMake – Dependency / FetchContent (C++, MSVC, LLVM/Clang, GNU/GCC, MinGW, MSYS2, WSL, Windows, Linux, Unix, MacOS)

include(FetchContent)
FetchContent_Declare(
MathParserOrgMxParser
GIT_REPOSITORY
https://github.com/mariuszgromada/MathParser.org-mXparser.git
GIT_TAG
v.6.1.0
SOURCE_SUBDIR CURRENT/cpp/lib
)
FetchContent_MakeAvailable(
MathParserOrgMxParser)
target_link_libraries(YourExecutable
MathParserOrgMxParser)

GitHub

git clone https://github.com/mariuszgromada/MathParser.org-mXparser

OTHER DOWNLOAD OPTIONS

Download latest release – v.6.1.0 Sagitara: .NET bin onlyDownload latest release – v.6.1.0 Sagitara: JAVA bin onlyDownload latest release – v.6.1.0 Sagitara: bin + doc

NEWS FROM MATHPARSER.ORG SOURCE CODE

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

My other creative spaces DONATION

Did you find the software useful?

Please consider donation πŸ™‚

DONATE

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4