Annotation of loncom/homework/templates/functionplottwo.problem, revision 1.4
1.1 www 1: <problem>
2: <script type="loncapa/perl">$x=&random(5,10,1);</script>
3: <startouttext />
4: Make a sketch of the electrostatic potential (zero at infinity) of a negative point charge located at x=$x m.
5: <endouttext />
1.4 ! www 6: <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)">
1.2 www 7: <functionplotelements>
1.1 www 8: <spline initx="-2" inity="0" index="A" order="2" scalex="4" />
9: <spline index="B" order="2" initx="12" inity="0" scalex="4" />
1.2 www 10: </functionplotelements>
11: <functionplotruleset>
12: <functionplotrule relationship="eq" value="undef" derivative="0" xinitial="$x" index="chargeposition" derivativeorder="0" />
1.3 www 13: <functionplotrule relationship="lt" value="0" derivativeorder="0" xinitiallabel="start" xfinallabel="chargeleft" index="negleft" />
1.1 www 14: <functionplotrule relationship="lt" value="0" derivativeorder="1" xinitiallabel="start" xfinallabel="chargeleft" />
1.3 www 15: <functionplotrule relationship="le" value="0" derivativeorder="2" xinitiallabel="start" xfinallabel="chargeleft" percentageerror="20" />
1.1 www 16: <functionplotrule relationship="eq" xinitiallabel="chargeleft" xfinallabel="chargeright" value="undef" derivativeorder="0" />
1.3 www 17: <functionplotrule relationship="lt" value="0" derivativeorder="0" xinitiallabel="chargeright" xfinallabel="end" index="negright" />
1.1 www 18: <functionplotrule relationship="gt" value="0" derivativeorder="1" xinitiallabel="chargeright" xfinallabel="end" />
1.3 www 19: <functionplotrule relationship="le" value="0" derivativeorder="2" xinitiallabel="chargeright" xfinallabel="end" percentageerror="20" />
1.2 www 20: </functionplotruleset>
21:
22: <hintgroup showoncorrect="no">
23: <hintpart on="chargeposition">
24: <startouttext />The charge is not in the correct position.<endouttext />
25: </hintpart>
1.3 www 26: <hintpart on="negleft">
27: <startouttext />The potential is zero at negative infinity, and the charge is negative.<endouttext />
28: </hintpart>
29: <hintpart on="negright">
30: <startouttext />The potential is zero at positive infinity, and the charge is negative.<endouttext />
31: </hintpart>
1.2 www 32: </hintgroup>
1.1 www 33: </functionplotresponse>
34: </problem>
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>