Description
Blanks questions are a form of free response question that can include multiple response objects in a single question. Blanks questions are limited in the fact that they accept only three types of response objects: text, menu, and formula. Each type is described below.
Notes
- Place a response object in a question
using the
\blank
macro. An optional argument specifies the type of blank. The required argument will be blanked out, and a response object (either a text entry cell or a drop-down menu) will be placed at that point in the question.\blank[text|menu|formula]{answer}
- Optional argument 1 must be one of the following:
-
- text
- A text blank.
This is the default. If the optional argument is omitted, it is assumed to betext
. - menu
- A menu blank; the response object will be a drop-down menu.
- formula
- A formula blank.
- answer
-
The correct answer.
- For [text] blanks, this argument should be the answer the student is expected to give.
- For [menu] blanks, this argument should be a
comma-delimited list of the options to appear in
the drop-down menu. The correct answer must be
the first item in the list.
If you need a comma to appear in one of the choices, use the ASCII escape sequence '%2c
'. - For [formula] blanks, this argument should be the answer the student is expected to give. Enter the answer in calculator syntax.
- Blanks must be exclusive of TeX math-mode content; blanks should not appear in math mode, and only raw text should be used in blanks.
- Notes for [menu] blanks
- In the drop-down menu of a [menu] blank, the choices will be scrambled for the student.
- This option is similar to Multiple Choice, but may be more convenient for some questions. However, the main difference is that only text choices are supported. TeX formatting may not be used in the list of choices.
- Notes for [formula] blanks
- The answer must be written in calculator syntax, not in TeX. Enter the answer as you would expect the student to enter it (although equivalent answers will be graded correctly).
- This option is similar to the Formula question type, but may be more convenient for some questions.
- If the answer is a number (i.e.,
does not have any variables), then it is a good idea to
specify whether an exact answer or an approximation is
expected. In the case of an approximation, the expected
accuracy must also be specified in the question. This
can be done in one of two ways:
- specify a certain fixed number of significant digits or a certain fixed number or digits after the decimal point, or
- specify a certain minimum accuracy, and use the
?
operator to grade answers that are within that accuracy. For example, if the answer field were\answer{2.34 ? 0.01}
then any response between 2.33 and 2.35 (inclusive) would be graded as correct. In other words, the number following the?
operator is the allowed error.
Warning: This use of formula-type blanks is not recommended; a much better choice would be to use a Numeric-mode blank in an Inline question.
Examples
\begin{question}{Blanks} \qutext{The first president of the United States was % Format: \blank{correct answer} \blank{George Washington}, and the first vice president was \blank{John Adams}.} \end{question}
\begin{question}{Blanks} \qutext{The first president of the United States was % Format: \blank[menu]{correct choice, other choices} \blank[menu]{George Washington, John Adams, John Hancock, Thomas Jefferson, James Madison}, and the first vice president was \blank[menu]{John Adams, George Washington, John Hancock, Thomas Jefferson, James Madison}.} \end{question}
\begin{question}{Blanks} \qutext{The derivative of the function $f(x)=4x-x^3$ is % Format: \blank[formula]{correct answer in calculator syntax} \blank[formula]{4-3x^2} and the second derivative is \blank[formula]{-6x}.} \end{question}
\begin{question}{Blanks} \qutext{The function $1-x^2$ is positive for values of $x$ in the range \blank[formula]{-1} $< x <$ \blank[formula]{1}.} \end{question}
\begin{question}{Blanks} \qutext{The maximum value of the function $f(x)=\displaystyle\frac{x}{1+2x^2}$ is \blank[formula]{0.353553 ? 0.0001} and the minimum value is \blank[formula]{-0.353553 ? 0.0001}. Your answers should be correct to an accuracy of at least 4 decimal places.} \end{question}
\begin{question}{Blanks} % This question mixes the [menu] and [formula] options. \qutext{The graph of the function $f(x)=(x-3)^2$ is the same as the graph of $g(x)=x^2$ shifted \blank[menu]{to the right, up} \blank[formula]{3} units.} \end{question}
\begin{question}{Blanks} % This question uses algorithmic variables. \qutext{An earthquake which measures $\var{a}$ on the Richter scale is \blank[formula]{\var{ans}} times more powerful than one which measures $\var{\var{a} - \var{inc}}$. Your answer should be exact.} \code{$a = range(5,9,0.01); $inc = range(2,4); $ans = int(10^$inc);} % The above code chooses a random value $a between 5 and 9, to two % significant figures.
\begin{question}{Blanks} % This question uses algorithmic variables. \qutext{The graph of the function $f(x)=\var{s1}\var{a}(x+\var{h})^2-\var{k}$ is the same as the graph of the function $g(x)=\var{s1}\var{a}x^2$ shifted \blank[menu]{to the left \var{h} units,to the right \var{h} units, up \var{h} units,down \var{h} units} and shifted \blank[menu]{down \var{k} units,up \var{k} units, to the right \var{k} units, to the left \var{k} units}.} \code{$s1 = if(rint(2),"","-"); $a = range(2,9); $h = range(2,9); $k = range(2,9);} % The above code chooses random integer coefficients between 2 and 9, % and allows the leading coefficient of the function f to be either % positive or negative. \end{question}
\begin{question}{Blanks} % This question uses algorithmic variables in the menu choices as well % as in the rest of the question. \qutext{In the \var{q} quadrant, the graph of $y=\var{c}(\var{a1})^x$ is \blank[menu]{\var{p1},\var{p2}} the graph of $y=\var{c}(\var{a2})^x$.} \code{$r = rint(2); $s = rint(2); $t = range(2,9); $q = switch($r,"first","second"); $p1 = switch($r+$s,"above","below","above"); $p2 = switch($r+$s,"below","above","below"); $c = range(2,30); $a = range(1.1,12.1,0.1); $a1 = switch($s,$a+$t,$a); $a2 = switch($s,$a,$a+$t);} \end{question}