[LON-CAPA-users] adjusting variables on a problem that's been released?

Gerd Kortemeyer korte at lite.msu.edu
Tue Oct 4 11:02:35 EDT 2011


Hi,

On Oct 4, 2011, at 10:27 AM, Mills, Douglas G wrote:

> 
> 
> We have an odd situation where in a very small percentage of cases our random variables are working together to generate an impossible answer (“mix 1004.2 mL of X and –4.2 mL of Y to form 1 L of solution...”). The problem has been released and these can be dealt with on a case by case basis as needed if necessary, but we are wondering what would happen if we tweaked the range of one of the variables to eliminate the possibility of the answers over 1000 mL.

All randomizations will change.

>  Specifically, what happens to students who have already done the problem

They will keep the credit, but would see a different version of it.


> with that variable possibly out of the new range (there are several variables involved so only in a very few cases do the calculations result in a solution out of range) -- does Lon-Capa ignore those cases where the problem has already been completed?  What happens if a student has started the problem and so had the values set, but has not completed it — do the original values stay the same even though they are now out of range in the newly published version?

The values *will* change.

The only way you can safely address this is to leave everything in place at the front of the script block, but then add a section to the end that says

# everything as it was
if ($yvolume<=0) { # catch the pathological case
# completely redo everything in here
   $xvolume=&random(…);
…
   $answer=...
}

If you do this, only the versions of the problem will change that were impossible to solve in the first place.

BTW, to avoid this situation, I oftentimes first randomly generate the answer and then build the problem.

- Gerd.



More information about the LON-CAPA-users mailing list