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 \displaystyle P_n(x;a,b,c;q)={}_3\phi_2(q^{-n},abq^{n+1},x;aq,cq;q,q)}

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

Semantic latex: P_n(x;a,b,c;q)={}_3\phi_2(q^{-n},abq^{n+1},x;aq,cq;q,q)

Confidence: 0

Mathematica

Translation: Subscript[P, n][x ; a , b , c ; q] == Subscript[, 3]*Subscript[\[Phi], 2][(q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q]

Information

Sub Equations

  • Subscript[P, n][x ; a , b , c ; q] = Subscript[, 3]*Subscript[\[Phi], 2][(q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q]

Free variables

  • Subscript[\[Phi], 2]
  • a
  • b
  • c
  • n
  • q
  • x

Symbol info

  • Function without DLMF-Definition. We keep it like it is (but delete prefix \ if necessary).
  • Function without DLMF-Definition. We keep it like it is (but delete prefix \ if necessary).

Tests

Symbolic
Numeric

SymPy

Translation: Symbol('{P}_{n}')(x ; a , b , c ; q) == Symbol('{}_{3}')*Symbol('{Symbol('phi')}_{2}')((q)**(- n), a*b*(q)**(n + 1), x ; a*q , c*q ; q , q)

Information

Sub Equations

  • Symbol('{P}_{n}')(x ; a , b , c ; q) = Symbol('{}_{3}')*Symbol('{Symbol('phi')}_{2}')((q)**(- n), a*b*(q)**(n + 1), x ; a*q , c*q ; q , q)

Free variables

  • Symbol('{Symbol('phi')}_{2}')
  • a
  • b
  • c
  • n
  • q
  • x

Symbol info

  • Function without DLMF-Definition. We keep it like it is (but delete prefix \ if necessary).
  • Function without DLMF-Definition. We keep it like it is (but delete prefix \ if necessary).

Tests

Symbolic
Numeric

Maple

Translation: P[n](x ; a , b , c ; q) = [3]*phi[2]((q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q)

Information

Sub Equations

  • P[n](x ; a , b , c ; q) = [3]*phi[2]((q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q)

Free variables

  • a
  • b
  • c
  • n
  • phi[2]
  • q
  • x

Symbol info

  • Function without DLMF-Definition. We keep it like it is (but delete prefix \ if necessary).
  • Function without DLMF-Definition. We keep it like it is (but delete prefix \ if necessary).

Tests

Symbolic
Numeric

Dependency Graph Information

Includes

  • Failed to parse (syntax error): {\displaystyle ^}
  • Failed to parse (syntax error): {\displaystyle +1}}

Is part of

Complete translation information:

{
  "id" : "FORMULA_e37401d2a6d574ba7a34422045b83ff5",
  "formula" : "P_n(x;a,b,c;q)={}_3\\phi_2(q^{-n},abq^{n+1},x;aq,cq;q,q)",
  "semanticFormula" : "P_n(x;a,b,c;q)={}_3\\phi_2(q^{-n},abq^{n+1},x;aq,cq;q,q)",
  "confidence" : 0.0,
  "translations" : {
    "Mathematica" : {
      "translation" : "Subscript[P, n][x ; a , b , c ; q] == Subscript[, 3]*Subscript[\\[Phi], 2][(q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q]",
      "translationInformation" : {
        "subEquations" : [ "Subscript[P, n][x ; a , b , c ; q] = Subscript[, 3]*Subscript[\\[Phi], 2][(q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q]" ],
        "freeVariables" : [ "Subscript[\\[Phi], 2]", "a", "b", "c", "n", "q", "x" ],
        "tokenTranslations" : {
          "P" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary).",
          "\\phi" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary)."
        }
      },
      "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" : "Symbol('{P}_{n}')(x ; a , b , c ; q) == Symbol('{}_{3}')*Symbol('{Symbol('phi')}_{2}')((q)**(- n), a*b*(q)**(n + 1), x ; a*q , c*q ; q , q)",
      "translationInformation" : {
        "subEquations" : [ "Symbol('{P}_{n}')(x ; a , b , c ; q) = Symbol('{}_{3}')*Symbol('{Symbol('phi')}_{2}')((q)**(- n), a*b*(q)**(n + 1), x ; a*q , c*q ; q , q)" ],
        "freeVariables" : [ "Symbol('{Symbol('phi')}_{2}')", "a", "b", "c", "n", "q", "x" ],
        "tokenTranslations" : {
          "P" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary).",
          "\\phi" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary)."
        }
      },
      "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" : "P[n](x ; a , b , c ; q) = [3]*phi[2]((q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q)",
      "translationInformation" : {
        "subEquations" : [ "P[n](x ; a , b , c ; q) = [3]*phi[2]((q)^(- n), a*b*(q)^(n + 1), x ; a*q , c*q ; q , q)" ],
        "freeVariables" : [ "a", "b", "c", "n", "phi[2]", "q", "x" ],
        "tokenTranslations" : {
          "P" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary).",
          "\\phi" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary)."
        }
      },
      "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" : [ ],
  "includes" : [ "^", "+1}", "\\displaystyle   P_n(x;a,b,c;q)={}_3\\phi_2(q^{-n},abq^{n+1},x;aq,cq;q,q)" ],
  "isPartOf" : [ "\\displaystyle   P_n(x;a,b,c;q)={}_3\\phi_2(q^{-n},abq^{n+1},x;aq,cq;q,q)" ],
  "definiens" : [ ]
}

Specify your own input