[LON-CAPA-users] Any way around this?
Mills, Douglas G
dmills at illinois.edu
Tue Aug 21 11:39:32 EDT 2012
So <numericalresponse answer="$CB1" format="4s"> ?? I have that, and have
tried setting the variable both with and without the &format command, but to
no avail. 8.000e-6, 8*10^-6 and even .000008000 all show up in the error
message as 8e-06 complaining of the computer's answer being wrong.
On 8/21/12 10:30 AM, "Gerd Kortemeyer" <korte at lite.msu.edu> wrote:
> Hi,
>
> I would suggest putting the format into the "Format" field of the numerical
> response.
>
> - Gerd.
>
> On Aug 21, 2012, at 10:54 AM, "Mills, Douglas G" <dmills at illinois.edu> wrote:
>
>> HI All,
>>
>> I¹m finding that if I define a variable as follows:
>>
>> $CB1=&format(8.000e-6,"4s");
>>
>> OR
>>
>> $CB1=&format(8.000e-6,"3e");
>>
>> And use it as the answer to a numerical problem requiring 4 significant
>> figures, I get the error message that ³the computer¹s answer is incorrect
>> (Œ8e-06¹).²
>>
>> I know (and have tested to confirm) that if I simply change the final zero to
>> a 1 (so 8.001e-6) everything is fine. I had thought the &format command was
>> the key to insisting on the correct number of sig figs in a variable, but I
>> guess hadn¹t run into this specific situation before.
>>
>> Any help from the pros? Thanks,
>>
>> Doug
>>
>> Douglas Mills
>> Director of Instructional Technologies
>> Department of Chemistry
>> University of Illinois
>> dmills at illinois.edu
>> (217) 244-5739
>>
>> _______________________________________________
>> LON-CAPA-users mailing list
>> LON-CAPA-users at mail.lon-capa.org
>> http://mail.lon-capa.org/mailman/listinfo/lon-capa-users
>
> _______________________________________________
> LON-CAPA-users mailing list
> LON-CAPA-users at mail.lon-capa.org
> http://mail.lon-capa.org/mailman/listinfo/lon-capa-users
Doug
Douglas Mills
Director of Instructional Technologies
Department of Chemistry
University of Illinois
dmills at illinois.edu
(217) 244-5739
More information about the LON-CAPA-users
mailing list