Main Page | Packages | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

ikayaki.MeasurementResult Class Reference

List of all members.

Public Types

enum  Type { SAMPLE, HOLDER, NOISE }

Public Member Functions

 MeasurementResult (Type type, int rotation, double x, double y, double z)
 MeasurementResult (Element element)
Element getElement (Document document)
Type getType ()
int getRotation ()
double getGeographicX ()
double getGeographicY ()
double getGeographicZ ()
double getSampleX ()
double getSampleY ()
double getSampleZ ()
double getRawX ()
double getRawY ()
double getRawZ ()

Protected Member Functions

void applyFixes (MeasurementStep step)
void setTransform (Matrix3d transform)
Vector3d getGeographicVector ()
Vector3d getSampleVector ()
Vector3d getRawVector ()

Private Attributes

final Type type
final int rotation
final Vector3d rawVector = new Vector3d()
final Vector3d sampleVector = new Vector3d()
final Vector3d geographicVector = new Vector3d()

Detailed Description

A set of X, Y and Z values measured by the magnetometer. The raw XYZ values will be rotated in 3D space by using a transformation matrix. The project will set and update the transformation whenever its parameters are changed. <p/> All units are mA/m.

Author:
Esko Luontola

Definition at line 39 of file MeasurementResult.java.


Member Enumeration Documentation

enum ikayaki::MeasurementResult::Type
 

Enumeration values:
SAMPLE 
HOLDER 
NOISE 

Definition at line 361 of file MeasurementResult.java.


Constructor & Destructor Documentation

ikayaki.MeasurementResult.MeasurementResult Type  type,
int  rotation,
double  x,
double  y,
double  z
 

Creates a new measurement result. All units are mA/m. <p/> The sample and geographic coordinates are NOT set when a MeasurementResult is created.

Parameters:
type the type (background or rotation) of this result.
rotation the rotation of the sample holder in degrees (0..360).
x the measured X coordinate value.
y the measured Y coordinate value.
z the measured Z coordinate value.
Exceptions:
NullPointerException if type is null.
IllegalArgumentException if the type is NOISE or HOLDER, but rotation is non-zero.

Definition at line 80 of file MeasurementResult.java.

References ikayaki.MeasurementResult.applyFixes(), ikayaki.MeasurementResult.rawVector, and ikayaki.MeasurementResult.setTransform().

Here is the call graph for this function:

ikayaki.MeasurementResult.MeasurementResult Element  element  ) 
 

Creates a measurement result from the specified element. <p/> The sample and geographic coordinates are NOT set when a MeasurementResult is created.

Parameters:
element the element from which this result will be created.
Exceptions:
NullPointerException if element is null.
IllegalArgumentException if the element was not in the right format.

Definition at line 103 of file MeasurementResult.java.

References ikayaki.MeasurementResult.applyFixes(), ikayaki.MeasurementResult.rawVector, ikayaki.MeasurementResult.rotation, ikayaki.MeasurementResult.setTransform(), and ikayaki.MeasurementResult.type.

Here is the call graph for this function:


Member Function Documentation

void ikayaki.MeasurementResult.applyFixes MeasurementStep  step  )  [protected]
 

Applies the holder, noise and rotation fixes and saves the results as the sample vector. Resets the geographic vector to a copy of the sample vector. This method must be called before setTransform().

Parameters:
step the measurement step that includes the holder and noise calibration values. If null, the holder and noise fixes are not applied.

Definition at line 176 of file MeasurementResult.java.

References ikayaki.MeasurementStep.getHolder(), ikayaki.MeasurementStep.getNoise(), ikayaki.Project.getOrientation(), ikayaki.MeasurementStep.getProject(), ikayaki.Project.MINUS_Z, ikayaki.MeasurementResult.rawVector, ikayaki.MeasurementResult.rotation, ikayaki.MeasurementResult.sampleVector, and ikayaki.MeasurementResult.setTransform().

Referenced by ikayaki.MeasurementResult.MeasurementResult().

Here is the call graph for this function:

Element ikayaki.MeasurementResult.getElement Document  document  ) 
 

Exports this result to a DOM element.

Parameters:
document the document that will contain this element.

