[LON-CAPA-users] Interaction between jsMath or LaTeX and randomized multiple choice answers??

Peter Dencker dencker at math.uni-luebeck.de
Wed Oct 18 21:41:48 EDT 2017

As noted in the manual, setting the attribute display to jsmath is
generally discouraged as it requires users to have installed jsmath
fonts on their computer.

The last release of jsMath was more than 4 years ago. It was succeeded
by MathJax. Forcing the use of this math rendering engine with <m
display="MathJax"> seems to work in your example.

The math rendering can be selected by the user or the course
coordinator. Using your example without the display attribute in <m> ..
</m> and forcing the jsMath math rendering as course coordinator seems
to work. But using your example with display attribute "MathJax" and
forcing the jsMath math rendering as course coordinator does not. I
would like to recommend to omit the display attribute in <m> .. </m>.

- Peter

Am 18.10.2017 um 20:00 schrieb Mills, Douglas G:
> HI All,
> Below is code for a problem that is acting quite strangely.  If you put this into your authoring space and hit new randomization a few times, you'll see that in some instances the LaTeX doesn't display at all for any of the answers. I added the "1:" etc. at the front of each one to try to get a handle on what was happening. I'm seeing that in some combinations of four, such as 6532, 3265, 6432, 4365 and 3625 (and some others), the LaTeX does not show.  Noticing that several of the combinations involved 2,3,5 and 6, I removed options 1 and 4 and left the rest of the code as is.  Under those conditions, even the combinations that do not appear when there are 6 options to choose from (6532 for example) DOES appear when there are only 4 options to be chosen from.  This leads me to suspect that there is some type of interaction going on between the LaTeX and the choosing of 4 out of 6 options in the problem below.
> Maybe I'm missing something obvious?  All help appreciated!
> Doug
> <problem>
> Which of the following are variations of the ideal gas law?
> <optionresponse id="14" randomize="yes" max="4">
>     <foilgroup checkboxoptions="nochoice" options="('True','False')" checkboxvalue="True">
>         <foil value="True" name="Foil1">
>             <startouttext />1: <m display="jsMath">$V = \frac{nRT}{P}$</m><br/><endouttext />
>         </foil>
>         <foil name="Foil2" value="True">
>             <startouttext />2: <m display="jsMath">$P = \frac{nRT}{V}$</m><br/><endouttext />
>         </foil>
>          <foil value="True" name="Foil3">
>             <startouttext />3: <m display="jsMath">$n = \frac{PV}{RT}$</m><br/><endouttext />
>         </foil>
>        <foil value="True" name="Foil4">
>             <startouttext />4: <m display="jsMath">$T = \frac{PV}{nR}$</m><br/><endouttext />
>         </foil>
>         <foil value="True" name="Foil5">
>             <startouttext />5: <m display="jsMath">$R = \frac{PV}{nT}$</m><br/><endouttext />
>         </foil>
>         <foil name="Foil6" value="True">
>             <startouttext />6: <m display="jsMath">$PV = nRT$</m><br/><endouttext />
>         </foil>
>     </foilgroup>
> </optionresponse>
> </problem>
> _______________________________________________
> LON-CAPA-users mailing list
> LON-CAPA-users at mail.lon-capa.org
> http://mail.lon-capa.org/mailman/listinfo/lon-capa-users

Dr. Peter Dencker
    wissenschaftl. Mitarbeiter


    Ratzeburger Allee 160
    23562 Lübeck

    dencker at math.uni-luebeck.de


More information about the LON-CAPA-users mailing list