Annotation of loncom/homework/templates/SimpleFormula.problem, revision 1.6

1.5       www         1: <problem>
1.6     ! albertel    2:     <script type="loncapa/perl">
        !             3: $k=&random(3,6,1);
1.5       www         4: $formula="a*x^$k";
                      5: $m=$k-1;
1.6     ! albertel    6: $derivative="$k*a*x^$m";
        !             7:     </script>
1.5       www         8: 
1.6     ! albertel    9:     <startouttext />
        !            10: What is the derivative of <tt>$formula</tt> with respect to x?
        !            11:     <endouttext />
1.5       www        12: 
1.6     ! albertel   13:     <formularesponse samples="a,x@-3,-3:3,3#4" answer="$derivative">
        !            14:         <responseparam description="Numerical Tolerance" type="tolerance" default="0.00001" name="tol" />
        !            15:         <textline size="25" />    
        !            16:     </formularesponse>
1.5       www        17: 
                     18: </problem>
                     19: 

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>