Definition at line 157 of file MeasurementResult.java.

References ikayaki.MeasurementResult.rawVector, ikayaki.MeasurementResult.rotation, and ikayaki.MeasurementResult.type.

Vector3d ikayaki.MeasurementResult.getGeographicVector  )  [protected]
 

Returns a pointer to the geographic vector. WARNING! No modification to the returned object should be made. They should be done on a copy of the object than the object itself.

Definition at line 299 of file MeasurementResult.java.

References ikayaki.MeasurementResult.geographicVector.

double ikayaki.MeasurementResult.getGeographicX  ) 
 

Returns the noise fixed, rotated and transformed X coordinate of this result. The value is in geographic coordinates.

Exceptions:
IllegalStateException if this result's type is not SAMPLE, in which case it should make no sense to call this method.

Definition at line 260 of file MeasurementResult.java.

References ikayaki.MeasurementResult.geographicVector, and ikayaki.MeasurementResult.type.

double ikayaki.MeasurementResult.getGeographicY  ) 
 

Returns the noise fixed, rotated and transformed Y coordinate of this result. The value is in geographic coordinates.

Exceptions:
IllegalStateException if this result's type is not SAMPLE, in which case it should make no sense to call this method.

Definition at line 274 of file MeasurementResult.java.

References ikayaki.MeasurementResult.geographicVector, and ikayaki.MeasurementResult.type.

double ikayaki.MeasurementResult.getGeographicZ  ) 
 

Returns the noise fixed, rotated and transformed Z coordinate of this result. The value is in geographic coordinates.

Exceptions:
IllegalStateException if this result's type is not SAMPLE, in which case it should make no sense to call this method.

Definition at line 288 of file MeasurementResult.java.

References ikayaki.MeasurementResult.geographicVector, and ikayaki.MeasurementResult.type.

Vector3d ikayaki.MeasurementResult.getRawVector  )  [protected]
 

Returns a pointer to the raw vector. WARNING! No modification to the returned object should be made. They should be done on a copy of the object than the object itself.

Definition at line 357 of file MeasurementResult.java.

References ikayaki.MeasurementResult.rawVector.

double ikayaki.MeasurementResult.getRawX  ) 
 

Returns the unmodified X coordinate of this result. The value is in magnetometer coordinates.

Definition at line 335 of file MeasurementResult.java.

References ikayaki.MeasurementResult.rawVector.

Referenced by ikayaki.gui.MeasurementDetailsPanel.DetailsTableModel.getValueAt().

double ikayaki.MeasurementResult.getRawY  ) 
 

Returns the unmodified Y coordinate of this result. The value is in magnetometer coordinates.

Definition at line 342 of file MeasurementResult.java.

References ikayaki.MeasurementResult.rawVector.

Referenced by ikayaki.gui.MeasurementDetailsPanel.DetailsTableModel.getValueAt().

double ikayaki.MeasurementResult.getRawZ  ) 
 

Returns the unmodified Z coordinate of this result. The value is in magnetometer coordinates.

Definition at line 349 of file MeasurementResult.java.

References ikayaki.MeasurementResult.rawVector.

Referenced by ikayaki.gui.MeasurementDetailsPanel.DetailsTableModel.getValueAt().

int ikayaki.MeasurementResult.getRotation  ) 
 

Returns the rotation of this result. The value is in range 0..360 degrees.

Definition at line 249 of file MeasurementResult.java.

References ikayaki.MeasurementResult.rotation.

Referenced by ikayaki.gui.MeasurementDetailsPanel.DetailsTableModel.getValueAt().

Vector3d ikayaki.MeasurementResult.getSampleVector  )  [protected]
 

Returns a pointer to the sample vector. WARNING! No modification to the returned object should be made. They should be done on a copy of the object than the object itself.

Definition at line 328 of file MeasurementResult.java.

References ikayaki.MeasurementResult.sampleVector.

double ikayaki.MeasurementResult.getSampleX  ) 
 

Returns the noise fixed and rotated X coordinate of this result. The value is in sample coordinates.

Definition at line 306 of file MeasurementResult.java.

References ikayaki.MeasurementResult.sampleVector.

double ikayaki.MeasurementResult.getSampleY  ) 
 

