LaTeX to CAS translator
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 \frac{1}{2} \int_{-1}^1 P_{l_1}(x) P_{l_2}(x) P_{l}(x) \, dx = \begin{pmatrix} l & l_1 & l_2 \\ 0 & 0 & 0 \end{pmatrix}^2, }
... is translated to the CAS output ...
Semantic latex: \frac{1}{2} \int_{-1}^1 \LegendrepolyP{l_1}@{x} \LegendrepolyP{l_2}@{x} \LegendrepolyP{l}@{x} dx = \begin{pmatrix} l & l_1 & l_2 \\ 0 & 0 & 0 \end{pmatrix}^2 ,
Confidence: 0.67814962762282
Mathematica
Translation:
Information
Symbol info
- (LaTeX -> Mathematica) The input LaTeX is invalid: Unable to retrieve free variables for limit expression.
Tests
Symbolic
Numeric
SymPy
Translation:
Information
Symbol info
- (LaTeX -> SymPy) No translation possible for given token: Cannot extract information from feature set: \LegendrepolyP [\LegendrepolyP]
Tests
Symbolic
Numeric
Maple
Translation:
Information
Symbol info
- (LaTeX -> Maple) The input LaTeX is invalid: Unable to retrieve free variables for limit expression.
Tests
Symbolic
Numeric
Dependency Graph Information
Includes
Complete translation information:
{
"id" : "FORMULA_8832ce832c717ebd542de886c9f50298",
"formula" : "\\frac{1}{2} \\int_{-1}^1 P_{l_1}(x) P_{l_2}(x) P_{l}(x) dx = \n\\begin{pmatrix}\n l & l_1 & l_2 \\\\\n 0 & 0 & 0\n\\end{pmatrix}^2,",
"semanticFormula" : "\\frac{1}{2} \\int_{-1}^1 \\LegendrepolyP{l_1}@{x} \\LegendrepolyP{l_2}@{x} \\LegendrepolyP{l}@{x} dx = \\begin{pmatrix}\n l & l_1 & l_2 \\\\\n 0 & 0 & 0\n\\end{pmatrix}^2 ,",
"confidence" : 0.6781496276228178,
"translations" : {
"Mathematica" : {
"translation" : "",
"translationInformation" : {
"tokenTranslations" : {
"Error" : "(LaTeX -> Mathematica) The input LaTeX is invalid: Unable to retrieve free variables for limit expression."
}
},
"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: \\LegendrepolyP [\\LegendrepolyP]"
}
},
"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" : "",
"translationInformation" : {
"tokenTranslations" : {
"Error" : "(LaTeX -> Maple) The input LaTeX is invalid: Unable to retrieve free variables for limit expression."
}
},
"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" : [ "\\frac{1}{2} \\int_{-1}^1 P_{l_1}(x) P_{l_2}(x) P_{l}(x) \\, dx = \\begin{pmatrix} l & l_1 & l_2 \\\\ 0 & 0 & 0\\end{pmatrix}^2", "l_2", "P", "l_1" ],
"isPartOf" : [ ],
"definiens" : [ ]
}