Diff for /doc/homework/homework5.html between versions 1.5 and 1.10

version 1.5, 2001/06/12 21:05:31 version 1.10, 2001/10/01 20:13:38
Line 62 Line 62
     the response to go in. It checks all styles of numerical      the response to go in. It checks all styles of numerical
     supported in CAPA. Possible args are:      supported in CAPA. Possible args are:
     <ul>      <ul>
       <li><i>answer</i> required, specifies the correct answer, must be a perl list</li>        <li><i>answer</i> required, specifies the correct answer, may be either a perl list or scalar</li>
       <li><i>type</i> optional, CAPA style str args, cs/ci/mc</li>  
       <li><i>units</i> optional, specifies unit of correct answer, CAPA style</li>        <li><i>units</i> optional, specifies unit of correct answer, CAPA style</li>
     </ul>      </ul>
   </li>    </li>
   <li>    <li>
       <b>&lt;stringresponse&gt;</b> implements a string answer,
       it needs an internal <b>&lt;textline&gt;</b> for the
       response to go in. It can check the string for either case
       or order.
       <ul>
         <li><i>answer</i> required, specifies the correct answer, may be either a perl list or scalar</li>
         <li><i>type</i> optional, CAPA style str args, cs/ci/mc
    <ul>
     <li>cs - case senesitive, order important</li>
     <li>ci - case insenesitive, order important</li>
     <li>mc - case insenesitive, order unimportant</li>
    </ul>
         </li>
       </ul>
     <li>
     <b>&lt;essayresponse&gt;</b> implements a ungraded large      <b>&lt;essayresponse&gt;</b> implements a ungraded large
     text response, it need an internal <b>&lt;textarea&gt;</b>      text response, it need an internal <b>&lt;textarea&gt;</b>
     for the response to go in.      for the response to go in.
Line 108 Line 122
     <i>value</i> of a &lt;foil&gt;can only be "true" or      <i>value</i> of a &lt;foil&gt;can only be "true" or
     "false" or "unused"      "false" or "unused"
   </li>    </li>
     <li>
       <b>&lt;dataresponse&gt;</b> implements a straight data
       storage entry idea, needs and interveing input tag like
       &lt;textline&gt; to work correctly.<br>
       Arguments:
       <ul>
         <li>
    <i>name</i> internal name for the value, it will have
    the part id and respose id added on to it
         </li>
         <li>
    <i>type</i> type of data stored in this response
    field, should be one of the types supported by
    parameter.html
         </li> 
         <li>
    <i>display</i> a string that will be used to describe
    the field when interfacing with humans
         </li>
       </ul>
     <li>
  </ul>   </ul>
  <li>   <li>
  <a name="foil">Foil Structure Tags</a>   <a name="foil">Foil Structure Tags</a>
Line 351 Line 386
             <td valign="top"><b>Differences (if any)</b</td>              <td valign="top"><b>Differences (if any)</b</td>
      </tr>       </tr>
   
      <tr>  
              <td valign="top">sin(x), cos(x), tan(x)</td>  
              <td valign="top">&amp;sin($x), &amp;cos($x), &amp;tan($x)</td>  
              <td valign="top">Trigonometric functions where x is in radians. $x  
          can be a pure number, i.e., you can call &amp;sin(3.1415)</td>  
              <td valign="top">&nbsp</td>  
     </tr>  
   
     <tr>      <tr>
              <td valign="top">sin(x), cos(x), tan(x)</td>               <td valign="top">sin(x), cos(x), tan(x)</td>
              <td valign="top">&amp;sin($x), &amp;cos($x), &amp;tan($x)</td>               <td valign="top">&amp;sin($x), &amp;cos($x), &amp;tan($x)</td>
Line 458 Line 485
     </tr>      </tr>
   
     <tr>      <tr>
                <td valign="top">/DIS($x,"nn")</td>
                <td valign="top">&amp;format($x,"nn")</td>
                <td valign="top">Display or format $x as nn where nn is nF or nE and n is an integer.</td>
                <td valign="top">&nbsp;The difference is obvious.</td>
       </tr>
   
       <tr>
              <td valign="top">roundto(x,n)</td>               <td valign="top">roundto(x,n)</td>
              <td valign="top">&amp;roundto($x,$n)</td>               <td valign="top">&amp;roundto($x,$n)</td>
              <td valign="top">Rounds a real number to n decimal points. $x and               <td valign="top">Rounds a real number to n decimal points. $x and
