PREP 2014 Question Authoring - Archived

GeoGebra applet not loading

GeoGebra applet not loading

by Nicholas Nguyen -
Number of replies: 4
Dear all,
I've started experimenting with GeoGebra. When I try to look at the example problem at

http://webwork.maa.org/wiki/GeoGebra1


and copy it to my course, the GeoGebra applet does not load, and gives the error:

ClassNotFoundException
geogebra.GeoGebraApplet

I tried copying the problem over to the PREP 2014 WeBWorK course, and the applet worked there. What could be going on with my course or WeBWorK installation that would cause GeoGebra applets to not work?
In reply to Nicholas Nguyen

Re: GeoGebra applet not loading

by Murphy Waggoner -
Nicholas,
I am very interesting in developing some questions using GeoGebra and would appreciate the ability to work together on this.

This is exactly the same problem I have had and just hadn't gotten around to reporting it yet.

I suspect the problem is the need for a specific .pl file.  I have found that when I try to run a .pg problem, I don't always get a message saying that one of the .pl files was not available.  My first recommendation is to look at the list of .pl files listed in the .pg code at http://webwork.maa.org/wiki/GeoGebra1.  Then go to the File Manager at the PREP 2014 WeBWorK course and look for the .pl files in the macro folder.  If you find one there that you don't have in your own WeBWorK course, you can copy it in.

But that is just a thought and I haven't had a chance to see if that is the problem or not.

One of the mentors in this PREP course said that they had worked on GeoGebra problems and if any of us wanted to work on them to contact him, but sadly I can't remember who that was.

Murphy 
In reply to Murphy Waggoner

Re: GeoGebra applet not loading

by Nicholas Nguyen -
Dear Murphy,
I would be glad to work with others. I believe Paul Pearson was the mentor who presented the GeoGebra example in the last workshop. Have you posted any problems to the PREP 2014 WeBWorK course?

You can see some of my "scratch work" in a homework set titled "Nguyen_practice" (problems 21 and 22). Problem 21 is just me seeing if I can plot points in WeBWorK itself using the pg file. Problem 22 is an attempt to plot graphs in the GeoGebra applet that matches the ones in the pictures, but so far I have been unsuccessful. It seems that trying to do for loops in the Applet setup part of the code causes problems like a blank display.

As for the issue on my university's WeBWorK course, I tried copying the macros, but the same problem still happened. Have you tried it on yours yet?

Nicholas
In reply to Nicholas Nguyen

Re: GeoGebra applet not loading

by Murphy Waggoner -
I get the same error as you did and then did a little investigating. This is a Java problem, not a webwork problem. The fact that we need Java to use this type of problem worries me because the students will run into the same problems and become frustrated. Not sure I want to proceed with resolving this, especially if I will have to resolve it for all the student as well.

OTOH, I want to be able to have students plot points, circles, lines, etc., using Webwork.
In reply to Murphy Waggoner

Re: GeoGebra applet not loading

by Nicholas Nguyen -
I was able to solve the problem. It seems that the file geogebra.jar is not present on the WeBWorK server at my university. This file appears in the Applet Setup part of the pg file around here:

$applet = JavaApplet(
code => "geogebra.GeoGebraApplet",
archive => "geogebra.jar",
codebase => findAppletCodebase("geogebra.jar"),
...

I was able to find the geogebra.jar on the geogebra website at

http://www.geogebra.org/webstart/4.2/unpacked/geogebra.jar

and changed the pg file:

code => "geogebra.GeoGebraApplet",
archive => "http://www.geogebra.org/webstart/4.2/unpacked/geogebra.jar",
codebase => findAppletCodebase("http://www.geogebra.org/webstart/4.2/unpacked/geogebra.jar"),

The 4.2 in the URL refers to the version of GeoGebra you use, so you may have to change it.

Meanwhile, I also solved the issue with my applet not graphing all vertices. I managed to get it to plot all vertices and edges in my graphs now. I'll try some other techniques like getting answers from the applet next week.