Forum archive 2000-2006

Lars Jensen - osu problems: latex graphics doesn't show

Lars Jensen - osu problems: latex graphics doesn't show

by Arnold Pizer -
Number of replies: 0
inactiveTopicosu problems: latex graphics doesn't show topic started 10/1/2004; 6:19:14 PM
last post 10/8/2004; 12:56:03 PM
userLars Jensen - osu problems: latex graphics doesn't show  blueArrow
10/1/2004; 6:19:14 PM (reads: 1920, responses: 7)
We have a number of problems from osu, like those in osu_problib/high_school_apcalc/dchmwk8 which contain latex drawings that we can't get to show up on the screen - instead we see the raw latex code.

Examples of such problems are dchmwk8/prob12.pg dchmwk8/prob119.pg dchmwk8/prob34.pg etc.

What can we do get this graphics to show up?

Thanks, Lars.

<| Post or View Comments |>


userMichael Gage - Re: osu problems: latex graphics doesn't show  blueArrow
10/4/2004; 12:17:28 PM (reads: 2179, responses: 0)
I believe that those problems were designed to work in Latex2HTML mode (where the entire problem is run through a tex compiler) If you use the typeset mode do they show up? How about for hardcopy? Modifying the problems to work in other display modes might take some work. dvipng and jsMath aren't really designed to handle all tex commands, although they will handle essentially all of the math display commands.

<| Post or View Comments |>


userZbigniew Fiedorowicz - Re: osu problems: latex graphics doesn't show  blueArrow
10/4/2004; 2:16:48 PM (reads: 2196, responses: 0)
Mike,

They work fine in dvipng. However jsMath can't handle it.

Zig

<| Post or View Comments |>


userLars Jensen - Re: osu problems: latex graphics doesn't show  blueArrow
10/5/2004; 1:50:15 AM (reads: 2166, responses: 0)
Hi Zig and Mike,

We downloaded the problems as is from cvs, and we set up a problem set with this version without modifying anything. The pdf hardcopy comes out fine, but the screen typeset (dvipng) version shows the raw latex - both in wwk1 and in wwk2. Do we need to do something special to get the screen version to display?

Lars.

<| Post or View Comments |>


userDavide P. Cervone - Re: osu problems: latex graphics doesn't show  blueArrow
10/5/2004; 7:40:27 AM (reads: 2175, responses: 0)
Zig and Mike:

Lars is right, the problems as they stand in the OSU library do NOT work in dvipng or jsMath mode. The LaTeX commands are not enclosed in math mode, and so are not sent to dvipng for processing. They can be fixed, but they don't work as is.

Lars, the fix is to put \[ and \] around the material that is showing up as LaTeX code in the problem. But there is an additional change that must be made. Some of the labels in the pictures are themselves in math mode, and WeBWorK will try to pass these to dvipng first before handling the larger chunk of math. To avoid this, change any \( and \) to \begin{math} and \end{math} within the picture environment.

Hope this helps.

Davide

<| Post or View Comments |>


userDavide P. Cervone - Re: osu problems: latex graphics doesn't show  blueArrow
10/5/2004; 8:21:10 AM (reads: 2171, responses: 0)
PS, Zig is correct in stating that jsMath will not process this problem even if you make the fix I recommended above, as jsMath doesn't support the picture environment.

Davide

<| Post or View Comments |>


userLars Jensen - Re: osu problems: latex graphics doesn't show  blueArrow
10/5/2004; 11:15:00 AM (reads: 2163, responses: 0)
Davide, thanks for the answer. What you said seems to work.

Zig, are the cvs versions of these problems old? -It sounds like you have working versions of these problems available. If so, would you be willing to upload them to CVS?

Thanks, Lars.

<| Post or View Comments |>


userLars Jensen - Re: osu problems: latex graphics doesn't show  blueArrow
10/8/2004; 12:56:03 PM (reads: 2122, responses: 0)
Hi Zig,

Do you have working versions of these problems? We have an instructor that would like to use them.

Thanks, Lars.

<| Post or View Comments |>