ucar.visad.quantities
Class PolarHorizontalWind.PolarCoordinateSystem

java.lang.Object
  extended by visad.CoordinateSystem
      extended by ucar.visad.quantities.PolarHorizontalWind.PolarCoordinateSystem
All Implemented Interfaces:
Serializable
Enclosing class:
PolarHorizontalWind

public static final class PolarHorizontalWind.PolarCoordinateSystem
extends CoordinateSystem

Provides support for transforming wind coordinates between polar and cartesian representations.

See Also:
Serialized Form

Constructor Summary
PolarHorizontalWind.PolarCoordinateSystem(Unit speedUnit, Unit directionUnit)
          Constructs from units for speed and direction.
 
Method Summary
 boolean equals(Object object)
          Tests for semantic equality with an object.
 double[][] fromReference(double[][] values)
          Converts wind coordinates from cartesian to polar.
 float[][] fromReference(float[][] values)
          Converts wind coordinates from cartesian to polar.
 double[][] toReference(double[][] values)
          Converts wind coordinates from polar to cartesian.
 float[][] toReference(float[][] values)
          Converts wind coordinates from polar to cartesian.
 
Methods inherited from class visad.CoordinateSystem
canConvert, fromReference, fromReference, getCoordinateSystemUnits, getDimension, getReference, getReferenceUnits, toReference, toReference, transformCoordinates, transformCoordinates, transformCoordinates, transformCoordinates, transformCoordinatesFreeUnits, transformCoordinatesFreeUnits
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PolarHorizontalWind.PolarCoordinateSystem

public PolarHorizontalWind.PolarCoordinateSystem(Unit speedUnit,
                                                 Unit directionUnit)
                                          throws VisADException
Constructs from units for speed and direction.

Parameters:
speedUnit - The unit for speed.
directionUnit - The unit for direction.
Throws:
VisADException - Couldn't create necessary VisAD object.
Method Detail

toReference

public double[][] toReference(double[][] values)
                       throws VisADException
Converts wind coordinates from polar to cartesian.

Specified by:
toReference in class CoordinateSystem
Parameters:
values - Polar wind coordinates (speed, direction).
Returns:
Cartesian wind coordinates (u, v).
Throws:
VisADException - Couldn't create necessary VisAD object.

toReference

public float[][] toReference(float[][] values)
                      throws VisADException
Converts wind coordinates from polar to cartesian.

Overrides:
toReference in class CoordinateSystem
Parameters:
values - Polar wind coordinates (speed, direction).
Returns:
Cartesian wind coordinates (u, v).
Throws:
VisADException - Couldn't create necessary VisAD object.

fromReference

public double[][] fromReference(double[][] values)
                         throws VisADException
Converts wind coordinates from cartesian to polar.

Specified by:
fromReference in class CoordinateSystem
Parameters:
values - Cartesian wind coordinates (u, v).
Returns:
Polar wind coordinates (speed, direction).
Throws:
VisADException - Couldn't create necessary VisAD object.

fromReference

public float[][] fromReference(float[][] values)
                        throws VisADException
Converts wind coordinates from cartesian to polar.

Overrides:
fromReference in class CoordinateSystem
Parameters:
values - Cartesian wind coordinates (u, v).
Returns:
Polar wind coordinates (speed, direction).
Throws:
VisADException - Couldn't create necessary VisAD object.

equals

public boolean equals(Object object)
Tests for semantic equality with an object.

Specified by:
equals in class CoordinateSystem
Parameters:
object - The object.
Returns:
True if and only if this object is semantically identical to the specified object.