summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-10-03 16:59:41 +0000
committerKarl Berry <karl@freefriends.org>2009-10-03 16:59:41 +0000
commitc4964f48405965ac9c70d20e44e681012cd34c7d (patch)
tree611fc2ed46601816964ba6c87d4123fe3fcedfd0 /Master/texmf-dist/doc/latex
parentb316efb7c226ec53ad21c090980220a4dacd15ff (diff)
new latex package rangen 1.3e (30sep09)
git-svn-id: svn://tug.org/texlive/trunk@15613 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex')
-rw-r--r--Master/texmf-dist/doc/latex/rangen/README37
-rw-r--r--Master/texmf-dist/doc/latex/rangen/doc/README.TEXLIVE6
-rw-r--r--Master/texmf-dist/doc/latex/rangen/examples/randomLIP.tex53
-rw-r--r--Master/texmf-dist/doc/latex/rangen/examples/randomQ.tex27
-rw-r--r--Master/texmf-dist/doc/latex/rangen/examples/randomR.tex44
-rw-r--r--Master/texmf-dist/doc/latex/rangen/examples/randomZ.tex38
-rw-r--r--Master/texmf-dist/doc/latex/rangen/examples/rangen_fp.tex24
-rw-r--r--Master/texmf-dist/doc/latex/rangen/examples/rangen_tst.tex280
8 files changed, 509 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/rangen/README b/Master/texmf-dist/doc/latex/rangen/README
new file mode 100644
index 00000000000..6ae2f48356d
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/README
@@ -0,0 +1,37 @@
+The rangen Package
+
+The rangen package is a package that generates random integers,
+rational numbers, and decimal number. Actually, the package uses the
+lcg package (by Erich Janka) to generate random integers, while
+rangen builds rational numbers and decimal numbers from the
+generated integers. My purpose in writing this package was to be
+able to create random questions for the quizzes of exerquiz (part of
+AeB). Indeed, that is what you can do with this package: Write a
+quiz question based on a template (for example, differentiate
+$\a x^{\n}$ , where \a and \n are RVs (random variables) generated with
+rangen); determine if the user input is correct; and display the
+correct answer to the question.
+
+Beta Testers wanted: The package is still in development. I would
+invite anyone interested to test the package, looking for bugs.
+Also, suggested features would be appreciated.
+
+The rangen package requires the insdljs package from AeB. The
+package can be used without exerquiz, perhaps there are some
+applications to the generation of random numbers. As pointed out in
+the documentation, the fp package can be used to manipulate the
+numbers created by rangen.
+
+The home page for rangen is
+
+ http://www.math.uakron.edu/~dpstory/rangen.html
+
+The home page for AeB is
+
+ http://www.math.uakron.edu/~dpstory/webeq.html
+
+Comments and suggestions are always gratefully accepted and seriously
+considered.
+
+D. P. Story
+09/30/09
diff --git a/Master/texmf-dist/doc/latex/rangen/doc/README.TEXLIVE b/Master/texmf-dist/doc/latex/rangen/doc/README.TEXLIVE
new file mode 100644
index 00000000000..68fd64ea249
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/doc/README.TEXLIVE
@@ -0,0 +1,6 @@
+The following files have been removed in the TeX Live installation of
+the current package, typically due to duplication, lack of space, or
+missing source code. You can find these files on CTAN. If questions or
+concerns, email tex-live@tug.org.
+
+ rangen_man.pdf
diff --git a/Master/texmf-dist/doc/latex/rangen/examples/randomLIP.tex b/Master/texmf-dist/doc/latex/rangen/examples/randomLIP.tex
new file mode 100644
index 00000000000..99170381509
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/examples/randomLIP.tex
@@ -0,0 +1,53 @@
+\documentclass{article}
+\usepackage[tight,designv]{web}
+\usepackage{insdljs}
+\usepackage[testmode,quiet]{rangen}
+%\usepackage[seed=30,quiet]{rangen}
+
+\parindent0pt\parskip6pt
+
+\begin{document}
+
+\RandomL{\a}{1,-1}$\texttt{\string\a}=\a, \cfmt\a x$
+
+\RandomP[index=5]{\a}{1,x,x^2,x^3}$\a$
+
+\RandomI{\indx}{5}
+\RandomP[index=\indx]{\q}{1+16,\cos(\pi),\pi\sin(\pi),\frac{d}{dx}\frac{1}{2}x^2,{\int \cos(x)\,dx}}
+
+$\displaystyle\q$
+
+\RandomI{\i}{2}\i
+\RandomP[index=\i]{\q}{1+16, \frac{d}{dx}\frac{1}{2}x^2}
+\RandomP[index=\i]{\a}{17,x}
+
+$ \q = \a $
+
+\RandomP{\q}{1+16,\frac{d}{dx}\frac{1}{2}x^2}
+\RandomP[index=\iOf\q]{\a}{17,x}
+
+$\displaystyle\q = \a $
+
+\RandomI{\i}{6}RandomI=\i
+
+\RandomL[index=1]{\a}{17,\rPI,3/4,\rE,88,1/2}\a\quad index=\iOf{\a}
+
+\RandomL[index=\i]{\a}{17,\rPI,3/4,\rE,88,1/2}\a\quad index=\iOf{\a}
+
+\RandomL{\a}{17,\rPI,3/4,\rE,88,1/2}\a\quad index=\iOf{\a}
+
+In practice, \verb!\RandomI! can be used to select one of n problems. Here, we have
+selected the
+\RandomI{\i}{6}
+\ifcase\i\relax\or
+first\or
+second\or
+third\or
+fourth\or
+fifth\or
+sixth\fi\space problem.
+
+
+
+
+\end{document}
diff --git a/Master/texmf-dist/doc/latex/rangen/examples/randomQ.tex b/Master/texmf-dist/doc/latex/rangen/examples/randomQ.tex
new file mode 100644
index 00000000000..ec2a9081a6f
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/examples/randomQ.tex
@@ -0,0 +1,27 @@
+\documentclass{article}
+\usepackage[dvipsone]{insdljs}
+\usepackage[testmode,quiet]{rangen}
+
+
+\parindent0pt\parskip6pt
+
+\begin{document}
+
+\RandomQ{\a}[16]{1/8}{3/7}$ 1/8 \le \a \le 3/7 $
+
+\RandomQ{\b}[7]{\a}{15/16}$\a \le \b$
+
+\RandomQ[ne={0,-1}]{\n}{-3}{2/3}$x^{\efmt\n}$
+
+
+\defineQ{\a}{5}{3}\RandomQ{\b}[8]{\a*}{10}$ \a < \b $
+
+\RandomQ{\a}[8]{1}{5}\RandomQ{\b}[8]{\a}{10}$ \a \le \b $
+
+\RandomQ{\a}[8]{1}{5}\RandomQ{\b}[8]{1}{\a*}$ \a > \b $
+
+\RandomQ{\a}[2]{1}{5}\RandomQ{\b}[8]{1}{\a}$ \a \ge \b $
+
+\RandomQ{\a}[2]{1}{5}$\ifnum\typeOf\a=0\relax\cfmt\a\else(\cfmt\a)\fi x$
+
+\end{document}
diff --git a/Master/texmf-dist/doc/latex/rangen/examples/randomR.tex b/Master/texmf-dist/doc/latex/rangen/examples/randomR.tex
new file mode 100644
index 00000000000..69f2f2ba1a5
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/examples/randomR.tex
@@ -0,0 +1,44 @@
+\documentclass{article}
+\usepackage[tight,designv]{web}
+\usepackage{insdljs}
+\usepackage[testmode,quiet]{rangen}
+
+\parindent0pt\parskip6pt
+
+\begin{document}
+
+\RandomR{\a}{-2.3}{2.3}\a
+
+\RandomL{\a}{17,\rPI,3/4,\rE,88,1/2}
+
+Choose at random a number from the list \verb!{17,\rPI,3/4,\rE,88,1/2}!:
+The choice is $\texttt{\a}$
+
+\rule{\linewidth}{.4pt}
+
+
+\defineR{\a}{-4.5}\defineR{\b}{5.343}
+
+\RandomR[round=2,showzeros]{\c}{\a}{\b}
+
+Random Real from the interval \texttt{[\a, \b ]} is \texttt{\c}
+
+\RandomR[round=2]{\a}{0}{10}\RandomR[round=2]{\b}{0}{12}
+
+\RandomR[round=2]{\c}{\a}{\b}
+
+A random Real taken from a random interval \texttt{[\a, \b ]} is \texttt{\c}
+
+
+\rule{\linewidth}{.4pt}
+
+
+\RandomR[round=2,showzeros]{\b}{0}{9.5}
+\RandomR[round=2]{\a}{-3}{\b}
+
+We require \verb!\b! to be greater than \texttt{\string\a}:
+$ \texttt{\string\b=\b} > \texttt{\a=\string\a} $
+
+$\texttt{\string\a}=\a\approx\nOf{\a}/\dOf{\a}$
+
+\end{document}
diff --git a/Master/texmf-dist/doc/latex/rangen/examples/randomZ.tex b/Master/texmf-dist/doc/latex/rangen/examples/randomZ.tex
new file mode 100644
index 00000000000..233b8efd162
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/examples/randomZ.tex
@@ -0,0 +1,38 @@
+\documentclass{article}
+\usepackage[dvipsone]{insdljs}
+\usepackage[testmode,quiet]{rangen}
+
+
+
+\parindent0pt\parskip6pt
+
+\begin{document}
+
+\RandomZ[ne={0,-1}]{\n}{-2}{2}$x^{\efmt\n}$
+
+\RandomZ[ne=\zZero]{\b}{-1}{1}
+The value of \texttt{\string\b=\b} and should be
+different from zero. Is it?
+
+\RandomZ{\a}{1}{5}\RandomZ{\b}{\a*}{10}$ \a < \b $
+
+\RandomZ{\a}{1}{5}\RandomZ{\b}{\a*}{10}$ \a \le \b $
+
+\RandomZ{\a}{1}{5}\RandomZ{\b}{1}{\a*}$ \a > \b $
+
+\RandomZ{\a}{1}{5}\RandomZ{\b}{1}{\a}$ \a \ge \b $
+
+\RandomZ[ne=0]{\b}{-1}{1}Is \texttt{\string\b}=\b\space zero?
+
+\RandomL{\a}{-2,4,6,-12,9,5,17}Select a number from a list \texttt{\string\a=\a}
+
+\RandomS{\si}\RandomS{\sii}
+\RandomZ[ne=0]{\a}{-5}{5}
+\RandomZ[ne=0]{\b}{1}{5}
+\RandomZ[ne=0]{\c}{1}{5}
+\RandomZ[ne=0]{\n}{1}{5}
+
+$ \cfmt\a x^{\efmt\n} \si \cfmt\b x \sii \c $
+
+
+\end{document}
diff --git a/Master/texmf-dist/doc/latex/rangen/examples/rangen_fp.tex b/Master/texmf-dist/doc/latex/rangen/examples/rangen_fp.tex
new file mode 100644
index 00000000000..e7e4fcffdaf
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/examples/rangen_fp.tex
@@ -0,0 +1,24 @@
+\documentclass{article}
+\usepackage[tight,dvipsone,designv,nodirectory]{web}
+\usepackage{insdljs}
+\usepackage[testmode,quiet]{rangen}
+\usepackage{fp}
+
+\parindent0pt\parskip6pt
+
+\begin{document}
+
+\RandomQ{\a}[6]{2}{4}\RandomQ{\b}[6]{2}{4}\RandomS{\thisop}
+\gcd{\dOf\a}{\dOf\b}
+\FPeval\lcd{clip((\dOf\a)*(\dOf\b)/\thegcd)}
+\FPeval\si{clip(\lcd/(\dOf\a))}
+\FPeval\sii{clip(\lcd/(\dOf\b))}\def\thisop{+}
+\if\thisop+\FPeval\finalnum{clip((\si)*(\nOf\a)+(\sii)*(\nOf\b))}
+\else\FPeval\finalnum{clip((\si)*(\nOf\a)-(\sii)*(\nOf\b))}\fi
+\defineQ{\ans}{\finalnum}{\lcd}
+$$
+\ds\a \thisop \ds\b = \frac{(\si)(\nOf\a)+(\sii)(\nOf\b)}{\lcd}
+ = \frac{\finalnum}{\lcd}\ifnum\lcd=\dOf\ans\else =\ds\ans\fi
+$$
+
+\end{document}
diff --git a/Master/texmf-dist/doc/latex/rangen/examples/rangen_tst.tex b/Master/texmf-dist/doc/latex/rangen/examples/rangen_tst.tex
new file mode 100644
index 00000000000..217065c0e46
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/rangen/examples/rangen_tst.tex
@@ -0,0 +1,280 @@
+\documentclass{article}
+\usepackage[fleqn]{amsmath}
+\usepackage[tight,dvipsone,designiii,nodirectory,usesf]{web}
+\usepackage{exerquiz}
+\usepackage[equations,ImplMulti,indefIntegral,limitArith,nodec]{dljslib}
+\usepackage[quiet,testmode]{rangen}
+
+\title{Experiments in Creating Random Problems}
+\author{D. P. Story}
+\subject{Test file for the rangen Package}
+\keywords{LaTeX, rangen, quizzes, random}
+
+\university{NORTHWEST FLORIDA STATE COLLEGE\\
+ Department of Mathematics}
+\email{dpstory@acrotex.net}
+\version{1.0}
+
+%\nocopyright
+\norevisionLabel
+\makeatletter
+\def\eq@textFont{/TiRo}
+\makeatother
+
+\everyTextField{\BG{1 1 1}}
+\everyCheckBox{\BG{1 1 1}}
+\everyRespBoxMath{\rectW{1.9in}\textSize{0}}
+\everyRespBoxTxt{\rectW{1.9in}\textSize{0}}
+
+\newcommand{\cs}[1]{\texttt{\char`\\#1}}
+
+\renewcommand\nodecAlertMsg{%
+ "A decimal answer is not acceptable here.
+ Please express your answer using a fraction."}
+\newenvironment{eqComments}[1][\strut]{\smallskip\leftskip-\labelwidth
+\item[]\textbf{\textcolor{blue}{#1}}}{\par\smallskip}
+
+\begin{document}
+
+\maketitle
+
+\begin{shortquiz}*[sq] Answer each of the following. Passing is 100\%.
+
+\begin{questions}
+
+\begin{eqComments}[Arithmetic]\end{eqComments}
+
+%% addition
+\RandomQ{\a}[9]{1/8}{6/7}\RandomQ{\b}[8]{1/16}{15/16}
+
+\item $\displaystyle \ds\a + \ds\b =
+ \RespBoxMath{ (\nOf\a * \dOf\b + \nOf\b * \dOf\a )/( \dOf\a * \dOf\b ) }{2}{.0001}{[0,2]}[{priorParse: \Array(nodec,NoAddOrSub)}]$\hfill
+ \CorrAnsButton{rFrac( rEval( \nOf\a * \dOf\b + \nOf\b * \dOf\a )/rEval( \dOf\a * \dOf\b ) )}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+% subtraction
+\RandomQ{\a}[16]{1/16}{15/16}\RandomQ[ne=\a]{\b}[16]{1/8}{15/16}
+
+\item $\displaystyle \ds\a - \ds\b =
+ \RespBoxMath{ (\nOf\a * \dOf\b - \nOf\b * \dOf\a )/( \dOf\a * \dOf\b ) }{2}{.0001}{[0,2]}[{priorParse: \Array(nodec,NoAddOrSub)}]$\hfill
+ \CorrAnsButton{rFrac( rEval( \nOf\a * \dOf\b - \nOf\b * \dOf\a )/rEval( \dOf\a * \dOf\b ) )}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+% subtraction
+\RandomQ{\a}[16]{1/8}{15/16}\RandomQ[ne=\a]{\b}[16]{1/8}{15/16}
+
+\item $\displaystyle \ds\a - \ds\b =
+ \RespBoxMath{ (\nOf\a * \dOf\b - \nOf\b * \dOf\a )/( \dOf\a * \dOf\b ) }{2}{.0001}{[0,2]}[{priorParse: \Array(nodec,NoAddOrSub)}]$\hfill
+ \CorrAnsButton{rFrac( rEval( \nOf\a * \dOf\b - \nOf\b * \dOf\a )/rEval( \dOf\a * \dOf\b ) )}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\begin{eqComments}
+This next problem illustrates the use of \cs{RandomL} and \cs{RansomAS}. The summands are
+determined from a list of rational numbers. Addition or subtraction of the summands is determined
+by \cs{RandomAS}.
+\end{eqComments}
+
+%% Random add/subtr using RandomL and RandomAS
+\RandomL{\a}{1/2,2/3,5/3,2/5,6/5}\RandomL{\b}{4/3,3/4,8/7,3/2}\RandomS{\as}
+
+\item $\displaystyle \ds\a \as \ds\b =
+ \RespBoxMath{ (\nOf\a * \dOf\b \as \nOf\b * \dOf\a )/( \dOf\a * \dOf\b ) }{2}{.0001}{[0,2]}[{priorParse: \Array(nodec,NoAddOrSub)}]$\hfill
+ \CorrAnsButton{rFrac( rEval( \nOf\a * \dOf\b \as \nOf\b * \dOf\a )/rEval( \dOf\a * \dOf\b ) )}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+
+\begin{eqComments}
+This next example illustrates how you can create a solution to a problem. This is a simple
+addition problem using the built-in command \cs{qAdd}. Solutions to more advanced problems
+might be obtained using the \textsf{fp} package.
+\end{eqComments}
+
+\begin{writeRVsTo}{quizzes}
+\RandomQ{\a}[9]{1/8}{6/7}\RandomQ{\b}[7]{1/16}{15/16}
+\end{writeRVsTo}
+
+%% addition
+\item $\displaystyle \ds\a + \ds\b =
+ \RespBoxMath{ (\nOf\a * \dOf\b + \nOf\b * \dOf\a )/( \dOf\a * \dOf\b ) }*{2}{.0001}{[0,2]}[{priorParse: \Array(nodec,NoAddOrSub)}]$\hfill
+ \CorrAnsButton{rFrac( rEval( \nOf\a * \dOf\b + \nOf\b * \dOf\a )/rEval( \dOf\a * \dOf\b ) )}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\begin{solution}\relax\RNGadd\a\b\defineQ{\ans}{\rfNumer}{\rfDenom}%
+The solution to this problem is
+\begin{equation*}
+ \boxed{\ds\a + \ds\b = \ds\ans}
+\end{equation*}
+\end{solution}
+
+
+\newpage
+\begin{eqComments}[Definite Integrals]\end{eqComments}
+
+\RandomQ{\a}[8]{1/4}{7/6}
+\RandomZ{\b}{1}{3}
+\RandomQ{\n}[8]{1/2}{3/2}
+\RandomZ[ne=0]{\c}{-3}{3}
+
+\item $\displaystyle\int_{\a}^{\b} \cfmt\c x^{\efmt\n}\,dx =
+ \RespBoxMath{\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rEval(\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1))}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+
+\RandomQ{\a}{1/6}{2/9}
+\RandomZ{\b}{1}{10}
+\RandomQ[ne={0,-1}]{\n}[5]{-1}{1}
+\RandomZ[ne=0]{\c}{-3}{3}
+
+\item $\displaystyle\int_{\a}^{\b} \cfmt\c x^{\efmt\n}\,dx =
+ \RespBoxMath{\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rEval(\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1))}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\RandomZ{\a}{1}{6}
+\RandomZ{\b}{\a*}{8}
+\RandomZ{\n}{1}{5}
+\RandomZ[ne=0]{\c}{-3}{3}
+
+\item $\displaystyle\int_{\a}^{\b} \cfmt\c x^{\efmt\n}\,dx =
+ \RespBoxMath{\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rFrac(rEval(\c ( (\b)^(\n+1)-(\a)^(\n+1)))/rEval(\n+1))}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\RandomZ{\a}{1}{5}
+\RandomZ{\b}{\a*}{10}
+\RandomQ[ne={0,-1}]{\n}{-3}{2/3}
+\RandomZ[ne=0]{\c}{-3}{3}
+
+\item $\displaystyle\int_{\a}^{\b} \cfmt\c x^{\efmt\n}\,dx =
+ \RespBoxMath{\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rEval(\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1))}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\RandomQ{\a}{1/4}{2/3}
+\RandomQ{\b}{\a*}{7/6}
+\RandomQ[ne={0,-1}]{\n}{-3}{2/3}
+\RandomZ[ne=0]{\c}{-3}{3}
+
+\item $\displaystyle\int_{\a}^{\b} \cfmt\c x^{\efmt\n}\,dx =
+ \RespBoxMath{\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rEval(\c((\b)^(\n+1)-(\a)^(\n+1))/(\n+1))}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\begin{eqComments}
+This next problem was created from random lists of values using \cs{RandomL}.
+\end{eqComments}
+
+\RandomL{\c}{1/6,1/4,1/6,1/2}
+\RandomL{\a}{1,2,3,4,5,6}
+\ifnum\a=1
+ \def\strAns{sin(PI/\dOf\c)}
+\else
+ \def\strAns{(1/\a)(sin(\a*PI/\dOf\c))}
+\fi
+
+\item $\displaystyle\int_0^{\pi/\dOf\c} \cos(\cfmt\a x) \,dx =
+ \RespBoxMath{(1/\a)(sin(\a*PI/\dOf\c))}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rEval(\strAns)}*{rngCorrAnsButton\RNGprintf{\%.4f}}\kern1bp\sqTallyBox
+
+
+\newpage
+\begin{eqComments}[Indefinite Integration]\end{eqComments}
+
+\RandomQ{\a}{1/6}{3/2}
+\RandomQ{\b}{1/6}{3/2}
+\RandomZ{\c}{1}{3}
+
+\item $\displaystyle\int \cds\a x^2 + \ds\b x + \c\,dx =
+ \RespBoxMath{(\a/3)x^3+(\b/2) x^2 + \c x}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{(rFrac(rEval(\nOf\a)/rEval(3*\dOf\a))) x^3
+ + (rFrac(rEval(\nOf\b)/rEval(2*\dOf\b))) x^2
+ + \c x + C}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\RandomQ{\a}{1/3}{3}
+\RandomQ{\b}{1/6}{3/2}
+\RandomZ{\c}{1}{3}
+
+\item $\displaystyle\int \cds\a x^2 + \ds\b x + \c\,dx =
+ \RespBoxMath{(\a/3)x^3+(\b/2) x^2 + \c x}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{(rFrac(rEval(\nOf\a)/rEval(3*\dOf\a))) x^3
+ + (rFrac(rEval(\nOf\b)/rEval(2*\dOf\b))) x^2
+ + \c x + C}*{rngCorrAnsButton}\kern1bp\sqTallyBox
+
+\newpage
+\begin{eqComments}[Differentiation]\end{eqComments}
+
+\RandomQ[ne=0]{\c}[4]{-2}{2}
+\RandomQ[ne=0]{\n}[1]{-3}{2}
+
+\item $\displaystyle \frac{d}{dx} \cds\c x^{\efmt\n} =
+ \ifnum\nOf\n=\dOf\n
+ \RespBoxMath{\c}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rFrac(\nOf\c/\dOf\c)}*{rngCorrAnsButton}%
+ \else
+ \RespBoxMath{\c*\n*x^(\n-1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rFrac(rEval(\nOf\c*\nOf\n)/rEval(\dOf\c*\dOf\n))
+ x^(rFrac(rEval(\nOf\n-\dOf\n)/\dOf\n))}*{rngCorrAnsButton}%
+ \fi
+ \kern1bp\sqTallyBox
+
+\begin{eqComments}
+This next problem uses a random sign, defined by \cs{RandomS}.
+\end{eqComments}
+
+\RandomQ{\c}[4]{2}{3}\RandomS{\s}
+\RandomQ[ne=0]{\n}[2]{-3}{2}
+
+\item $\displaystyle \frac{d}{dx} \cfmt\s\ds\c x^{\efmt\n} =
+ \ifnum\nOf\n=\dOf\n
+ \RespBoxMath{\s\c}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{\s\nOf\c/\dOf\c}*{rngCorrAnsButton}%
+ \else
+ \RespBoxMath{\s\c*\n*x^(\n-1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rFrac(rEval(\s\nOf\c*\nOf\n)/rEval(\dOf\c*\dOf\n))
+ x^(rFrac(rEval(\nOf\n-\dOf\n)/\dOf\n))}*{rngCorrAnsButton}%
+ \fi
+ \kern1bp\sqTallyBox
+
+
+\RandomQ[ne=0]{\c}[4]{-2}{5}
+\RandomQ{\n}[4]{2}{5}
+
+\item $\displaystyle \frac{d}{dx} \ds\c x^{\efmt\n} =
+ \ifnum\nOf\n=\dOf\n
+ \RespBoxMath{\c}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{\nOf\c/\dOf\c}*{rngCorrAnsButton}%
+ \else
+ \RespBoxMath{\c*\n*x^(\n-1)}{3}{.0001}{[0,2]}$\hfill
+ \CorrAnsButton{rFrac(rEval(\nOf\c*\nOf\n)/rEval(\dOf\c*\dOf\n))
+ x^(rFrac(rEval(\nOf\n-\dOf\n)/\dOf\n))}*{rngCorrAnsButton}%
+ \fi
+ \kern1bp\sqTallyBox
+
+\newpage
+
+\begin{eqComments}[Analytic Geometry]\end{eqComments}
+
+\RandomZ{\a}{-10}{9}
+\RandomZ{\b}{-10}{9}
+\RandomZ{\c}{\a*}{10}
+\RandomZ{\d}{\b*}{10}
+\defineDepQJS{\m}{\d - \b}{\c - \a}{rFrac(rEval(\nOf\m)/rEval(\dOf\m))}
+\defineDepQJS{\yIntercept}{\b - \a*\m}{1}{rFrac((rEval( \b * \dOf\m - \a*\nOf\m ))/(rEval(\dOf\m)))}
+
+
+\item Let $P(\,\a, \b\,)$ be a point and $Q(\,\c, \d\,)$ be a point. Find the equation of the line that
+ passes through $P$ and $Q$.\par\kern3pt
+ \RespBoxMath{y = \m*x + \yIntercept }(xy){3}{.0001}{[0,2]x[0,2]}*{ProcRespEq}\hfill
+ \CorrAnsButton{y = \js\m\space x + \js\yIntercept}*{rngCorrAnsButton}%
+ \kern1bp\sqTallyBox
+
+\RandomZ{\a}{-10}{9}
+\RandomZ{\b}{-10}{9}
+\RandomZ{\c}{\a*}{10}
+\RandomZ{\d}{\b*}{10}
+\defineDepQJS{\m}{\d - \b}{\c - \a}{rFrac(rEval(\nOf\m)/rEval(\dOf\m))}
+\defineDepQJS{\yIntercept}{\b - \a*\m}{1}{rFrac((rEval( \b * \dOf\m - \a*\nOf\m ))/(rEval(\dOf\m)))}
+
+\item Let $P(\,\a, \b\,)$ be a point and $Q(\,\c, \d\,)$ be a point. Find the equation of the line that
+ passes through $P$ and $Q$.\par\kern3pt
+ \RespBoxMath{y = \m*x + (\b - \a*\m) }(xy){3}{.0001}{[0,2]x[0,2]}*{ProcRespEq}\hfill
+ \CorrAnsButton{y = \js\m\space x + \js\yIntercept}*{rngCorrAnsButton}%
+ \kern1bp\sqTallyBox
+
+\end{questions}
+\end{shortquiz}
+\begin{flushright}
+\sqClearButton\kern1bp\sqTallyTotal
+\end{flushright}
+\end{document}