Line 523 Line 557
     </tr>      </tr>
   
     <tr>      <tr>
                <td valign="top">map(seed;a,b,c,d;w,x,y,z)</td>
                <td valign="top">Option 1 - &amp;map($seed,[\$w,\$x,\$y,\$z],[$a,$b,$c,$d]) or <br> 
                     Option 2 - &amp;map($seed,\@mappedArray,[$a,$b,$c,$d]) <br>
                     Option 3 - @mappedArray = &amp;map($seed,[$a,$b,$c,$d]) <br>
                     Option 4 - ($w,$x,$y,$z) = &amp;map($seed,\@a) <br>
                     where $a='A'<br>
                           $b='B'<br>
                           $c='B'<br>
                           $d='B'<br>
                           $w, $x, $y, and $z are variables</td>
                <td valign="top">Assigns to the variables $w, $x, $y and $z the values of the
                     $a, $b, $c and $c (A, B, C and D). The precise value for $w .. depends
                     on the seed. (Option 1 of calling map). 
                     In option 2, the values of $a, $b .. are mapped into the array, @mappedArray. The two
                     options illustrate the different grouping. Options 3 and 4 give a consistent 
                     way (with other functions) of mapping the items. For each option, the group can
                     be passed as an array, for example, [$a,$b,$c,$d] => \@a.</td>
                <td valign="top">In CAPA, the arguments are divided into three groups separated
                     by a semicolon ;. In LON-CAPA, the separation is done by using [] brackets or
                     using an array @a. Note the backslash (\) before the arguments in the
                     second and third groups.</td>
       </tr>
   
   
       <tr>
                <td valign="top">rmap(seed;a,b,c,d;w,x,y,z)</td>
                <td valign="top">Option 1 - &amp;rmap($seed,[\$w,\$x,\$y,\$z],[$a,$b,$c,$d]) or <br> 
                     Option 2 - &amp;rmap($seed,\@rmappedArray,[$a,$b,$c,$d]) <br>
                     Option 3 - @rmapped_array = &amp;rmap($seed,[$a,$b,$c,$d]) <br>
                     Option 4 - ($w,$x,$y,$z) = &amp;rmap($seed,\@a) <br>
                     where $a='A'<br>
                           $b='B'<br>
                           $c='B'<br>
                           $d='B'<br>
                           $w, $x, $y, and $z are variables</td>
                <td valign="top">The rmap functions does the reverse action of map if the same seed
                     is used in calling map and rmap. </td>
                <td valign="top">In CAPA, the arguments are divided into three groups separated
                     by a semicolon ;. In LON-CAPA, the separation is done by using [] brackets or
                     using an array @a. Note the backslash (\) before the arguments in the
                     second and third groups.</td>
       </tr>
         
        <tr>
                <td valign="top">NOT IMPLEMENTED IN CAPA</td>
                <td valign="top">$a=&amp;xmlparse($string) </td>
                <td valign="top">Runs the internal parser over the
     argument parsing for display. <b>Warning</b> This will
     result in different strings in different targets. Don't use
     the results of this function as an answer.</td>
                <td valign="top">New to LON-CAPA</td>
       </tr>
   
       <tr>
              <td valign="top">tex(a,b), tex("a","b")</td>               <td valign="top">tex(a,b), tex("a","b")</td>
              <td valign="top">&amp;tex($a,$b), &amp;tex("a","b")</td>               <td valign="top">&amp;tex($a,$b), &amp;tex("a","b")</td>
              <td valign="top">Returns a if the output mode is in tex otherwise               <td valign="top">Returns a if the output mode is in tex otherwise
Line 713 Line 801
              <td valign="top">New to LON-CAPA</td>               <td valign="top">New to LON-CAPA</td>
     </tr>      </tr>
      <tr>       <tr>
              <td valign="top">NOT IMPLEMENTED IN CAPA</td>               <td valign="top">NOT DOCUMENTED IN CAPA</td>
              <td valign="top">@return_array=&random_multivariate_normal ($item_cnt,$seed,@mean,@covar) <br>               <td valign="top">@return_array=&random_multivariate_normal ($item_cnt,$seed,\@mean,\@covar) <br>
                         NOTE: @mean should be a length p array of real numbers. @covar should be a length                          NOTE: @mean should be of length p array of real numbers. @covar should be a length
                         p array of references to length p arrays or real numbers (i.e. a p by p matrix.</td>                          p array of references to length p arrays of real numbers (i.e. a p by p matrix.</td>
              <td valign="top">Generate $item_cnt deviates of multivariate_normal distribution with                 <td valign="top">Generate $item_cnt deviates of multivariate_normal distribution with  
                         mean vector @mean and variance-covariance matrix. </td>                          mean vector @mean and variance-covariance matrix. </td>
              <td valign="top">New to LON-CAPA</td>               <td valign="top">Note the backslash before the @mean and @covar arrays.</td>
     </tr>      </tr>
      <tr>       <tr>
              <td valign="top">NOT IMPLEMENTED IN CAPA</td>               <td valign="top">NOT IMPLEMENTED IN CAPA</td>
Line 808 Line 896
     <address><a href="mailto:albertel@marvin.lite.msu.edu">Guy Albertelli</a></address>      <address><a href="mailto:albertel@marvin.lite.msu.edu">Guy Albertelli</a></address>
 <!-- Created: Thu May 17 15:05:35 EDT 2001 -->  <!-- Created: Thu May 17 15:05:35 EDT 2001 -->
 <!-- hhmts start -->  <!-- hhmts start -->
 Last modified: Tue June 12 15:25 EDT 2001  Last modified: Mon Oct  1 16:12:05 EDT 2001
 <!-- hhmts end -->  <!-- hhmts end -->
   </body>    </body>
 </html>  </html>

Removed from v.1.5  
changed lines
  Added in v.1.10


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