Class Util

java.lang.Object
  extended by Util

public final class Util
extends java.lang.Object


Field Summary
static java.text.DecimalFormat[] d
           
static java.text.DecimalFormat d1
           
static java.text.DecimalFormat d2
           
static java.text.DecimalFormat d3
           
static java.text.DecimalFormat d4
           
static java.text.DecimalFormat d5
           
static java.text.DecimalFormat d6
           
static java.text.DecimalFormat d7
           
static java.text.DecimalFormat d8
           
static java.text.DecimalFormat d9
           
static java.text.DecimalFormat[] e
           
static java.text.DecimalFormat e0
           
static java.text.DecimalFormat e1
           
static java.text.DecimalFormat e2
           
static java.text.DecimalFormat e3
           
static java.text.DecimalFormat e4
           
static java.text.DecimalFormat e5
           
static java.text.DecimalFormat e6
           
static java.text.DecimalFormat e7
           
static java.text.DecimalFormat e8
           
static java.text.DecimalFormat e9
           
static java.text.DecimalFormat[] f
           
static java.text.DecimalFormat f0
           
static java.text.DecimalFormat f1
           
static java.text.DecimalFormat f2
           
static java.text.DecimalFormat f3
           
static java.text.DecimalFormat f4
           
static java.text.DecimalFormat f5
           
static java.text.DecimalFormat f6
           
static java.text.DecimalFormat f7
           
static java.text.DecimalFormat f8
           
static java.text.DecimalFormat f9
           
static double sigmasInFWHM
           
 
Constructor Summary
Util()
           
 
Method Summary
static void addLongFitsKey(nom.tam.util.Cursor cursor, java.lang.String key, java.lang.String value, java.lang.String comment)
           
static void addLongFitsKey(nom.tam.fits.Header header, java.lang.String key, java.lang.String value, java.lang.String comment)
           
static double angleOfTime(double time)
          Return the equivalent angle value for a time value.
static double DMS(int D, int M, double S)
          Construct an angle from degree, arc-minute and arc-second values.
static double fitsDouble(double value)
           
static java.lang.String getLongFitsKey(nom.tam.fits.Header header, java.lang.String key)
           
static java.lang.String getSystemString(java.lang.String spec)
           
static double[] lineFit(double[] y, double[] w)
           
static boolean parseBoolean(java.lang.String value)
          Construct an time from hour, minute and second values.
static void printContents(java.lang.Object object)
           
static double standardAngle(double angle)
          Return the standardized angle for a given angle.
static double timeOfAngle(double angle)
          Return the equivalent time value for angle.
static double timeOfDay(double time)
          Return the time of day for a given time value.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

f0

public static final java.text.DecimalFormat f0

f1

public static final java.text.DecimalFormat f1

f2

public static final java.text.DecimalFormat f2

f3

public static final java.text.DecimalFormat f3

f4

public static final java.text.DecimalFormat f4

f5

public static final java.text.DecimalFormat f5

f6

public static final java.text.DecimalFormat f6

f7

public static final java.text.DecimalFormat f7

f8

public static final java.text.DecimalFormat f8

f9

public static final java.text.DecimalFormat f9

e0

public static final java.text.DecimalFormat e0

e1

public static final java.text.DecimalFormat e1

e2

public static final java.text.DecimalFormat e2

e3

public static final java.text.DecimalFormat e3

e4

public static final java.text.DecimalFormat e4

e5

public static final java.text.DecimalFormat e5

e6

public static final java.text.DecimalFormat e6

e7

public static final java.text.DecimalFormat e7

e8

public static final java.text.DecimalFormat e8

e9

public static final java.text.DecimalFormat e9

d1

public static final java.text.DecimalFormat d1

d2

public static final java.text.DecimalFormat d2

d3

public static final java.text.DecimalFormat d3

d4

public static final java.text.DecimalFormat d4

d5

public static final java.text.DecimalFormat d5

d6

public static final java.text.DecimalFormat d6

d7

public static final java.text.DecimalFormat d7

d8

public static final java.text.DecimalFormat d8

d9

public static final java.text.DecimalFormat d9

e

public static final java.text.DecimalFormat[] e

f

public static final java.text.DecimalFormat[] f

d

public static final java.text.DecimalFormat[] d

sigmasInFWHM

public static final double sigmasInFWHM
Constructor Detail

Util

public Util()
Method Detail

standardAngle

public static final double standardAngle(double angle)
Return the standardized angle for a given angle.

Returns:
an angle between -Pi and Pi.

timeOfDay

public static final double timeOfDay(double time)
Return the time of day for a given time value.

Returns:
time betweem 0-24h.

timeOfAngle

public static final double timeOfAngle(double angle)
Return the equivalent time value for angle. Useful for converting angles to right-ascention or hour-angle

Returns:
a time.
See Also:
angleOfTime

angleOfTime

public static final double angleOfTime(double time)
Return the equivalent angle value for a time value. Useful for converting right-ascention or hour-angle to radians.

Returns:
an angle.
See Also:
timeOfAngle

DMS

public static double DMS(int D,
                         int M,
                         double S)
Construct an angle from degree, arc-minute and arc-second values.

Parameters:
degree -
arcminute -
arcsecond -
Returns:
an angle.
See Also:
DMS

parseBoolean

public static boolean parseBoolean(java.lang.String value)
                            throws java.lang.NumberFormatException
Construct an time from hour, minute and second values.

Parameters:
degree -
arcminute -
arcsecond -
Returns:
an angle.
Throws:
java.lang.NumberFormatException
See Also:
HMS

lineFit

public static double[] lineFit(double[] y,
                               double[] w)

printContents

public static void printContents(java.lang.Object object)

fitsDouble

public static double fitsDouble(double value)

addLongFitsKey

public static void addLongFitsKey(nom.tam.fits.Header header,
                                  java.lang.String key,
                                  java.lang.String value,
                                  java.lang.String comment)
                           throws nom.tam.fits.FitsException,
                                  nom.tam.fits.HeaderCardException
Throws:
nom.tam.fits.FitsException
nom.tam.fits.HeaderCardException

getLongFitsKey

public static java.lang.String getLongFitsKey(nom.tam.fits.Header header,
                                              java.lang.String key)

addLongFitsKey

public static void addLongFitsKey(nom.tam.util.Cursor cursor,
                                  java.lang.String key,
                                  java.lang.String value,
                                  java.lang.String comment)
                           throws nom.tam.fits.FitsException,
                                  nom.tam.fits.HeaderCardException
Throws:
nom.tam.fits.FitsException
nom.tam.fits.HeaderCardException

getSystemString

public static java.lang.String getSystemString(java.lang.String spec)