|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectoptics.Optics
optics.WaveLengthFunction
public abstract class WaveLengthFunction
Abstract class to implement one dimensional function of wavelength.
It is used for either refractive index or spectral responses
It also includes the ability to plot to via the
ptolemy.Plot
graphical class.
Field Summary | |
---|---|
protected double |
maxPlotLambda
Propected double the graph minumum. |
protected double |
minPlotLambda
Propected double the graph minumum. |
protected static int |
plotPoints
Propected static to control the numbers of points on the graphs |
Fields inherited from class optics.Optics |
---|
DEFAULT_WAVELENGTH, errorStream, fmt, MICRONS |
Constructor Summary | |
---|---|
WaveLengthFunction()
|
Method Summary | |
---|---|
ptolemy.plot.Plot |
getPlot()
Method to get the Plot object. |
int |
getPlotPoints()
Method to get the current number of points in a plot. |
abstract double |
getValue(double lambda)
Method to get the value at specific wavelength. |
void |
setPlotPoints(int points)
Method to set the number of point in all subsequent plots. |
void |
setPlotRange(double minLambda,
double maxLambda)
Method to set the range of a plot. |
void |
setPlotRange(WaveLengthFunction f)
Method to set the range of a plot from another WaveLengthFunction. |
void |
toGraph(int ds)
Method to plot and automatically popup a basic graph of the function using PtPlot. |
void |
toPlot(int ds)
Method to plot the function to an internal Plot class. |
void |
toPlot(ptolemy.plot.Plot p,
int ds)
Void method to add a line to a ptplot Plot dataset using the default wavelength range. |
void |
toPlot(ptolemy.plot.Plot p,
int ds,
double minLambda,
double maxLambda)
Void method to add a line to a ptplot Plot dataset |
Methods inherited from class optics.Optics |
---|
getDefaultWaveLength, getErrorStream, getFormatString, getName, getStaticName, getVersion, printError, setDefaultWaveLength, setErrorStream, setFormatString, setMicrons |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static int plotPoints
protected double minPlotLambda
double
the graph minumum.
protected double maxPlotLambda
double
the graph minumum.
Constructor Detail |
---|
public WaveLengthFunction()
Method Detail |
---|
public abstract double getValue(double lambda)
lambda
- the wavelength
double
the valuepublic int getPlotPoints()
int
number of points in a plotpublic void setPlotPoints(int points)
points
- number of points.public ptolemy.plot.Plot getPlot()
Plot
object.
This may be null if no graph has been asked for.
Plot
the internal plot object.public void setPlotRange(double minLambda, double maxLambda)
minLambda
- minimum wavelengthmaxLambda
- maximum wavelnegthpublic void setPlotRange(WaveLengthFunction f)
f
- the WaveLengthFunction.public void toPlot(int ds)
ds
- the data setpublic void toPlot(ptolemy.plot.Plot p, int ds)
p
- the Plot to which it is addedds
- the dataset to hold the spectrumpublic void toPlot(ptolemy.plot.Plot p, int ds, double minLambda, double maxLambda)
p
- the Plot to which it is addedds
- the dataset to hold the spectrumminLambda
- minimum wavelength in micronsmaxLambda
- maximum wavelength in micronspublic void toGraph(int ds)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |