## LinearApprox Applet

LinearApprox is used to illustrate the idea of a linear function approximating another function. It graphs the original function, a tangent line linear approximation, and a vertical line segment to illustrate the error. In this applet, "a" is the x coordinate of the point of tangency.

The applet tag that creates the applet is as follows:

<applet code="net.sourceforge.webcompmath.calculus.LinearApprox" codebase="../../assets"

archive="webcompmath.jar,calculus.jar" height="400" width="450">

<param name="Example1" value="1. A Parabola;x^2;-1,3,-1,3;400;400;1.5;1" />

<param name="Example2" value="2. A Sine Curve;sin(x);-6.28,6.28,-2,2;1256;1256;1;0" />

<param name="Example3" value="3. Different Tangent on the Same Sine Curve;sin(x);-3.14,6.28,-1,3;942;942;1;1.5708" />

</applet>

This applet takes the following parameters:

Param NameTypeDefaultDescriptionExample1, ...String N/A Each example is a list of strings separated by semicolons. The strings, in order, are:

1. The name of the example, displayed in the example menu.

2. The expression for f(x), the function.

3. The xmin, xmax, ymin, and ymax to use for the graph, as a list of comma-separated numbers.

4. The number of steps for the x slider. The slider min and max are the same as the graph window's xmin and xmax.

5. The number of steps for the a slider. The slider min and max are the same as the graph window's xmin and xmax.

6. The value for x.

7. The value for a.