LaTeX to CAS translator

Jump to navigation Jump to search

This mockup demonstrates the concept of TeX to Computer Algebra System (CAS) conversion.

The demo-application converts LaTeX functions which directly translate to CAS counterparts.

Functions without explicit CAS support are available for translation via a DRMF package (under development).

The following LaTeX input ...

{\displaystyle \operatorname{Li}_s(z)}

... is translated to the CAS output ...

Semantic latex: \polylog{s}@{z}

Confidence: 0.93338379873252

Mathematica

Translation: PolyLog[s, z]

Information

Sub Equations

  • PolyLog[s, z]

Free variables

  • s
  • z

Symbol info

  • Polylogarithm; Example: \polylog{s}@{z}

Will be translated to: PolyLog[$0, $1] Relevant links to definitions: DLMF: http://dlmf.nist.gov/25.12#E10 Mathematica: https://reference.wolfram.com/language/ref/PolyLog.html

Tests

Symbolic
Numeric

SymPy

Translation:

Information

Symbol info

  • (LaTeX -> SymPy) No translation possible for given token: Cannot extract information from feature set: \polylog [\polylog]

Tests

Symbolic
Numeric

Maple

Translation: polylog(s, z)

Information

Sub Equations

  • polylog(s, z)

Free variables

  • s
  • z

Symbol info

  • Polylogarithm; Example: \polylog{s}@{z}

Will be translated to: polylog($0, $1) Relevant links to definitions: DLMF: http://dlmf.nist.gov/25.12#E10 Maple: https://www.maplesoft.com/support/help/maple/view.aspx?path=polylog

Tests

Symbolic
Numeric

Dependency Graph Information

Includes

Is part of

Description

  • series
  • polylogarithm
  • special case
  • special case of the Lerch Zeta

Complete translation information:

{
  "id" : "FORMULA_1574f057e5a4de3b7b53627317967b49",
  "formula" : "\\operatorname{Li}_s(z)",
  "semanticFormula" : "\\polylog{s}@{z}",
  "confidence" : 0.9333837987325216,
  "translations" : {
    "Mathematica" : {
      "translation" : "PolyLog[s, z]",
      "translationInformation" : {
        "subEquations" : [ "PolyLog[s, z]" ],
        "freeVariables" : [ "s", "z" ],
        "tokenTranslations" : {
          "\\polylog" : "Polylogarithm; Example: \\polylog{s}@{z}\nWill be translated to: PolyLog[$0, $1]\nRelevant links to definitions:\nDLMF:         http://dlmf.nist.gov/25.12#E10\nMathematica:  https://reference.wolfram.com/language/ref/PolyLog.html"
        }
      },
      "numericResults" : {
        "overallResult" : "SKIPPED",
        "numberOfTests" : 0,
        "numberOfFailedTests" : 0,
        "numberOfSuccessfulTests" : 0,
        "numberOfSkippedTests" : 0,
        "numberOfErrorTests" : 0,
        "wasAborted" : false,
        "crashed" : false,
        "testCalculationsGroups" : [ ]
      },
      "symbolicResults" : {
        "overallResult" : "SKIPPED",
        "numberOfTests" : 0,
        "numberOfFailedTests" : 0,
        "numberOfSuccessfulTests" : 0,
        "numberOfSkippedTests" : 0,
        "numberOfErrorTests" : 0,
        "crashed" : false,
        "testCalculationsGroup" : [ ]
      }
    },
    "SymPy" : {
      "translation" : "",
      "translationInformation" : {
        "tokenTranslations" : {
          "Error" : "(LaTeX -> SymPy) No translation possible for given token: Cannot extract information from feature set: \\polylog [\\polylog]"
        }
      },
      "numericResults" : {
        "overallResult" : "SKIPPED",
        "numberOfTests" : 0,
        "numberOfFailedTests" : 0,
        "numberOfSuccessfulTests" : 0,
        "numberOfSkippedTests" : 0,
        "numberOfErrorTests" : 0,
        "wasAborted" : false,
        "crashed" : false,
        "testCalculationsGroups" : [ ]
      },
      "symbolicResults" : {
        "overallResult" : "SKIPPED",
        "numberOfTests" : 0,
        "numberOfFailedTests" : 0,
        "numberOfSuccessfulTests" : 0,
        "numberOfSkippedTests" : 0,
        "numberOfErrorTests" : 0,
        "crashed" : false,
        "testCalculationsGroup" : [ ]
      }
    },
    "Maple" : {
      "translation" : "polylog(s, z)",
      "translationInformation" : {
        "subEquations" : [ "polylog(s, z)" ],
        "freeVariables" : [ "s", "z" ],
        "tokenTranslations" : {
          "\\polylog" : "Polylogarithm; Example: \\polylog{s}@{z}\nWill be translated to: polylog($0, $1)\nRelevant links to definitions:\nDLMF:  http://dlmf.nist.gov/25.12#E10\nMaple: https://www.maplesoft.com/support/help/maple/view.aspx?path=polylog"
        }
      },
      "numericResults" : {
        "overallResult" : "SKIPPED",
        "numberOfTests" : 0,
        "numberOfFailedTests" : 0,
        "numberOfSuccessfulTests" : 0,
        "numberOfSkippedTests" : 0,
        "numberOfErrorTests" : 0,
        "wasAborted" : false,
        "crashed" : false,
        "testCalculationsGroups" : [ ]
      },
      "symbolicResults" : {
        "overallResult" : "SKIPPED",
        "numberOfTests" : 0,
        "numberOfFailedTests" : 0,
        "numberOfSuccessfulTests" : 0,
        "numberOfSkippedTests" : 0,
        "numberOfErrorTests" : 0,
        "crashed" : false,
        "testCalculationsGroup" : [ ]
      }
    }
  },
  "positions" : [ {
    "section" : 5,
    "sentence" : 7,
    "word" : 19
  } ],
  "includes" : [ "z", "s", "\\mathrm{Li}_n(z)" ],
  "isPartOf" : [ "\\Phi(z,s,a)=\\frac{1}{a^s}+\\sum_{m=0}^\\infty (1-m-s)_m \\operatorname{Li}_{s+m}(z)\\frac{a^m}{m!}; |a|<1", "\\,\\textrm{Li}_s(z)=z\\Phi(z,s,1)", "\\Phi(z,s,a)=\\sum_{k=0}^n \\frac{z^k}{(a+k)^s}+z^n\\sum_{m=0}^\\infty (1-m-s)_{m}\\operatorname{Li}_{s+m}(z)\\frac{(a+n)^m}{m!};\\ a\\rightarrow-n", "\\Phi(z,s,a) - \\frac{\\mathrm{Li}_{s}(z)}{z^{a}}=\\sum_{n=0}^{N-1}C_{n}(z,a) \\frac{(s)_{n}}{a^{n+s}}+O\\left( (\\Re a)^{1-N-s}+a z^{-\\Re a} \\right)" ],
  "definiens" : [ {
    "definition" : "series",
    "score" : 0.8786935335285544
  }, {
    "definition" : "polylogarithm",
    "score" : 0.8001513961975653
  }, {
    "definition" : "special case",
    "score" : 0.6687181434333315
  }, {
    "definition" : "special case of the Lerch Zeta",
    "score" : 0.35159851143248233
  } ]
}

Specify your own input