public class Walker
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
double[] |
dPhi
space to stop phase shifts in each scan direction
|
double[] |
r
current coords
|
double[] |
r0
initial coords
|
double[] |
step
space to store next step
|
Constructor and Description |
---|
Walker(double[] r0)
initialises a walker without a step generator.
|
Walker(double[] r0,
StepGenerator stepGen,
Substrate substrate,
SyntheticScan scan,
java.io.DataOutputStream trajWriter)
public constructor.
|
Walker(double[] r0,
Substrate substrate)
initialises a walker without a step generator.
|
Modifier and Type | Method and Description |
---|---|
double[] |
getDisplacement()
fetches the current displacemnt vector (r - r0)
|
double |
getLogMagnetisation(int i)
returns log magnetisaion for a given measurement
|
double |
getPhaseShift(int i)
returns the phase shift due to diffusion weighting in
a specified direction.
|
static void |
main(java.lang.String[] args)
main is just a test method
|
void |
makeStep(double[] step)
make a specified step
|
void |
testReplacePositionVector(double[] pos)
set the position directly.
|
java.lang.String |
toString()
outputs walker fields as string
|
void |
update(double t,
int ti,
int i)
update walkers position.
|
public double[] r0
public double[] r
public double[] step
public final double[] dPhi
public Walker(double[] r0, StepGenerator stepGen, Substrate substrate, SyntheticScan scan, java.io.DataOutputStream trajWriter)
r0
- initial coords arraypublic Walker(double[] r0)
r0
- inital walker positionpublic Walker(double[] r0, Substrate substrate)
r0
- inital walker positionpublic void update(double t, int ti, int i)
public final double getPhaseShift(int i)
i
- index of directionpublic final double getLogMagnetisation(int i)
i
- direction indexpublic void makeStep(double[] step)
step
- the step vectorpublic void testReplacePositionVector(double[] pos)
pos
- new position vector (uses same instance)public double[] getDisplacement()
public java.lang.String toString()
toString
in class java.lang.Object
public static void main(java.lang.String[] args)