|
||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||
java.lang.Object
|
+--TimeDepSchrodinger
|
+--HaynesShockley
Class to model the Haynes-Shockley experiment. Uses the fourth-order Runge-Kutta method to interpolate across time.
| Field Summary | |
protected double |
field
The field strength |
protected double |
lifetime
The carrier lifetime |
protected double[] |
p
The function data |
| Fields inherited from class TimeDepSchrodinger |
dt,
energy,
h,
pot,
potFn,
psi,
t,
width,
x0 |
| Constructor Summary | |
HaynesShockley()
|
|
| Method Summary | |
protected void |
advanceOnce(double dt)
Performs one step of the Runge-Kutta method. |
double |
getField()
Returns the selected field strength |
double |
getLifetime()
Returns the selected carrier lifetime |
void |
initFunction(double x,
double h,
int steps)
Resets the model, replacing the function data with a new square wave. |
double |
integralCheck()
Approximates the integral of the function, by summing the function data and dividing by h. |
void |
setField(double d)
Sets the selected field strength |
void |
setLifetime(double d)
Sets the selected carrier lifetime |
void |
solve(double x,
double h,
double[] vals)
Since all the work is done in advanceOnce(), this method need only return the function data. |
protected double |
xderiv(double[] d,
int i)
Measures the derivative with respect to x using a finite difference method. |
protected double |
xderiv2(double[] d,
int i)
Measures the second derivative with respect to x using a finite difference method. |
| Methods inherited from class TimeDepSchrodinger |
advanceOnce,
getEnergy,
getT,
getWidth,
getX0,
setEnergy,
setT,
setWidth,
setX0,
xderiv |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
protected double lifetime
protected double field
protected double[] p
| Constructor Detail |
public HaynesShockley()
| Method Detail |
public void initFunction(double x,
double h,
int steps)
x - The smallest x-value to considerh - The gap between x-valuessteps - The number of x-values to considerprotected void advanceOnce(double dt)
dt - The size of the advancement in time
protected double xderiv(double[] d,
int i)
i <= 1 or
i >= d.length-2, zero will be returned.d - The function data on which to operatei - The index at which the derivative is required
protected double xderiv2(double[] d,
int i)
i <= 1 or
i >= d.length-2, zero will be returned.d - The function data on which to operatei - The index at which the derivative is required
public void solve(double x,
double h,
double[] vals)
advanceOnce(), this method need only return the function data.
Since it is not practical to adjust the size or x-spacing
of the data in the array while the simulation is running, the
x and h parameters are ignored.vals is not the same
size as the array of function datapublic double integralCheck()
h.public double getField()
public void setField(double d)
public double getLifetime()
public void setLifetime(double d)
|
||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||