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 (q)_n}

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

Semantic latex: \Pochhammersym{q}{n}

Confidence: 0.90733333333333

Mathematica

Translation: Pochhammer[q, n]

Information

Sub Equations

  • Pochhammer[q, n]

Free variables

  • n
  • q

Symbol info

  • Pochhammer symbol; Example: \Pochhammersym{a}{n}

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

Tests

Symbolic
Numeric

SymPy

Translation:

Information

Symbol info

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

Tests

Symbolic
Numeric

Maple

Translation: pochhammer(q, n)

Information

Sub Equations

  • pochhammer(q, n)

Free variables

  • n
  • q

Symbol info

  • Pochhammer symbol; Example: \Pochhammersym{a}{n}

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

Tests

Symbolic
Numeric

Dependency Graph Information

Is part of

Description

  • double series
  • Pochhammer symbol
  • series
  • Appell series
  • function
  • A system
  • Appell
  • definition
  • partial differential equation
  • solution
  • system
  • derivative
  • derivative result from the definition
  • system of differential equation
  • system of second-order differential equation

Complete translation information:

{
  "id" : "FORMULA_a522b876590f6e9f2fa229ee885e4acb",
  "formula" : "(q)_n",
  "semanticFormula" : "\\Pochhammersym{q}{n}",
  "confidence" : 0.9073333333333333,
  "translations" : {
    "Mathematica" : {
      "translation" : "Pochhammer[q, n]",
      "translationInformation" : {
        "subEquations" : [ "Pochhammer[q, n]" ],
        "freeVariables" : [ "n", "q" ],
        "tokenTranslations" : {
          "\\Pochhammersym" : "Pochhammer symbol; Example: \\Pochhammersym{a}{n}\nWill be translated to: Pochhammer[$0, $1]\nRelevant links to definitions:\nDLMF:         http://dlmf.nist.gov/5.2#iii\nMathematica:  https://reference.wolfram.com/language/ref/Pochhammer.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: \\Pochhammersym [\\Pochhammersym]"
        }
      },
      "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" : "pochhammer(q, n)",
      "translationInformation" : {
        "subEquations" : [ "pochhammer(q, n)" ],
        "freeVariables" : [ "n", "q" ],
        "tokenTranslations" : {
          "\\Pochhammersym" : "Pochhammer symbol; Example: \\Pochhammersym{a}{n}\nWill be translated to: pochhammer($0, $1)\nRelevant links to definitions:\nDLMF:  http://dlmf.nist.gov/5.2#iii\nMaple: https://www.maplesoft.com/support/help/maple/view.aspx?path=pochhammer"
        }
      },
      "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" : 1,
    "sentence" : 0,
    "word" : 16
  } ],
  "includes" : [ ],
  "isPartOf" : [ "F_1(a,b_1,b_2;c;x,y) = \\sum_{m,n=0}^\\infty \\frac{(a)_{m+n} (b_1)_m (b_2)_n} {(c)_{m+n} \\,m! \\,n!} \\,x^m y^n", "F_2(a,b_1,b_2;c_1,c_2;x,y) = \\sum_{m,n=0}^\\infty \\frac{(a)_{m+n} (b_1)_m (b_2)_n} {(c_1)_m (c_2)_n \\,m! \\,n!} \\,x^m y^n", "F_3(a_1,a_2,b_1,b_2;c;x,y) = \\sum_{m,n=0}^\\infty \\frac{(a_1)_m (a_2)_n (b_1)_m (b_2)_n} {(c)_{m+n} \\,m! \\,n!} \\,x^m y^n", "F_4(a,b;c_1,c_2;x,y) = \\sum_{m,n=0}^\\infty \\frac{(a)_{m+n} (b)_{m+n}} {(c_1)_m (c_2)_n \\,m! \\,n!} \\,x^m y^n", "\\frac {\\partial^n} {\\partial x^n} F_1(a,b_1,b_2,c; x,y) = \\frac {\\left(a\\right)_n \\left(b_1\\right)_n} {\\left(c\\right)_n} F_1(a+n,b_1+n,b_2,c+n; x,y)", "\\frac {\\partial^n} {\\partial y^n} F_1(a,b_1,b_2,c; x,y) = \\frac {\\left(a\\right)_n \\left(b_2\\right)_n} {\\left(c\\right)_n} F_1(a+n,b_1,b_2+n,c+n; x,y)" ],
  "definiens" : [ {
    "definition" : "double series",
    "score" : 0.7861085151706015
  }, {
    "definition" : "Pochhammer symbol",
    "score" : 0.722
  }, {
    "definition" : "series",
    "score" : 0.7037873237320742
  }, {
    "definition" : "Appell series",
    "score" : 0.6629879847031728
  }, {
    "definition" : "function",
    "score" : 0.6621997121168637
  }, {
    "definition" : "A system",
    "score" : 0.4063630428911055
  }, {
    "definition" : "Appell",
    "score" : 0.4063630428911055
  }, {
    "definition" : "definition",
    "score" : 0.4063630428911055
  }, {
    "definition" : "partial differential equation",
    "score" : 0.4063630428911055
  }, {
    "definition" : "solution",
    "score" : 0.4063630428911055
  }, {
    "definition" : "system",
    "score" : 0.4063630428911055
  }, {
    "definition" : "derivative",
    "score" : 0.319333892799869
  }, {
    "definition" : "derivative result from the definition",
    "score" : 0.319333892799869
  }, {
    "definition" : "system of differential equation",
    "score" : 0.319333892799869
  }, {
    "definition" : "system of second-order differential equation",
    "score" : 0.319333892799869
  } ]
}

Specify your own input