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.unancy.fr
 See Also:
 Resultat

Acompute
 if TRUE : can start computations

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

curve
 Use for frequency representation.

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

fenb
 Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit

fenetre
 Use to store parameter window size from the calling item of class Resultat

fenh
 Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit

fonction
 Use to store the fonction we are plotting (temporal domain) from the calling item of class Resultat

inter
 Contains the horizontal space on the canvas between two consecutive points

nbpoints
 contains the number of points of the curent plotting
Note: if we are in the frequency domain nbpoints=fenetre

orgx
 Are the positions of the origin in the canvas

orgy
 Are the positions of the origin in the canvas

period_ech
 Use to store the sample period from the calling item of class Resultat

saisie


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.

trace_im
 trace_im is a vector containing the points (classe Pts) to plot in the case
of a frequency domain plotting.

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.

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

typefenetre
 Use to store parameter window type from the calling item of class Resultat

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

Courbe(Saisie, boolean)
 Store and calculate paramters

compute()
 Set variable Acompute to true : allow the computation

drawWindow(double, Graphics)
 plotting of the window

fenetrage()
 apply window coeficients to the temporal domain values before the computation of the fourier transform

init_trace(Vector)
 Save results of computations in Vector trace

init_trace_im(Vector)
 Save results of computations in Vector trace_im

init_trace_temp(Vector)
 Save results of computations in time domains for the frequency
computations
/*

maxy(Vector)
 look for the maximum y value in the vector t

miny(Vector)
 look for the minimum y value in the vector t

paint(Graphics)
 handle the computation and the display .
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
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
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
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
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
saisie
public Saisie saisie
 See Also:
 Saisie
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
period_ech
public double period_ech
 Use to store the sample period from the calling item of class Resultat
 See Also:
 Resultat, Saisie
typefenetre
public int typefenetre
 Use to store parameter window type from the calling item of class Resultat
 See Also:
 Resultat, Saisie
fenetre
public int fenetre
 Use to store parameter window size from the calling item of class Resultat
 See Also:
 Resultat, Saisie
nbpoints
public int nbpoints
 contains the number of points of the curent plotting
Note: if we are in the frequency domain nbpoints=fenetre
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
inter
public double inter
 Contains the horizontal space on the canvas between two consecutive points
fenb
public double fenb
 Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit
fenh
public double fenh
 Contains the range limits of the window in the time domain : fenb lower limit, fenh upper limit
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
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
orgx
public int orgx
 Are the positions of the origin in the canvas
orgy
public int orgy
 Are the positions of the origin in the canvas
Acompute
public boolean Acompute
 if TRUE : can start computations
 See Also:
 compute, run
Courbe
public Courbe(Saisie sais,
boolean typ)
 Store and calculate paramters
init_trace
public void init_trace(Vector t)
 Save results of computations in Vector trace
 See Also:
 paint
init_trace_temp
public void init_trace_temp(Vector t)
 Save results of computations in time domains for the frequency
computations
/*@see Resultat#run
init_trace_im
public void init_trace_im(Vector t)
 Save results of computations in Vector trace_im
 See Also:
 paint
compute
public void compute()
 Set variable Acompute to true : allow the computation
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
maxy
public double maxy(Vector t)
 look for the maximum y value in the vector t
 Returns:
 double
miny
public double miny(Vector t)
 look for the minimum y value in the vector t
 Returns:
 double
fenetrage
public void fenetrage()
 apply window coeficients to the temporal domain values before the computation of the fourier transform
drawWindow
public void drawWindow(double echelle,
Graphics g)
 plotting of the window