fhm.edu.fem.animation
Class CalcAnimation

java.lang.Object
  extended by fhm.edu.fem.animation.CalcAnimation
All Implemented Interfaces:
java.awt.event.KeyListener, java.util.EventListener
Direct Known Subclasses:
CalcAnimationSpanner

public class CalcAnimation
extends java.lang.Object
implements java.awt.event.KeyListener

Class Description: This class is being used when we have a FEM4 files for Membran calculations. Any node designated as border node in the FEMIN File is taken out of the calculations (all other get Alias IDs)

Author:
Thomas Woellert (thomas@woellert.net), Stefan Weissbach (weissbst@gmx.de)

Field Summary
protected  Vector aiVector
           
protected  double deltaT
           
protected  double dimensionA
           
protected  double dimensionB
           
protected  FEMManager femManager
           
protected  int frameCount
           
protected  double initialDeltaT
           
protected  double initialPZ
           
protected static int INNER_POINTS
           
protected static Logger localLogger
           
protected  Vector omega
           
protected static int OUTER_POINTS
           
protected  double pX
           
protected  double pY
           
protected  double pZ
           
protected  long startTime
           
protected  long tmpTime
           
protected  Vector w0Vector
           
 
Constructor Summary
protected CalcAnimation()
          Basic Constructor needed for other animation classes extending from this one
  CalcAnimation(java.lang.String[] args)
          Create a new Calc Animation Object
 
Method Summary
protected  boolean calculateAI()
          Calculate the Vector a(i)
protected  boolean calculateAnimation()
          Calculate the Animation
protected  boolean calculateExactA()
          Calculate the exact Matrix a(m,n) via formula: 4/(ab) double-integral { w(x,y,0) sin(m pi x/a) sin(n pi y/b) dx dy
protected  boolean calculateMembranDimensions()
          Calculate the Membran Dimensions
protected  boolean calculateOmega()
          Calculate the Vector Omega
protected  boolean calculateStartingAmplitude()
          Calculate the Starting Amplitude
 void keyPressed(java.awt.event.KeyEvent e)
          METHODS NEEDED BY THE KEYLISTENER INTERFACE
 void keyReleased(java.awt.event.KeyEvent e)
           
 void keyTyped(java.awt.event.KeyEvent e)
          Automatically called when the user presses a key
protected  boolean normB()
          B-normalize all eigenvectors
 boolean start()
          Call this method to start the animation
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

aiVector

protected Vector aiVector

deltaT

protected double deltaT

dimensionA

protected double dimensionA

dimensionB

protected double dimensionB

femManager

protected FEMManager femManager

frameCount

protected int frameCount

initialDeltaT

protected double initialDeltaT

initialPZ

protected double initialPZ

INNER_POINTS

protected static int INNER_POINTS

localLogger

protected static Logger localLogger

omega

protected Vector omega

OUTER_POINTS

protected static int OUTER_POINTS

pX

protected double pX

pY

protected double pY

pZ

protected double pZ

startTime

protected long startTime

tmpTime

protected long tmpTime

w0Vector

protected Vector w0Vector
Constructor Detail

CalcAnimation

protected CalcAnimation()
Basic Constructor needed for other animation classes extending from this one


CalcAnimation

public CalcAnimation(java.lang.String[] args)
Create a new Calc Animation Object

Parameters:
args, - the command-line arguments
Method Detail

calculateAI

protected boolean calculateAI()
Calculate the Vector a(i)

Returns:
true if all went well, false otherwise

calculateAnimation

protected boolean calculateAnimation()
Calculate the Animation

Returns:
true if all went well, false otherwise

calculateExactA

protected boolean calculateExactA()
Calculate the exact Matrix a(m,n) via formula: 4/(ab) double-integral { w(x,y,0) sin(m pi x/a) sin(n pi y/b) dx dy

Returns:
true if all went well, false otherwise

calculateMembranDimensions

protected boolean calculateMembranDimensions()
Calculate the Membran Dimensions

Returns:
true if all went well, false otherwise

calculateOmega

protected boolean calculateOmega()
Calculate the Vector Omega

Returns:
true if all went well, false otherwise

calculateStartingAmplitude

protected boolean calculateStartingAmplitude()
Calculate the Starting Amplitude

Returns:
true if all went well, false otherwise

keyPressed

public void keyPressed(java.awt.event.KeyEvent e)
METHODS NEEDED BY THE KEYLISTENER INTERFACE

Specified by:
keyPressed in interface java.awt.event.KeyListener

keyReleased

public void keyReleased(java.awt.event.KeyEvent e)
Specified by:
keyReleased in interface java.awt.event.KeyListener

keyTyped

public void keyTyped(java.awt.event.KeyEvent e)
Automatically called when the user presses a key

Specified by:
keyTyped in interface java.awt.event.KeyListener
Parameters:
e, - the key event

normB

protected boolean normB()
B-normalize all eigenvectors

Returns:
true if all went well, false otherwise

start

public boolean start()
Call this method to start the animation

Returns:
true if all went well, false otherwise