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 c_n(q^{-x};a;q) = {}_2\phi_1(q^{-n},q^{-x};0;q,-q^{n+1}/a)}

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

Semantic latex: c_n(q^{-x};a;q) = {}_2\phi_1(q^{-n},q^{-x};0;q,-q^{n+1}/a)

Confidence: 0

Mathematica

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

Information

Sub Equations

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

Free variables

  • Subscript[\[Phi], 1]
  • a
  • 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('{c}_{n}')((q)**(- x); a ; q) == Symbol('{}_{2}')*Symbol('{Symbol('phi')}_{1}')((q)**(- n), (q)**(- x); 0 ; q , - (q)**(n + 1)/a)

Information

Sub Equations

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

Free variables

  • Symbol('{Symbol('phi')}_{1}')
  • a
  • 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: c[n]((q)^(- x); a ; q) = [2]*phi[1]((q)^(- n), (q)^(- x); 0 ; q , - (q)^(n + 1)/a)

Information

Sub Equations

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

Free variables

  • a
  • n
  • phi[1]
  • 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}}
  • Failed to parse (syntax error): {\displaystyle +1} /}

Is part of

Complete translation information:

{
  "id" : "FORMULA_738d8499ee4772023bda6917eb9a2ba2",
  "formula" : "c_n(q^{-x};a;q) = {}_2\\phi_1(q^{-n},q^{-x};0;q,-q^{n+1}/a)",
  "semanticFormula" : "c_n(q^{-x};a;q) = {}_2\\phi_1(q^{-n},q^{-x};0;q,-q^{n+1}/a)",
  "confidence" : 0.0,
  "translations" : {
    "Mathematica" : {
      "translation" : "Subscript[c, n][(q)^(- x); a ; q] == Subscript[, 2]*Subscript[\\[Phi], 1][(q)^(- n), (q)^(- x); 0 ; q , - (q)^(n + 1)/a]",
      "translationInformation" : {
        "subEquations" : [ "Subscript[c, n][(q)^(- x); a ; q] = Subscript[, 2]*Subscript[\\[Phi], 1][(q)^(- n), (q)^(- x); 0 ; q , - (q)^(n + 1)/a]" ],
        "freeVariables" : [ "Subscript[\\[Phi], 1]", "a", "n", "q", "x" ],
        "tokenTranslations" : {
          "\\phi" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary).",
          "c" : "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('{c}_{n}')((q)**(- x); a ; q) == Symbol('{}_{2}')*Symbol('{Symbol('phi')}_{1}')((q)**(- n), (q)**(- x); 0 ; q , - (q)**(n + 1)/a)",
      "translationInformation" : {
        "subEquations" : [ "Symbol('{c}_{n}')((q)**(- x); a ; q) = Symbol('{}_{2}')*Symbol('{Symbol('phi')}_{1}')((q)**(- n), (q)**(- x); 0 ; q , - (q)**(n + 1)/a)" ],
        "freeVariables" : [ "Symbol('{Symbol('phi')}_{1}')", "a", "n", "q", "x" ],
        "tokenTranslations" : {
          "\\phi" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary).",
          "c" : "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" : "c[n]((q)^(- x); a ; q) = [2]*phi[1]((q)^(- n), (q)^(- x); 0 ; q , - (q)^(n + 1)/a)",
      "translationInformation" : {
        "subEquations" : [ "c[n]((q)^(- x); a ; q) = [2]*phi[1]((q)^(- n), (q)^(- x); 0 ; q , - (q)^(n + 1)/a)" ],
        "freeVariables" : [ "a", "n", "phi[1]", "q", "x" ],
        "tokenTranslations" : {
          "\\phi" : "Function without DLMF-Definition. We keep it like it is (but delete prefix \\ if necessary).",
          "c" : "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}", "+1} /", "\\displaystyle c_n(q^{-x};a;q) = {}_2\\phi_1(q^{-n},q^{-x};0;q,-q^{n+1}/a)" ],
  "isPartOf" : [ "\\displaystyle c_n(q^{-x};a;q) = {}_2\\phi_1(q^{-n},q^{-x};0;q,-q^{n+1}/a)" ],
  "definiens" : [ ]
}

Specify your own input