## New Teaching Tools

Last Update: 17 May 2012

## Plotting mathematical functions

Here is a Java™ program that facilitates the graphical presentation of mathematical functions by SVG (Scalable Vector Graphics, the standard of the Internet Consortium). It needs elementary knowledge of Java™ and SVG.

Details of the algorithm used by the program were presented with animated graphics in a talk given at the SVGOpen2003 conference. People interested in applying the algorithm on a different platform (than java) and are using Internet Explorer with the plugin "Adobe SVG Viewer" could find interest in the section "A curve expressed as a Bezier path" of this talk.

## Catalog of functions expressed as Bezier quadratic paths

This catalog of functions expressed as Bezier quadratic paths was obtained by the program described at Plotting mathematical functions. In order to be able to use it, please read this explanatory file first.

Here are the links to the text files containing the Bezier paths of the functions:

cosh (cosine hyperbolic)
cosh-1 (1/cosh)
exponent (y=e^x)
hyperbola (x^2-y^2=1)
oneOverX (y=1/x)
sine (y=sin(x))
sinh (sine hyperbolic)
tangent (y=tan(x))
tanh (tangent hyperbolic)
xOnMn2 (y=1/(x^2))
xto4 (y=x^4)

## The cubic polynomial function expressed as a single Bezier cubic curve

Any given cubic polynomial:
y=a0+a1x+a2x2+a3x3 , where the indexed a's are real constants,
in the interval of x :   x0 ≤ x ≤ x0   with   χ>0 ,
can be expressed by a single Bezier cubic curve. The relation between the variable  x  and the parameter of the Bezier curve  t  is  t=(x−x0)/χ .

The cubic Bezier curve is defined by four points  Pn(Pnx ,  Pny)  with   n=0,1,2,3 ,
where P0x=x0 ,  P1x=x1=x0+(χ/3) ,  P2x=x2=x0+(2χ/3)  and  P3x=x3=x0 .
By denoting  yn=y(xn)  for  n=0,1,2,3 , one obtains
P0y=y0  and  P3y=y3  and for the control points :
P1y=-5y0 +18y1 -9y2 +2y3 ) / 6  and
P2y=2y0 -9y1 +18y2 -5y3 ) / 6 .

For the proof of this rule see the link.

## "Animathed Mathematics"

### A talk presented at the SVGOpen2003 conference

The talk introduces a teachware project of mathematics for science students of the first year. It contains SVG graphics and animations, which could be displayed by Internet Explorer with the plugin "Adobe SVG Viewer".

One can see the whole transcript of the talk and the actual slide show of the presentation.

## Math Animated™

### A courseware of math for first year university and college students

The project of the teachware (see "Animated Mathematics" - above) became in March 2005 a self consistent courseware of math for first year university and college students, containing calculus of one variable, and was hosted on the web at: http://mathanimated.com/.

For further details see Math Animated.

## Zoom and Pan

### Enhancing the scalability of the SVG graphics

In order to take advantage of the scalability of SVG, tools for observing enlarged details of the graphics are necessary. The ASV (Adobe SVG viewer) provides such tools, but they are still missing (January 2007) in the native support of the Firefox browser. On the other hand, Firefox supplies some software methods that are applicable for constructing the tools.

The file zoom-and-pan-controlsViewBox.svg of Jonathan Watt was used with Firefox as a starting point. Since the file did not satisfy in full the zooming and paning requirements, the file was modified by the aid of getScreenCTM() and the "onresize" event handler, not supported by ASV. In addition the "onzoom" and "onscroll" event handlers were omitted, and a couple of controls, for original view (canceling the zoom and pan) and for showing the centre of the zoom, were added. All the controls remain on focus, even if the viewport is resized.

Any one interested can copy, modify and use the proposed solution panZoom.svg. For obvious reasons it does not run with ASV, but was tested with Firefox.

Back to home