Convert static questions to algorithmic
Updated 28 Aug 2023
- Enter your problem and the answer with static values in the question-and-answer area of the Custom Question Builder.
- Select a static value that you want to convert to algorithmic.
- In the Algorithmic Value toolbar, click Convert
to Algorithmic Value to open the Edit
Algorithmic Values window.
If the value you selected begins with a letter, it shows in the Algorithmic Value Name box as the default name for the algorithmic value. If the value you selected begins with a number, the default variable name, which begins with a V, shows.
- Enter a name or accept the default name. Then select an appropriate type, define the constraints, and set any other options for the algorithmic value.
- Click Save to save your question.
The new algorithmic value shows in the question-and-answer area in place of the static value that you selected.
Suppose that you enter the following question to calculate the square footage of a room:
The kitchen of your house is 12 feet by 10 feet. What is the area in square feet?
The area is 120 square feet.
- Highlight the word kitchen in the question area.
- Click Convert to Algorithmic Value to open the Edit Algorithmic Value window.
- In the Algorithmic Value Name box, change the name from kitchen to room.
- Choose Text or symbol as the type.
- Create a list of rooms in the constraints area: kitchen, living room, bedroom, dining room. Enclose all text entries in quotation marks:
- On the Options tab, enter any authoring notes that you want to refer to when you look at the question later.
- Click Save to enter the algorithmic value in the question area.
- Highlight the number 12 in the question area and click Convert to Algorithmic Value.
- In the Algorithmic Value Name box, change the name from V1 to dim1 (dimension 1).
- Choose Integer as the type.
- In the constraints area, create a range of possible dimensions from 8 to 20:
- On the Options tab, enter any authoring notes that you want to refer to when you look at the question later.
- Click Save to enter the algorithmic value in the question area.
- Highlight the number 10 in the question area and click Convert to Algorithmic Value.
- In the Algorithmic Value Name box, change the name from V1 to dim2 (dimension 2).
- Choose Integer as the type.
- In the constraints area, once again create a range of possible dimensions from 8 to 20.
- On the Options tab, enter any authoring notes that you want to refer to when you look at the question later.
- Click Save to enter the algorithmic value in the question area.
- In the answer area, highlight the number 120 and click Convert to Algorithmic Value.
- In the Algorithmic Value Name box, change the name from V1 to ans (answer).
- Choose Integer as the type.
- In the constraints area, use an asterisk as the multiplier symbol and create a formula that multiplies ~dim1 by ~dim2:
- On the Options tab, enter any authoring notes that you want to refer to when you look at the question later.
- Click Save to enter the algorithmic
value in the answer area.
Your question now looks something like this:
- Click Regenerate Algorithmic Values to ensure that your algorithmic values work correctly.
- In the answer area, highlight the answer box and then delete it so you can create a new input area where students must enter their answers.
- With your cursor in front of "square feet," click Short Answer to get the Edit Answer Definition window.
- In Step 1, define the answer as an integer.
- In Step 2, click the first row under Value and enter
~ans
as the value: - Save the answer definition.
- Click Preview Exercise to view the question as your students will see it. Enter some correct and incorrect answers to test your question.
- When you are satisfied, dismiss the Preview window and then click Save to save your question.
Note: If you created custom feedback for incorrect answers, you might need to revise that feedback so that it applies regardless of the student's answer or so that it changes as the algorithmic values change.