Entering Functions
Entering Functions
The Basics:
Basically, the applet will display the graphs of up to four
functions at once. You type a function in one of the input fields
beneath the graphing area, and press the <Enter> or
<Return> key on your keyboard. If you are used to entering
functions in a graphing calculator, entering functions in the
graphing applet should pose no problems for you.
Variables:
The applet recognizes only the variables "x" and "y". X is assumed
to be the independent variable and is graphed on the horizontal axis,
and y is assumed to be the dependent variable and is graphed on the
vertical axis.
Arithmetic Operators:
The applet uses the standard arithmetic operators:
- "+" for addition
- "-" for subtraction
- "*" for multiplication. Implied multiplication is supported.
In other words, you may type "3*x" or "3x" to mean "three times
x".
- "/" for division
- "^" for exponentiation
- "()" - parentheses group symbols to indicate order of
operations, as in standard algebra. The "normal" order of
operations is observed in expressions - multiplications and
divisions first, then additions and subtractions. This order can
be changed using parentheses. That is, the expression " 2*3 + 4"
evaluates to 10, while the expression "2*(3 + 4)" evaluates to
14.
Built-In Functions:
The applet supports several elementary functions, including:
- Algebraic/Arithmetic Functions:
- abs(expression) - returns the absolute value
of its argument, which may be any real-valued expression.
- int(expression) - returns the greatest
integer less than or equal to the value of the
argument.
- pi - returns the constant p.
(This function has no parentheses nor
argument.)
- rnd - returns a random number in the range
(0, 1)
- rni(start expression, end expression) - returns a
random integer in the range [start expression, end
expression]
- sqr(expression) or sqrt(expression) -
returns the square root of its argument.
- Trigonometric Functions - arguments are in radians.
- cos(expression) - returns the cosine of its
argument.
- cot(expression) - returns the cotangent of
its argument.
- csc(expression) - returns the cosecant of its
argument.
- sec(expression) - returns the secant of its
argument.
- sin(expression) - returns the sine of its
argument.
- tan(expression) - returns the tangent of its
argument.
- Exponential & Logarithmic Functions
- exp(expression) - returns the value
eexpression, where "e" is the base of the
natural logarithms, and the argument can be any real-valued
expression.
- ln(expression) - returns the value of the natural
logarithm function.
- log(base, expression) - returns the logarithm
(logbaseexpression) of the expression to the
given base.
- Inverse Trigonometric Functions
- aco(expression) or acos(expression) -
returns the arccosine (inverse cosine) of its
argument.
- acot(expression) returns the arccotangent
(inverse cotangent) of its argument.
- acsc(expression) returns the arccosecant
(inverse cosecant) of its argument.
- asec(expression) returns the arcsecant
(inverse secant) of its argument.
- asi(expression) or asin(expression) -
returns the arcsine (inverse sine) of its argument.
- atan(expression) - returns the arctangent
(inverse tangent) of its argument.
- Hyperbolic Functions
- cosh(expression) - returns the hyperbolic cosine
of its argument.
- coth(expression) - returns the hyperbolic
cotangent of its argument.
- csch(expression) - returns the hyperbolic
cosecant of its argument.
- sech(expression) - returns the hyperbolic
secant of its argument
- sinh(expression) - returns the hyperbolic sine
of its argument.
- tanh(expression) - returns the hyperbolic tangent
of its argument.
- Inverse Hyperbolic Functions
- icoh(expression) - returns the inverse hyperbolic
cosine (cosh-1) of its argument.
- icth(expression) - returns the inverse hyperbolic
cotangent (coth-1) of its argument.
- icsh(expression) - returns the inverse hyperbolic
cosecant (csch-1) of its argument.
- iseh(expression) - returns the inverse hyperbolic
secant (sech-1) of its argument
- isih(expression) - returns the inverse hyperbolic
sine (sinh-1) of its argument.
- itah(expression) - returns the inverse hyperbolic
tangent (tanh-1) of its argument.
Turning Graphs On/Off:
You can use the checkbox to the left of the function to turn the
graph of particular functions on and off.
X-Scan & Y-Scan
If X-Scan is checked, the program will sketch curves that are
more-or-less vertical pretty well, but will tend to skip a lot of
points across lines that are more-or-less horizontal (See "How
It Works"). Y-Scan will draw the more-or-less horizontal parts of
a curve pretty well, but not the more-or-less vertical parts. You may
want to get the viewing rectangle you
want, then check both X-Scan and Y-Scan to get the best graph.
This feature has no effect on the graph of an explicit (y = f(x))
function.
Syntax Errors:
If you make a mistake typing your function, the program will
ignore the input and display a "syntax error" message in the message
area to the right of the graph display. At the moment, this message
is not very helpful in identifying your error - I'm working on
that.
last update April 14, 2008 by JL
Stanbrough