Flash and Math Applets: Learn by Example

Programming in ActionScript 3 for Mathematics and Science Teaching and Learning

by Douglas Ensley and Barbara Kaskosz


About the book


Chapter 1. Basics of Flash and ActionScript

MovieClip Motion

Try it:ClipMotion.html

Sprite Motion

Try it:SpriteMotion.html


Chapter 2. Textboxes and Keyboard Events

Basic Arithmetic Activity

Try it:ArithmeticBasic.html

Using the Visibility Property

Try it: ArithmeticVisibility.html

Manipulating Listeners for Control Flow

Try it: ArithmeticListeners.html

Listening for Keyboard Events

Try it: ArithmeticKeyboard.html

Adding a Timer

Try it: ArithmeticTimer.html

Sprite Motion, Revisited

Try it:SpriteKeyMotion.html


Chapter 3. MovieClips, Sprites, and Shapes

Circular Motion with MovieClips

Try it:CircleMotion.html

Circular Motion with Sprites and Shapes at Run Time

Try it:CircleMotionSprite.html

Filling graphics for Shaded Area

Try it: CircleFillSprite.html

More on the Display List and Coordinate Systems

Try it: ParentChild.html

Note: The source file (fla) for this applet is not included in the book's download folder. It serves as an interactive illustration to explain the parent/child relationship, not a programming example. With that disclaimer, anyone who would really like the source file for this applet can e-mail doug@flashandmath.com to get it.


Chapter 4. More Mouse Events

Getting Mouse Coordinates

Try it: LineSegment.html

The Drag and Drop Interface

Try it: TriangleDrag.html

Drawing with a Mouse

Try it: MouseDraw.html


Chapter 5. Simple Animation

Animation using the ENTER_FRAME event

Try it: BounceEnterFrame.html

Animation using the Timer class

Try it: BounceTimer.html

Animation using the Tween class

Try it: GameSpinner.html

The “Repeat Effect” for Buttons

Try it: CircleFillRepeat.html


Chapter 6. Parsing Data and Drawing Charts

Creating a Simple Histogram

Try it: Histogram.html

Creating a Pie Chart from Data

Try it: PieChart.html

Creating Textboxes at Runtime

Try it: PieChartText.html or HistogramText.html

Scatter Plot Application

Try it: ScatterPlot.html


Chapter 7. A First Look at Components

ColorPicker, Slider and NumericStepper Components

Try it: MouseDrawComp.html

Using the Slider Component to Control Motion

Try it: CircleFillSlider.html

The DataGrid component: ScatterPlot revisited

Try it: DataGridScatter.html


Chapter 8. Components for Quizzes

RadioButton component for multiple choice questions

Try it: MultipleChoice.html

CheckBox component for multiple answer questions

Try it: MultipleAnswer.html

ComboBox component for matching problems

Try it: FamousBooks.html


Chapter 9. Applications of Masking

Masking in ActionScript 3

Try it: EZMask.html

Regression Line Application

Try it: ScatterPlotLine.html

Area under a Curve Application

Try it: AreaMask.html


Chapter 10. A Simple Function Grapher

Part 1. Drawing the Sine Function

Try it: SinGraph.html

Try it: SinGraphCS4.html

Part 2. Masking and Wrapping at Infinity

Try it:SinExpGraph.html

Part 3. Error Checking in Range Input

Try it:GraphCheckRange.html

Part 4. Using the Custom MathParser class

Try it:GraphParsed.html


Chapter 11. Bread and Butter Graphing Applets

Tracing a Point or Tangent Line on a Curve

Try it:GraphTrace.html

Try it:GraphTan.html

Showing Area under a Curve

Try it:GraphArea.html

Animating a Family of Functions

Try it:AnimatedFamily.html


Chapter 12. Using the FlashandMath Custom Classes

Download the flashandmath custom classes here: flashandmath.zip

Place the unzipped flashandmath folder in the same directory as the fla file for which you are using the custom classes.

Simple Computation with the MathParser Class

Try it:Computation.html

A Short Answer Quiz using the MathParser Class

Try it:AnswerChecking.html

The SimpleGraph Class: A First Example

Try it:VerticalDistance.html

Custom Appearance with the GraphingBoard Class

Try it:VerticalDistance2.html

The drawGraph Method for a Derivative Grapher

Try it:DerivativeGrapher.html

Using the RangeParser Class for a Polar Plotter

Try it:GraphPolar.html

Try it:GraphParam.html


Chapter 13. Importing External Content at Authoring Time and Run Time

Interactive Map with Imported Graphics

Try it:InteractiveMap.html

Importing LaTeX Output for Mathematical Notation

Try it:LateXSWFDemo.html

Note: The example LateXSWF.fla referenced in the book contains only the imported swf from Troy Henderson's LaTeX2SWF utility. The example above adds a Numeric Stepper component and five lines of code to illustrate the idea of "scalability." The source code LateXSWFDemo.fla is included in the book's download folder.

Working with Flash Video

Try it:SimpleVideo.html

Simple Slide Show: Importing Content at Run Time

Try it:SlideShow.html

Adding Simple Sounds

Try it:SlideShowSound.html

Loading Multiple Images

Try it:SlideShowTimer.html


Chapter 14. Working with External XML Files

Using XML to Initialize an Application

Try it:GraphPolarXML.html

Adding an XML Gallery to Graphing Applications

Try it:DerivativeGallery.html

Using XML Data for a Scrolling Banner

Try it:ScrollingBanner.html

An XML-based Quiz in Flash

Try it:RadioButtonXMLQuiz.html


Chapter 15. Working with MovieClips

The Cereal Box Problem

Try it:CerealBoxProblem.html

Using the Timeline of a MovieClip (Tiny Bubbles)

Try it:FreeBubbles.html

Loading SWF Files at Run Time (More Bubbles)

Try it:MultipleBubblers.html

Creating a Master Quiz Structure

Try it:QuizControl.html


Chapter 16. Simple 3D Drawing in Flash Player 10

Flipping a Card in Flash CS4

Try it: CardFlip.html

Matrix3D and Rotating a Cube in Space

Try it: 3DDie.html

Adding Imported Graphics: Rotating Picture Cube

Try it: PictureCube.html

Rolling the Die

Try it: DiceRoll.html

Redrawing at RunTime: An Icosahedron

Try it: Icosahedron.html


Chapter 17. Bridging the Gap: Developing Your Own AS3 Classes

The Bubble Class with Code on the Main Timeline

Try it:BubbleTimeline.html

The Bubble Effect as a Custom AS3 Class

Try it:BubbleClassDemo.html

A Bubble Tools Package

Try it:BubblerDemo.html

Card-Flipping Classes for CS3 and CS4

Try it:CardDemoCS3.html

Try it:CardDemoCS4.html

A Classic Memory Game with Cards

Try it:ConcentrationCS3.html

Try it:ConcentrationCS4.html

A Mathematical Memory Game

Try it:MathConcentrationCS3.html

Try it:MathConcentrationCS4.html

Applets Book Cover

Order Now!


Flash and Math Applets: Learn by Example

Programming in ActionScript 3 for Mathematics and Science Teaching and Learning

by Douglas Ensley and Barbara Kaskosz

Available now at Amazon.com

We welcome your comments, suggestions, and contributions. To contact us, email Barbara Kaskosz at barbara@flashandmath.com or Doug Ensley at doug@flashandmath.com.