faa.tg.units
Class IndicatedAirspeed

java.lang.Object
  extended by faa.tg.units.AMeasure
      extended by faa.tg.units.IndicatedAirspeed
All Implemented Interfaces:
GenericSpeed, java.io.Serializable, java.lang.Cloneable, java.lang.Comparable<AMeasure>

public class IndicatedAirspeed
extends AMeasure
implements GenericSpeed

 IndicatedAirspeed represents a measurement of speed as perceived by an
 aneroid/bellows airspeed indicator: local atmospheric changes will affect
 the value even if the actual speed does not change.
 This does not extend Speed since it is a perception of a speed, and the
 measures can not be directly compared to other speed measures.
 Conversion methods are provided for the GenericSpeed interface.
 
See section 5.6 of the Detailed Design Document for a discussion of design issues.

See the source: IndicatedAirspeed.java

Version:
$Id: IndicatedAirspeed.java,v 3.7 2009/01/28 22:29:02 danaw Exp $
Author:
Tim Kimmet (modeled after Robert G. Oliver's Units Classes)
See Also:
Speed, GroundTrackSpeed, TrueAirspeed, Units.mPerSec, Serialized Form

Field Summary
static IndicatedAirspeed ACCEPTABLE_VARIATION
           
static java.lang.String CVS_VERSION_ID
          The CVS Version ID
static IndicatedAirspeed FAR_LT_10K
          Federal Air Regulation speed for less than 10,000 ft altitude (MSL) is 250 knots.
static IndicatedAirspeed FAR10K_PLUS_10_KTS
           
static IndicatedAirspeed KTS_10
           
static IndicatedAirspeed KTS_100
           
static IndicatedAirspeed KTS_20
           
static IndicatedAirspeed KTS_200
           
static IndicatedAirspeed KTS_220
           
static IndicatedAirspeed KTS_250
           
static IndicatedAirspeed KTS_45
           
static IndicatedAirspeed KTS_5
           
static IndicatedAirspeed KTS_50
           
static IndicatedAirspeed MAX_IAS
           
static IndicatedAirspeed MIN_IAS
           
(package private) static long serialVersionUID
           
static IndicatedAirspeed ZERO
           
 
Fields inherited from class faa.tg.units.AMeasure
DEC0, DEC0_, DEC00, DEC000, DEC1, DEC1_, DEC12, DEC12_, DEC1L, DEC1L_, DEC2, DEC2_, DEC3, DEC3_, DEC4, DEC4_, DEC5, DEC5_, DEC6, DEC6_, DEC7, DEC7_, DEC9, DEC9_, itsValue, TIME_FRACTION
 
Constructor Summary
IndicatedAirspeed(double theValue, SpeedUnits theUnits)
          Constructor for a measurement of IndicatedAirspeed (speed perceived by an aneroid/bellows airspeed indicator).
 
Method Summary
 IndicatedAirspeed abs()
          This method returns an IndicatedAirspeed with the absolute value of this object's value.
 IndicatedAirspeed add(IndicatedAirspeed theMeasure)
          This summation method adds a value with like units.
 boolean aeq(IndicatedAirspeed measure)
          Return whether measure is within an acceptable variation of this.
 double as(SpeedUnits units)
          The as method extracts the value from a Measure in the specified units.
 IndicatedAirspeed asIndicatedAirspeed(LocalAtm atm)
          These methods are used to return the speed as other GenericSpeeds.
 Mach asMach(LocalAtm atm)
          These methods are used to return the speed as other GenericSpeeds.
 TrueAirspeed asTrueAirspeed(LocalAtm atm)
          These methods are used to return the speed as other GenericSpeeds.
 java.lang.String debug()
          Formats value as an easy-to-read text string that shows the AMeasure followed by its commonly-used unit abbreviation.
 boolean eq(IndicatedAirspeed theMeasure)
          This method provides a test for equality.
 boolean ge(IndicatedAirspeed theMeasure)
          This method provides a test for greater than / equal to.
 boolean gt(GenericSpeed otherSpd, LocalAtm atm)
          Convenience method for "greater than" test against other GenericSpeeds.
 boolean gt(IndicatedAirspeed theMeasure)
          This method provides a test for greater than.
 boolean inRange()
          Returns whether this value is between the minimum and maximum IAS.
 boolean le(IndicatedAirspeed theMeasure)
          This method provides a test for less than / equal to.
 boolean lt(IndicatedAirspeed theMeasure)
          This method provides a test for less than.
 double ratio(IndicatedAirspeed val)
          This division method produces a dimensionless ratio of like measures.
 IndicatedAirspeed sub(IndicatedAirspeed theMeasure)
          This subtraction method subtracts a value with like units.
 java.lang.String toString()
          Returns the String representation of this object in the form with which it was created.
 java.lang.String toText()
          Prints the speed in a standardized text value format by type.
 
Methods inherited from class faa.tg.units.AMeasure
absoluteValue, add, as, as, clone, compareTo, div, eq, equals, ge, getAUnit, getCanonicalUnit, getCanonicalValue, getInitialUnit, getUnitClass, gt, hashCode, isBetween, le, lt, mul, ratio, sub, toAMeasure, toString, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface faa.tg.units.GenericSpeed
mul, toString
 

Field Detail

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

CVS_VERSION_ID

public static final java.lang.String CVS_VERSION_ID
The CVS Version ID

See Also:
Constant Field Values

ZERO

public static final IndicatedAirspeed ZERO

KTS_5

public static final IndicatedAirspeed KTS_5

KTS_10

public static final IndicatedAirspeed KTS_10

KTS_20

public static final IndicatedAirspeed KTS_20

KTS_50

public static final IndicatedAirspeed KTS_50

KTS_100

public static final IndicatedAirspeed KTS_100

KTS_200

public static final IndicatedAirspeed KTS_200

KTS_220

public static final IndicatedAirspeed KTS_220

KTS_250

public static final IndicatedAirspeed KTS_250

FAR_LT_10K

public static final IndicatedAirspeed FAR_LT_10K
Federal Air Regulation speed for less than 10,000 ft altitude (MSL) is 250 knots.


FAR10K_PLUS_10_KTS

public static final IndicatedAirspeed FAR10K_PLUS_10_KTS

ACCEPTABLE_VARIATION

public static final IndicatedAirspeed ACCEPTABLE_VARIATION

MAX_IAS

public static final IndicatedAirspeed MAX_IAS

MIN_IAS

public static final IndicatedAirspeed MIN_IAS

KTS_45

public static final IndicatedAirspeed KTS_45
Constructor Detail

IndicatedAirspeed

public IndicatedAirspeed(double theValue,
                         SpeedUnits theUnits)
Constructor for a measurement of IndicatedAirspeed (speed perceived by an aneroid/bellows airspeed indicator).

Parameters:
theValue - the magnitude of IndicatedAirspeed as a double
theUnits - the units of the value that will be stored (ex: km)
Method Detail

inRange

public boolean inRange()
Returns whether this value is between the minimum and maximum IAS.


as

public double as(SpeedUnits units)
The as method extracts the value from a Measure in the specified units. Override for type safety!

Parameters:
units - The units of the value that will be returned (ex: nm).
Returns:
The value of the measure in specified units.

aeq

public boolean aeq(IndicatedAirspeed measure)
Return whether measure is within an acceptable variation of this.


add

public IndicatedAirspeed add(IndicatedAirspeed theMeasure)
This summation method adds a value with like units. It overrides the method in the superclass and checks for like AMeasures as well as doing the cast for you.

Parameters:
theMeasure - the unit of measure you wish to add to this measure.
Returns:
new IndicatedAirspeed equal to this plus the parameter value.

sub

public IndicatedAirspeed sub(IndicatedAirspeed theMeasure)
This subtraction method subtracts a value with like units. It overrides the method in the superclass and checks for like AMeasures as well as doing the cast for you.

Parameters:
theMeasure - the unit of measure you wish to sub from this measure.
Returns:
a clone with the difference

abs

public IndicatedAirspeed abs()
This method returns an IndicatedAirspeed with the absolute value of this object's value. The value of this object is not changed.

Returns:
a IndicatedAirspeed with the absolute value of this.

ratio

public double ratio(IndicatedAirspeed val)
This division method produces a dimensionless ratio of like measures.

Returns:
the ratio of the two measures

eq

public boolean eq(IndicatedAirspeed theMeasure)
This method provides a test for equality. It overrides the method in the superclass and checks for like AMeasures as well as doing the cast for you.

Returns:
Returns boolean indicating whether values are equal.

lt

public boolean lt(IndicatedAirspeed theMeasure)
This method provides a test for less than. It overrides the method in the superclass and checks for like AMeasures as well as doing the cast for you.

Returns:
Returns whether this value is less than the given value.

gt

public boolean gt(IndicatedAirspeed theMeasure)
This method provides a test for greater than. It overrides the method in the superclass and checks for like AMeasures as well as doing the cast for you.

Returns:
Returns whether this value is greater than the given value.

gt

public boolean gt(GenericSpeed otherSpd,
                  LocalAtm atm)
Convenience method for "greater than" test against other GenericSpeeds.

Specified by:
gt in interface GenericSpeed
Returns:
Returns whether this value is greater than the given value when at the specified atmosphere.

le

public boolean le(IndicatedAirspeed theMeasure)
This method provides a test for less than / equal to. It overrides the method in the superclass and checks for like AMeasures as well as doing the cast for you.

Returns:
Returns result of test for less than or equal to.

ge

public boolean ge(IndicatedAirspeed theMeasure)
This method provides a test for greater than / equal to. It overrides the method in the superclass and checks for like AMeasures as well as doing the cast for you.

Returns:
Returns result of test for greater than or equal to.

debug

public java.lang.String debug()
Formats value as an easy-to-read text string that shows the AMeasure followed by its commonly-used unit abbreviation. (This is to point out an override of AMeasure.debug() to always display the units in knots rather than the created unit.)

Specified by:
debug in interface GenericSpeed
Overrides:
debug in class AMeasure
Returns:
An easy-to-read String representing the measure in knots.

toText

public java.lang.String toText()
Prints the speed in a standardized text value format by type. IAS in knots: 9kts (TAS in knots: 9kTAS)

Specified by:
toText in interface GenericSpeed
Returns:
A short standardized text output value.

toString

public java.lang.String toString()
Returns the String representation of this object in the form with which it was created.

Overrides:
toString in class AMeasure
Returns:
A String representing the measure in the canonical unit.
See Also:
Units

asMach

public Mach asMach(LocalAtm atm)
These methods are used to return the speed as other GenericSpeeds. Note that the LocalAtm must be at the altitude to be converted.

Specified by:
asMach in interface GenericSpeed

asTrueAirspeed

public TrueAirspeed asTrueAirspeed(LocalAtm atm)
These methods are used to return the speed as other GenericSpeeds. Note that the LocalAtm must be at the altitude to be converted.

Specified by:
asTrueAirspeed in interface GenericSpeed

asIndicatedAirspeed

public IndicatedAirspeed asIndicatedAirspeed(LocalAtm atm)
These methods are used to return the speed as other GenericSpeeds. Note that the LocalAtm must be at the altitude to be converted.

Specified by:
asIndicatedAirspeed in interface GenericSpeed