Returns the noise fixed and rotated Y coordinate of this result. The value is in sample coordinates.

Definition at line 313 of file MeasurementResult.java.

References ikayaki.MeasurementResult.sampleVector.

double ikayaki.MeasurementResult.getSampleZ  ) 
 

Returns the noise fixed and rotated Z coordinate of this result. The value is in sample coordinates.

Definition at line 320 of file MeasurementResult.java.

References ikayaki.MeasurementResult.sampleVector.

Type ikayaki.MeasurementResult.getType  ) 
 

Returns the type of this result.

Definition at line 242 of file MeasurementResult.java.

References ikayaki.MeasurementResult.type.

Referenced by ikayaki.gui.MeasurementDetailsPanel.DetailsTableModel.getRowCount(), and ikayaki.gui.MeasurementDetailsPanel.DetailsTableModel.getValueAt().

void ikayaki.MeasurementResult.setTransform Matrix3d  transform  )  [protected]
 

Applies a transformation matrix to the sample vector and saves the results as the geographic vector. This method must be called after applyFixes().

Parameters:
transform the matrix to be applied. If null, will assume identity matrix.

Definition at line 231 of file MeasurementResult.java.

References ikayaki.MeasurementResult.geographicVector, and ikayaki.MeasurementResult.sampleVector.

Referenced by ikayaki.MeasurementResult.applyFixes(), and ikayaki.MeasurementResult.MeasurementResult().


Member Data Documentation

final Vector3d ikayaki.MeasurementResult.geographicVector = new Vector3d() [private]
 

The measurements in geographic coordinates. Equals the sample coordinates with the transformation matrix applied.

Definition at line 65 of file MeasurementResult.java.

Referenced by ikayaki.MeasurementResult.getGeographicVector(), ikayaki.MeasurementResult.getGeographicX(), ikayaki.MeasurementResult.getGeographicY(), ikayaki.MeasurementResult.getGeographicZ(), and ikayaki.MeasurementResult.setTransform().

final Vector3d ikayaki.MeasurementResult.rawVector = new Vector3d() [private]
 

The unmodified measurements recieved from the squid. Will not change after it has been once set.

Definition at line 54 of file MeasurementResult.java.

Referenced by ikayaki.MeasurementResult.applyFixes(), ikayaki.MeasurementResult.getElement(), ikayaki.MeasurementResult.getRawVector(), ikayaki.MeasurementResult.getRawX(), ikayaki.MeasurementResult.getRawY(), ikayaki.MeasurementResult.getRawZ(), and ikayaki.MeasurementResult.MeasurementResult().

final int ikayaki.MeasurementResult.rotation [private]
 

The rotation that the sample holder was in when this result was measured. The value is in range 0..360 degrees.

Definition at line 49 of file MeasurementResult.java.

Referenced by ikayaki.MeasurementResult.applyFixes(), ikayaki.MeasurementResult.getElement(), ikayaki.MeasurementResult.getRotation(), and ikayaki.MeasurementResult.MeasurementResult().

final Vector3d ikayaki.MeasurementResult.sampleVector = new Vector3d() [private]
 

The measurements in sample coordinates. Has the rotation, noise and holder fixes applied to itself.

Definition at line 59 of file MeasurementResult.java.

Referenced by ikayaki.MeasurementResult.applyFixes(), ikayaki.MeasurementResult.getSampleVector(), ikayaki.MeasurementResult.getSampleX(), ikayaki.MeasurementResult.getSampleY(), ikayaki.MeasurementResult.getSampleZ(), and ikayaki.MeasurementResult.setTransform().

final Type ikayaki.MeasurementResult.type [private]
 

The type of this result.

Definition at line 44 of file MeasurementResult.java.

Referenced by ikayaki.MeasurementResult.getElement(), ikayaki.MeasurementResult.getGeographicX(), ikayaki.MeasurementResult.getGeographicY(), ikayaki.MeasurementResult.getGeographicZ(), ikayaki.MeasurementResult.getType(), and ikayaki.MeasurementResult.MeasurementResult().


The documentation for this class was generated from the following file:
Generated on Fri May 6 16:00:38 2005 for Squid by  doxygen 1.4.1