Josh Thompson
Assistant Professor: Northern Michigan University

Hints for entering answers in WeBWork

Source: http://www.math.uwo.ca/~shafikov/teaching/winter2006/081/hw/howto_enter_answers.html

Mathematical Symbols Available in WeBWorK

  • + Addition
  • - Subtraction
  • * Multiplication
  • / Division
  • ^ or ** Raise to a power
  • All kinds of brackets and paretheses: (...), [...], {...}
  • Multiplication may also be indicated by a space or juxtaposition, that is, just writing symbols next to each other, e.g. \[2x, 2\mbox{ }x , 2*x, \mbox{ or } 2(x).\] To be on the safe side, you might wish to always use * for multiplication.

    Syntax for entering expressions

    Be careful entering expressions just as you would be careful entering expressions in a calculator. Sometimes using the * symbol to indicate multiplication makes things easier to read. For example \[(1+2)*(3+4) \mbox{ and } (1+2)(3+4)\] are both valid.

    Use brackets, braces and parenthesis to make your meaning clear.

  • Don't enter 2/4+5 (which is 5.5) if you mean 2/(4+5) (which is 2/9).
  • Don't enter 2/3*4 (which is 8/3) if you mean 2/(3*4) (which is 2/12).
  • Entering big quotients with square brackets, \[ [1+2+3+4]/[5+6+7+8] \] is a good practice.
  • Be careful when entering functions. It's always good practice to use parentheses when entering functions.

    Write sin(t) instead of sin t.

    But WeBWorK is smart enough to accept sin t or even sint. But sin 2t is really sin(2)t, i.e. (sin(2))*t. Be careful.

    Be careful entering powers of trigonometric, and other, functions.

    Write (sin(t))^2 for the square of sin(t) and never \sin^2t.

    Things in parentheses are always done first. Next all exponents are taken, then functions are evaluated,

    Remember that multiplication and division have the same precedence and there are no universal rules as to which should be done first in the absence of paretheses. WeBWorK and many computers read things from left to right, so \[ 2/3*4 \mbox{ means } (2/3)*4=8/3.\]

    The only way to make sure that you are entering what you want to enter is the use of parentheses!!!

    Use the "Preview Button" to see exactly how your entry looks. E.g. to tell the difference between 1+2/3+4 and [1+2]/[3+4] click the "Preview Button".

    If a problem calls for a decimal answer, give at least four decimal digits, or as many as the problem specifies, or the exact answer. For example, write 3.14159 instead of 3.14, or simply pi.

    Intervals in WeBWorK

    What is the domain of f(x)=sqrt(x)? One answer is x>=0 (x is greater than or equal to 0). One way to enter this in WeBWorK is in interval notation: [0,infinity).

    Other intervals:

  • (2,3] is the set \[2 < x <= 3\]
  • (-infinity,5) is the set \[x<5\]
  • (-infinity, infinity) is the set of all real numbers.
  • (2,3]U[4,5) is the set \[2 < x <= 3 \mbox{ or } 4<=x<5.\]
  • (This is a union of two intervals and can be very important.)

  • pi This gives 3.14159265358979
  • e This gives 2.71828182845905, e.g. \[ \ln(e) = 1 \]
  • Scientific Notation Available In WeBWorK

    2.1E2 gives 210 2.1E-2 gives .021

    Cube roots and such

    x^(1/3) gives the cube root of x

    Mathematical Functions Available In WeBWorK

  • abs( ): The absolute value
  • sqrt( ): The square root function
  • cos( ): The Cosine function. Note: cos( ) uses radian measure
  • sin( ): The Sine function. Note: sin( ) uses radian measure
  • tan( ): The Tangent function. Note: tan( ) uses radian measure
  • sec( ): The Secant function. Note: sec( ) uses radian measure
  • exp( ): The Exponential function. The same function as e^x
  • log( ): The natural log function
  • ln( ): Another name for the natural log
  • logten( ): The log to the base 10
  • arcsin( ), asin( ): name for arcsin
  • arccos( ), acos( ): Another name for arccos
  • arctan( ), atan( ): Another name for arctan
  • sgn( ): The sign function, either -1, 0, or 1
  • fact( ): The factorial function (defined only for non negative integers)
  • Using Interval Notation

    (Source: webwork.uwyo.edu/webworkdocs/IntervalNotation.html)   
    Links for Math 104