Author a Math App question to be graded by Maple

You can author a Math App question to include grading code built inside of the Math App itself (instead of inputting the grading code directly into Möbius) to grade student responses.

The Maple grading procedure is defined within the Math App's Maple worksheet when it's created through the Maple software program.

You must define an Actions module in the Startup Code of the Math App, and that module must contain an exported procedure called Grade that's used to grade the student response.

This help topic shows you how to:

  • Create a basic Math App using the Maple software program;

  • Define a grading procedure within the Math App using the Maple software program; and

  • Configure your Math App question in Möbius to reference the grading procedure.

Create a Math App

Here's an example of how to create a basic Math App within Maple:

  1. Start a new Maple document in the Maple software program.

  2. Click the Plot Component and Slider Component from the Components palette to add them to your document.

  3. Right-click the inserted Slider component and click Component Properties.

  4. Make the following changes in the Slider Properties window:

    • Change the Value at Lowest Position to -5

    • Change the Value at Highest Position to 5

    • Change the Spacing of Major Tick Marks to 5

    • Change the Spacing of Minor Tick Marks to 1

    • Ensure the check boxes for the following options are selected:

      • Enable Input

      • Visible

      • Show Track

      • Show Axis Labels

      • Show Axis Tick Marks

      • Continuous Update On Drag

  5. Click OK.

  6. Right-click the Slider component and click Edit Value Changed Code.

  7. Remove the default code in the Component Code Editor and replace it with the following:

    DocumentTools:-Do(%Plot0=plot(x^2+%Slider0*x+4, x=-5..5, y=-5..10));

  8. Click the save icon and then exit the Component Code Editor.

  9. Save your Maple document with the .mw file extension.

Define a grading procedure within the Math App

Here's how to define the grading procedure within your Math App:

  1. Open your Math App in the Maple software program from the Create a Math App section of this help topic. Click Startup Code (or press Ctrl+Shift+E) from the Edit menu.

  2. Define an Actions module with an exported procedure called Grade, by adding the following code into the empty Startup Code window:

    Actions := module() export Grade; Grade:=proc() if DocumentTools:-GetProperty(Slider0,value)=-2 then return 1; else return 0; end if; end proc; end module;

  3. Click the save icon and then close the Startup Code window.

  4. Save your Maple document with the .mw file extension. Your new Math App now has an Actions:-Grade procedure that calculates the grade.

Configure your Math App question to use the grading procedure

Once you've saved your Math App with the Actions:-Grade procedure, that allows for automatic grading of the Math App question without adding any additional code to Möbius.

Navigate to the Question Editor in Möbius and follow the steps described in Author a Math App question to configure your question to use the Math App's grading procedure.