File:
[LON-CAPA] /
loncom /
homework /
templates /
functionplottwo.problem
Revision
1.5:
download - view:
text,
annotated -
select for diffs
Wed Dec 23 19:36:24 2015 UTC (9 years ago) by
damieng
Branches:
MAIN
CVS tags:
version_2_12_X,
version_2_11_X,
version_2_11_5_msu,
version_2_11_5,
version_2_11_4_uiuc,
version_2_11_4_msu,
version_2_11_4,
version_2_11_3_uiuc,
version_2_11_3_msu,
version_2_11_3,
version_2_11_2_uiuc,
version_2_11_2_msu,
version_2_11_2_educog,
version_2_11_2,
HEAD
fixed syntax errors in template
<problem>
<script type="loncapa/perl">$x=&random(5,10,1);</script>
<startouttext />
Make a sketch of the electrostatic potential (zero at infinity) of a negative point charge located at x=$x m.
<endouttext />
<functionplotresponse xaxisvisible="yes" xlabel="x [m]" gridvisible="yes" ylabel="V(x) [V]" id="11" xmax="30" yaxisvisible="yes" xmin="-4" ymin="-10" ymax="10" answerdisplay="-4/abs(x-$x)">
<functionplotelements>
<spline initx="-2" inity="0" index="A" order="2" scalex="4" />
<spline index="B" order="2" initx="12" inity="0" scalex="4" />
</functionplotelements>
<functionplotruleset>
<functionplotrule relationship="eq" value="undef" xinitial="$x" index="chargeposition" derivativeorder="0" />
<functionplotrule relationship="lt" value="0" derivativeorder="0" xinitiallabel="start" xfinallabel="chargeleft" index="negleft" />
<functionplotrule relationship="lt" value="0" derivativeorder="1" xinitiallabel="start" xfinallabel="chargeleft" />
<functionplotrule relationship="le" value="0" derivativeorder="2" xinitiallabel="start" xfinallabel="chargeleft" percenterror="20" />
<functionplotrule relationship="eq" xinitiallabel="chargeleft" xfinallabel="chargeright" value="undef" derivativeorder="0" />
<functionplotrule relationship="lt" value="0" derivativeorder="0" xinitiallabel="chargeright" xfinallabel="end" index="negright" />
<functionplotrule relationship="gt" value="0" derivativeorder="1" xinitiallabel="chargeright" xfinallabel="end" />
<functionplotrule relationship="le" value="0" derivativeorder="2" xinitiallabel="chargeright" xfinallabel="end" percenterror="20" />
</functionplotruleset>
<hintgroup showoncorrect="no">
<hintpart on="chargeposition">
<startouttext />The charge is not in the correct position.<endouttext />
</hintpart>
<hintpart on="negleft">
<startouttext />The potential is zero at negative infinity, and the charge is negative.<endouttext />
</hintpart>
<hintpart on="negright">
<startouttext />The potential is zero at positive infinity, and the charge is negative.<endouttext />
</hintpart>
</hintgroup>
</functionplotresponse>
</problem>
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>