STACK: variable number of inputs possible?

STACK: variable number of inputs possible?

by Florian Hanisch -
Number of replies: 2

Hi,

I am trying to set up a STACK task where I dot not want to specify the number of inputs in advance but rather have the user determine that number. More precisely, students are supposed to determine a basis of a given vector space without knowing the dimension in advance.  Providing the exact amount of input boxes gives away the dimension. I am wondering whether there is a way to have a flexible number of input boxes for vectors. E.g students decide during runtime that they want another box for another vector ... or they specify the required amount of boxes initially.

I was considering to provide the maximum possible number of boxes and just use the relevant ones for the evaluation ... but maybe there is better solution or a better workaround ?

Thanks a lot,

Florian

Average of ratings: -
In reply to Florian Hanisch

Re: STACK: variable number of inputs possible?

by Christopher Sangwin -
Picture of Particularly helpful Moodlers Picture of Plugin developers
I've been asked for this before. Currently, you have to have a fixed number of inputs.

I do appreciate the limitations of this. I teach linear algebra and needed to ask this exact question! You have two options.

1. Use the "allow empty" and ask students to full in only inputs they need.
2. Use a matrix of variable size, one column per vector.

Not ideal, but a workable solution.

Chris
Average of ratings: Useful (1)
In reply to Christopher Sangwin

Re: STACK: variable number of inputs possible?

by Florian Hanisch -
Thanks, I eventually asked the students to fill in a dummy variable in the boxes they did not need. Next time, I will try your option 1!
And sorry for very late reply, simply I forgot when there were too many other things to do.

Florian