Class Courbe

Class Courbe

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Canvas
                   |
                   +----Courbe

public class Courbe
extends Canvas
Courbe is an extended Canvas created to compute and display either a plot in the temporal domain either the associated plot in the frequency domain. Objects are instanciated by an item of the class Resultat
Version:
1.0 02/98
Author:
Stephane Verlet verlet@cadet.esstin.u-nancy.fr
See Also:
Resultat

Variable Index

 o Acompute
if TRUE : can start computations
 o courbe_def
courbe_def is a boolean use to check whether the computation of the points has been perfomed or not : courbe_def=false ---> points are not calculated yet courbe_def=true ---> points are avaible not need to compute them again
 o curve
Use for frequency representation.
 o deb
Since the number of point of the temporal representation might be smaller than the number of point computed for the Fourier Transform, deb tell what is the index of the first point to plot in the Vector trace
 o fenb
Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit
 o fenetre
Use to store parameter window size from the calling item of class Resultat
 o fenh
Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit
 o fonction
Use to store the fonction we are plotting (temporal domain) from the calling item of class Resultat
 o inter
Contains the horizontal space on the canvas between two consecutive points
 o nbpoints
contains the number of points of the curent plotting Note: if we are in the frequency domain nbpoints=fenetre
 o orgx
Are the positions of the origin in the canvas
 o orgy
Are the positions of the origin in the canvas
 o period_ech
Use to store the sample period from the calling item of class Resultat
 o saisie
 o trace
trace is a vector containing the points (classe Pts) to plot, in the case of a frequency domain plotting it contains either the real value points either the Modulus points.
 o trace_im
trace_im is a vector containing the points (classe Pts) to plot in the case of a frequency domain plotting.
 o trace_temp
trace_im is a vector containing the points (classe Pts) needed to compute the the Fourier Transform in the case of a frequency domain plotting.
 o type
type is a boolean use to specified the type of plotting we are doing if TRUE then we are plotting a temporal function if FALSE then we r ploting a frequency function
 o typefenetre
Use to store parameter window type from the calling item of class Resultat
 o typefft
typefft is a boolean use for the reprensatation if TRUE then the representation is Modulus & Frequency if FALSE then the representation is Real & imaginary part

Constructor Index

 o Courbe(Saisie, boolean)
Store and calculate paramters

Method Index

 o compute()
Set variable Acompute to true : allow the computation
 o drawWindow(double, Graphics)
plotting of the window
 o fenetrage()
apply window coeficients to the temporal domain values before the computation of the fourier transform
 o init_trace(Vector)
Save results of computations in Vector trace
 o init_trace_im(Vector)
Save results of computations in Vector trace_im
 o init_trace_temp(Vector)
Save results of computations in time domains for the frequency computations /*
 o maxy(Vector)
look for the maximum y value in the vector t
 o miny(Vector)
look for the minimum y value in the vector t
 o paint(Graphics)
handle the computation and the display .

Variables

 o trace
  public Vector trace
trace is a vector containing the points (classe Pts) to plot, in the case of a frequency domain plotting it contains either the real value points either the Modulus points.
See Also:
Pts
 o trace_im
  public Vector trace_im
trace_im is a vector containing the points (classe Pts) to plot in the case of a frequency domain plotting. It contains either the imaginar value points either the phase points.
See Also:
Pts
 o trace_temp
  public Vector trace_temp
trace_im is a vector containing the points (classe Pts) needed to compute the the Fourier Transform in the case of a frequency domain plotting. It contains a sampled function of time.
See Also:
Pts
 o courbe_def
  public boolean courbe_def
courbe_def is a boolean use to check whether the computation of the points has been perfomed or not : courbe_def=false ---> points are not calculated yet courbe_def=true ---> points are avaible not need to compute them again
See Also:
boolean
 o typefft
  public boolean typefft
typefft is a boolean use for the reprensatation if TRUE then the representation is Modulus & Frequency if FALSE then the representation is Real & imaginary part
See Also:
Saisie, Resultat
 o saisie
  public Saisie saisie
See Also:
Saisie
 o type
  public boolean type
type is a boolean use to specified the type of plotting we are doing if TRUE then we are plotting a temporal function if FALSE then we r ploting a frequency function
 o period_ech
  public double period_ech
Use to store the sample period from the calling item of class Resultat
See Also:
Resultat, Saisie
 o typefenetre
  public int typefenetre
Use to store parameter window type from the calling item of class Resultat
See Also:
Resultat, Saisie
 o fenetre
  public int fenetre
Use to store parameter window size from the calling item of class Resultat
See Also:
Resultat, Saisie
 o nbpoints
  public int nbpoints
contains the number of points of the curent plotting Note: if we are in the frequency domain nbpoints=fenetre
 o fonction
  public String fonction
Use to store the fonction we are plotting (temporal domain) from the calling item of class Resultat
See Also:
Resultat, Saisie
 o inter
  public double inter
Contains the horizontal space on the canvas between two consecutive points
 o fenb
  public double fenb
Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit
 o fenh
  public double fenh
Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit
 o deb
  public int deb
Since the number of point of the temporal representation might be smaller than the number of point computed for the Fourier Transform, deb tell what is the index of the first point to plot in the Vector trace
 o curve
  public int curve
Use for frequency representation. If = 1 then we are plotting the modulus or the real part, If = 2 we are plotting the phase or the imaginary part. See variable typefft
 o orgx
  public int orgx
Are the positions of the origin in the canvas
 o orgy
  public int orgy
Are the positions of the origin in the canvas
 o Acompute
  public boolean Acompute
if TRUE : can start computations
See Also:
compute, run

Constructors

 o Courbe
  public Courbe(Saisie sais,
                boolean typ)
Store and calculate paramters

Methods

 o init_trace
  public void init_trace(Vector t)
Save results of computations in Vector trace
See Also:
paint
 o init_trace_temp
  public void init_trace_temp(Vector t)
Save results of computations in time domains for the frequency computations /*@see Resultat#run
 o init_trace_im
  public void init_trace_im(Vector t)
Save results of computations in Vector trace_im
See Also:
paint
 o compute
  public void compute()
Set variable Acompute to true : allow the computation
 o paint
  public void paint(Graphics g)
handle the computation and the display . for computaion either an item of class Point_courbe either an item of class Calculftt is created
Overrides:
paint in class Canvas
See Also:
Point_courbe, Calculfft
 o maxy
  public double maxy(Vector t)
look for the maximum y value in the vector t
Returns:
double
 o miny
  public double miny(Vector t)
look for the minimum y value in the vector t
Returns:
double
 o fenetrage
  public void fenetrage()
apply window coeficients to the temporal domain values before the computation of the fourier transform
 o drawWindow
  public void drawWindow(double echelle,
                         Graphics g)
plotting of the window