                   # Introduction

This applet allows you to experiment with Riemann sums and approximating the area between the x-axis, the graph of y = f(x), the vertical lines x = a and x = b. The user gets to specify the function f, the values of a and b and the number n of subintervals [a,b] is to be divided into. The user also specifies what kind of Riemann sum is to be used. The applet will then draw the graph of the function, and the rectangles corresponding to the partition and the kind of Riemann sum being used. For a more detailed explanation of the options, read further.

# Features

There are seven areas on the applet the user can interact with. They are listed below, along with an explanation. As the user puts the cursor into a field, a brief explanation of what to do will be displayed in the Messages area.

## Viewing Window Parameters.

In this area, the user specifies the range for the x and y-values. The default is that x and y are between -10 and 10. Any number as well as any expression resulting in a number can be used here. For example, when trigonometric functions are studied, the user may prefer to use multiples of pi such as 2*pi or 4*pi.

If "use y-range" is checked (the default), then both the x and y-range values are used. If it is unchecked, the applet will only use the x-range values and compute the corresponding range for the y-values.

The RESET ZOOM button is used to reset the x and y ranges to their default values.

## Function information

In this area, the user specifies the function to use. The syntax is the same as the one used in PlotSolve or the Java Math Pad. All the functions built into the system can be used. Also combinations of these functions by addition, subtraction, multiplication, division and composition can be used. Finally, the derivatives of functions can be used. Here are some possible examples:

• x^2-5*x
• xin(x^2)+cos(x)
• exp(x)-ln(x)
• sin(exp(x^2))
• diff(sin(x^2))

## Interval [a,b]

The user gets to specify the value of a, the left end point of the interval of study;b, the right end point of the interval of study and n, the number of subintervals. Two methods can be used to specify a. Either click on the corresponding field, and enter the value of a using the keyboard. Alternatively, click on the corresponding field, then click on the x-axis where a should be. The same possibility exists for b, except that you click on the field corresponding to b. n can only be entered using the keyboard.

## Riemann Sum

In this area, the user specifies what kind of Riemann sum to use from the choice list. There are five choices:

1. Upper. This computes the upper Riemann sum. Under this option, the height of the rectangles in each subinterval is the maximum value of the function in each subinterval. This gives an upper bound for the area below the graph.
2. Lower. This computes the lower Riemann sum. Under this option, the height of the rectangles in each subinterval is the minimum value of the function in each subinterval. This gives a lower bound for the area below the graph.
3. Midpoint. Under this option, the height of the rectangles in each subinterval is the value of the function at the midpoint of each subinterval.
4. Left. Under this option, the height of the rectangles in each subinterval is the value of the function at the left point of each subinterval.
5. Right. Under this option, the height of the rectangles in each subinterval is the value of the function at the right point of each subinterval.

Once the user has selected the kind of Riemann sum to use, its value will be displayed.

## Control Buttons

The PLOT button is used to plot the function after it has been entered.

The CLEAR ALL button erases all the areas. The applet will look as if you had just started it.

## Plot Area

This areas displays the graph of the function, as well as the rectangles approximating the area below the graph, according to the kind of Riemann sum being chosen. The only interaction with this area is via the mouse. The user can click near the x-axis to select a and b as explained above.

## Message Area

There is no interaction with this area. It is used to display hints on what the user should do next as well as error messages if the wrong operation is performed. Always look at what is displayed in this area.

## User Actions

The user can do the following:

1. Enter any function.

2. Specify the end points a and b of the interval of study by either entering their value using the keyboard or by clicking on the x-axis.

3. Specify the number of subintervals to use..

4. Specify the kind of Riemann sum to use..

# How to Use the Applet

Use the applet as follows:

1. If necessary, change the values in the Viewing Window Parameters area, though the default values should be fine in many cases.

2. Enter a function. Nothing can happen unless a function has been entered. Use the same syntax as in the PlotSolve or the Java Math Pad applets.

3. Next, specify the values of a, b and n if the default values are not adequate.

4. Finally, specify the kind of Riemann sum to use.

This applet was developed by Dr. Philippe B. Laval, at Kennesaw State University.
This work was funded in part by:
The National Science Foundation # DUE-9952568
The US Department of Education FIPSE #P116B00178  