# Community

cancel
Showing results for
Show  only  | Search instead for
Did you mean:
Community Participant

## Using formulas in variable definitions?

Is it possible to create formulas in the variable definitions for formula questions?

Example: teacher wants to create formula questions for adding multiples of 5.

Ideally, I could enter for [x] "5*0" as my minimum and "5*20" as a maximum so that all of the variables for [x] would be  multiple of 5. It doesn't seem to work though. I do see what that doesn't work though, since the software probably doesn't know understand the ranges for two different numbers.

Another way to handle this?

Tags (4)
1 Solution

Accepted Solutions
Community Champion

Is it possible to create formulas in the variable definitions for formula questions?

Not currently. There was a period of time where there was a big push in the Community for improving the random number generation capability of Canvas, but I don't see where any of those rose to the level of making it onto product radar.

The variables can only be random numbers, which you can limit to integers, but you can't use anything other than the randomly generated variables in the question text. Explained another way, you can generate [a], [b], and [c], but if d is a formula based on [a], [b], and/or [c], such as d=5*a, you cannot use [d] in the question text.

Another way to handle this?

Option 1: Don't use formula questions.

I create questions like this in Excel, import them into Respondus, and then export them into Canvas. You can, of course, create them directly in Canvas as well.

Option 2: Change the way you ask the question.

"What is the sum when you start with 5×[a] and add the next [n] multiples of 5?"

or

"What is the sum of all the multiples of 5 starting with 5×[a] and ending with 5×[b]?"

Make sure that [a] and [b] cannot overlap and that [b] is definitely greater than [a], but then the answer would be

3 Replies
Community Champion

Is it possible to create formulas in the variable definitions for formula questions?

Not currently. There was a period of time where there was a big push in the Community for improving the random number generation capability of Canvas, but I don't see where any of those rose to the level of making it onto product radar.

The variables can only be random numbers, which you can limit to integers, but you can't use anything other than the randomly generated variables in the question text. Explained another way, you can generate [a], [b], and [c], but if d is a formula based on [a], [b], and/or [c], such as d=5*a, you cannot use [d] in the question text.

Another way to handle this?

Option 1: Don't use formula questions.

I create questions like this in Excel, import them into Respondus, and then export them into Canvas. You can, of course, create them directly in Canvas as well.

Option 2: Change the way you ask the question.

"What is the sum when you start with 5×[a] and add the next [n] multiples of 5?"

or

"What is the sum of all the multiples of 5 starting with 5×[a] and ending with 5×[b]?"

Make sure that [a] and [b] cannot overlap and that [b] is definitely greater than [a], but then the answer would be

Community Participant

James, how does Excel make creating questions easier?

Community Champion

Sorry, I missed your question about Excel for over 2 years and just now stumbled across it as I was looking up previous material for another question.

I use Excel to generate the text of the question. Since Excel has calculation capability built in, it can find the correct answer. Respondus can import a CSV file saved from Excel.

Alternatively, you can use Excel to create the question and then copy/paste it into Canvas.