Moodle 2 and the future of the Algebra Filter

As has been repeatedly noted, the current Algebra filter is simply a retrofit if you will of the webworks parser and though I have sought feedback in the past, it appears that it simply affords a tex subset.

The question is why it should exist as a separate filter if it simply provide a tex subset. It would seem that providing the ability to read the previously employed tokens to a replacement, that Moodle 2 can be further realigned (i.e. we can continue to parse tex using the @ without having to use the algebra filter.

One option I have noted elsewhere is to replace the webworks parser with latexml (see, http://dlmf.nist.gov/LaTeXML/ ) , which is also perl and provides full tex to mathml. One could employ the @ with latexml and the $ with the tex filter and that way natively support mathml in Moodle. This would provide tex via dvi using $, tex via mathml using @ and potentially both via asciimathml if you want to be able to provide students (and teachers) with the ability to write text expressions in asciimath and use the svg features that have been incorporated there....

There are a number of obvious issues in looking at such a change: 1) does algebra filter usage actually deviate somehow from tex usage, 2) to what degree is the state of latexml potentially inadequate for Moodle usage, 3) would licensing present any issues (latexml was developed by folk at NIST, 4) would we be better off simply dropping the algebra filter and including the @ token in the tex filter as a step towards deprecation?

The question is why it should exist as a separate filter if it simply provide a tex subset. It would seem that providing the ability to read the previously employed tokens to a replacement, that Moodle 2 can be further realigned (i.e. we can continue to parse tex using the @ without having to use the algebra filter.

One option I have noted elsewhere is to replace the webworks parser with latexml (see, http://dlmf.nist.gov/LaTeXML/ ) , which is also perl and provides full tex to mathml. One could employ the @ with latexml and the $ with the tex filter and that way natively support mathml in Moodle. This would provide tex via dvi using $, tex via mathml using @ and potentially both via asciimathml if you want to be able to provide students (and teachers) with the ability to write text expressions in asciimath and use the svg features that have been incorporated there....

There are a number of obvious issues in looking at such a change: 1) does algebra filter usage actually deviate somehow from tex usage, 2) to what degree is the state of latexml potentially inadequate for Moodle usage, 3) would licensing present any issues (latexml was developed by folk at NIST, 4) would we be better off simply dropping the algebra filter and including the @ token in the tex filter as a step towards deprecation?

Text Expression Syntax

Based on Christina's post I searched Webworks and found these two links for using webworks text expressions (the first one is arguably replaced by the second):

Is this a subset of a more widely known syntax? Can other systems provide competent parsing of the syntax more economically (for example, can this also be parsed by asciimathml for example)? How did the webworks system decide upon this system and to what extent will webworks remain with such syntax?

- http://webwork.math.rochester.edu/docs/docs/pglanguage/availableFunctions.html
- http://webwork.maa.org/wiki/Mathematical_notation_recognized_by_WeBWorK

Is this a subset of a more widely known syntax? Can other systems provide competent parsing of the syntax more economically (for example, can this also be parsed by asciimathml for example)? How did the webworks system decide upon this system and to what extent will webworks remain with such syntax?

Re: Moodle 2 and the future of the Algebra Filter

Though my International Baccalaureate high school students are likely unaware of how this works, they're happy to be able to enter expressions in the familiar "Texas Instruments 83/84-family calculator" format [ e.g. (x-1)/(x+1)^2 ], and have them appear as TeX-rendered expressions in Moodle.

Here is "(x-1)/(x+1)^2" enclosed by double @ symbols:

@@(x-1)/(x+1)^2@@

" 'Nice to not have to know the TeX (\frac{}..., etc.) for this", my students would say if asked.

Several "TeX-generating" applications compete with the algebra filter, such as DragMath, Sitmo, and CodeCogs. In the majority of our actual use cases, however, Moodle's algebra filter is the easiest way for students to produce the nice TeX output.

It's my hope that the algebra filter will remain in place until and unless the same behavior (i.e. proper TeX expressions from "calculator-style" expression input) is produced—at least as efficiently—by some other filter or feature of Moodle.

Sincerely,

Tom Mellin

Here is "(x-1)/(x+1)^2" enclosed by double @ symbols:

@@(x-1)/(x+1)^2@@

" 'Nice to not have to know the TeX (\frac{}..., etc.) for this", my students would say if asked.

Several "TeX-generating" applications compete with the algebra filter, such as DragMath, Sitmo, and CodeCogs. In the majority of our actual use cases, however, Moodle's algebra filter is the easiest way for students to produce the nice TeX output.

It's my hope that the algebra filter will remain in place until and unless the same behavior (i.e. proper TeX expressions from "calculator-style" expression input) is produced—at least as efficiently—by some other filter or feature of Moodle.

Sincerely,

Tom Mellin

Re: Moodle 2 and the future of the Algebra Filter

As a newcomer to the idea of TeX and completely at sea with the various components and varieties of the Algebra and Tex filters, I cannot understand why there are two. Does the TeX filter do the job or not? Obviously not, otherwise, why have an Algebra filter? If it does not do the job required, then why include it? Is Moodle trying to be all things to all people? This is not Ford or GM, why should Moodle need to be? If I am sensing the drift of v2.0 there is a number of things that are essentially adapted from other, existing apps, TinyMCE NWiki, et al, so why not the TeX filter?