--- loncom/html/adm/help/tex/Problem_LON-CAPA_Functions.tex 2014/12/14 02:44:04 1.31
+++ loncom/html/adm/help/tex/Problem_LON-CAPA_Functions.tex 2017/09/24 01:52:57 1.33
@@ -47,6 +47,9 @@ erf = 2/sqrt(pi) integral (0,x) et-sq an
\&format(\$x,'nn') & Display or format \$x as nn where nn is nF or nE or nS and n is an integer. \\
\hline
+
+\$expr=\&math_calculus_expression() & Creates Math::Calculus::Expression object. Methods are: \$expr->addVariable('x'), \$expr->setExpression('f(x)'), \$expr->simplify, \$expr->getExpression -- see Math::Calculus::Expression documentation at cpan.org for details.\\
+\hline
\&prettyprint(\$x,'nn','optional target') & Note that that tag $<$num$>$ can be used to do the same thing. Display or format \$x as nn where nn is nF or nE or nS and n is an integer. Also supports the first character being a \$, it then will format the result with a a call to \&dollarformat() described below. If the first character is a , it will format it with commas grouping the thousands. In S mode it will fromat the number to the specified number of significant figures and display it in F mode. In E mode it will attempt to generate a pretty x10\^{}3 rather than a E3 following the number, the 'optional target' argument is optional but can be used to force \&prettyprint to generate either 'tex' output, or 'web' output, most people do not need to specify this argument and can leave it blank.\\
\hline
@@ -170,6 +173,10 @@ optional array of wrong answers that sho
Returns the ID of the current part.\\
\hline
+\&input\_id(part\_id, response\_id, textline\_id) &
+Returns the HTML id of the input field. This is useful in Javascript scripts to get a safe reference to a response textline field with \texttt{document.getElementById()}.\\
+\hline
+
Not implemented & Get and set the random seed. \\
\hline