visad.python
Class JPythonMethods

java.lang.Object
  extended by visad.python.JPythonMethods

public abstract class JPythonMethods
extends java.lang.Object

A collection of methods for working with VisAD, callable from the JPython editor.


Constructor Summary
JPythonMethods()
           
 
Method Summary
static Data abs_data(Data data)
          return pointwise absolute value of data name changed 1/11/02 to avoid conflicts with Jython built-in
static Data acos(Data data)
          return pointwise arccos value of data, in radians
static Data acosDegrees(Data data)
          return pointwise arccos value of data, in degrees
static Data asin(Data data)
          return pointwise arcsin value of data, in radians
static Data asinDegrees(Data data)
          return pointwise arcsin value of data, in degrees
static Data atan(Data data)
          return pointwise arctan value of data, in radians
static Data atan2(Data data1, Data data2)
          return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in radians.
static Data atan2(Data data1, double data2)
          return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in radians.
static Data atan2(double data1, Data data2)
          return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in radians.
static Data atan2Degrees(Data data1, Data data2)
          return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in degrees.
static Data atan2Degrees(Data data1, double data2)
          return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in degrees.
static Data atan2Degrees(double data1, Data data2)
          return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in degrees.
static Data atanDegrees(Data data)
          return pointwise arctan value of data, in degrees
static Data ceil(Data data)
          return pointwise ceil value of data (smallest integer not less than)
static JamaCholeskyDecomposition chol(FlatField data)
          return matrix Cholesky Decomposition of data, as a 1-Tuple (lower_triangular_factor); data should have either a 1-D or 2-D gridded domain
static void clearplot()
          clear the onscreen data display
static void clearplot(java.lang.String name)
          clear the onscreen data display with the given name
static Field combine(Field[] fields)
          combines fields
static double cond(FlatField data)
          return matrix condition of data (ratio of largest to smallest singular value), which should have either a 1-D or 2-D gridded domain
static Data cos(Data data)
          return pointwise cos value of data, assuming input values are in radians unless they have units convertable with radians, in which case those units are converted to radians
static Data cosDegrees(Data data)
          return pointwise cos value of data, assuming input values are in degrees unless they have units convertable with degrees, in which case those units are converted to degrees
static double det(FlatField data)
          return matrix determinant of data, which should have either a 1-D or 2-D gridded domain
static int domainDimension(Data data)
           
static Field domainFactor(Field data, int comp)
          factors out the given domain component (by index) and creates a new data object.
static Field domainFactor(Field data, RealType factor)
          factors out the given MathType from the domain of the data object.
static RealTupleType domainType(Data data)
           
static java.lang.String domainType(Data data, int comp)
          get the name of the given component of the domain RealType.
static void dumpTypes(Data d)
          helper method for the dump(Data|Math)Type() methods this will list both the MathType and DataType information to stdout.
static JamaEigenvalueDecomposition eig(FlatField data)
          return matrix Eigenvalue Decomposition of data, as a 3-Tuple (eigenvector_matrix, real_eigenvalue_components, imaginary_eigenvalue_components); data should have either a 1-D or 2-D gridded domain
static Data evaluate(Field data, double domain)
           
static Data evaluate(Field data, Real domain)
          creates a VisAD Data by evaluating the Field at the point given in the domain.
static Data exp(Data data)
          return pointwise exp value of data
static Field extract(Field data, int comp)
          extracts a component of the Field
static Field extract(Field data, MathType t)
          extracts a component of the Field
static Field extract(Field data, java.lang.String s)
          extracts a component of the Field
static FlatField fft(Field field)
          return forward Fourier transform of field, which should have either a 1-D or 2-D gridded domain; uses fft when domain size is a power of two; returns real and imaginary parts
static FlatField field(float[] values)
          return a VisAD FlatField with default 1-D domain and with range values given by values array
static FlatField field(float[][] values)
          return a VisAD FlatField with default 2-D domain and with range values given by values array
static FlatField field(Set set, java.lang.String name, float[] values)
          return a VisAD FlatField with given 1-D domain set, with range values given by values array, and with given range RealType name
static FlatField field(Set set, java.lang.String name, float[][] values)
          return a VisAD FlatField with given 2-D domain set, with range values given by values array, and with given range RealType name
static FlatField field(java.lang.String name, float[] values)
          return a VisAD FlatField with default 1-D domain, with range values given by values array, and with given range RealType name
static FlatField field(java.lang.String name, float[][] values)
          return a VisAD FlatField with default 2-D domain, with range values given by values array, and with given range RealType name
static FlatField field(java.lang.String dom0, java.lang.String name, float[] values)
          return a VisAD FlatField with default 1-D domain, with range values given by values array, and with given range RealType name
static FlatField field(java.lang.String dom0, java.lang.String dom1, java.lang.String rng, float[][] values)
          return a VisAD FlatField with named default 2-D domain, with range values given by values array and with given range RealType name
static Data floor(Data data)
          return pointwise floor value of data (largest integer not greater than)
static Set getDomain(Data data)
           
static int getDomainDimension(Data data)
          get the number of domain components of the Data object
static Set getDomainSet(Data data)
          return the sampling set for the domain of the Data object
static RealTupleType getDomainType(Data data)
          get the domain Type for the field
static RealTupleType getDomainType(FunctionType type)
          get the domain Type for the FunctionType
static PointDataAdapter getPointDataAdapter(java.lang.String request)
           
static int getRangeDimension(Data data)
          get the number of range components of the Data object
static MathType getRangeType(Data data)
          get the range Type for the field
static MathType getRangeType(FunctionType type)
          get the range Type for the FunctionType
static RealType getRealType(java.lang.String name)
           
static RealType getRealType(java.lang.String name, Unit u)
           
static MathType getType(Data data)
          get the MathType of the named VisAD data object
static double getValue(Real r)
          returns the double value of a Real value.
static double[][] getValues(Field data)
          returns the double values of the range
static FlatField hist(Field field, int[] ranges)
          return histogram of range values of field selected by ranges array, with dimension = ranges.length, and 64 equally spaced bins in each dimension
static FlatField hist(Field field, int[] ranges, int[] sizes)
          return histogram of range values of field selected by ranges array, with dimension = ranges.length, and with number of equally spaced bins in each dimension determined by sizes array
static FlatField hist(Field field, Set set)
          return histogram of range values of field selected by set, with dimension and bin sampling defined by set
static FlatField ifft(Field field)
          return backward Fourier transform of field, which should have either a 1-D or 2-D gridded domain; uses fft when domain size is a power of two; returns real and imaginary parts
static JamaMatrix inverse(FlatField data)
          return matrix inverse of data, which should have either a 1-D or 2-D gridded domain
static DataImpl load(java.lang.String location)
          Reads in data from the given location (filename or URL).
static Data log(Data data)
          return pointwise log value of data
static JamaLUDecomposition lu(FlatField data)
          return matrix LU Decomposition of data, as a 3-Tuple (lower_triangular_factor, upper_triangular_factor, pivot_permutation_vector); data should have either a 1-D or 2-D gridded domain
static Linear1DSet makeDomain(double first, double last, int length)
          create a Linear1DSet for domain samples
static Linear2DSet makeDomain(double first1, double last1, int length1, double first2, double last2, int length2)
          create a Linear2DSet for domain samples
static Linear3DSet makeDomain(double first1, double last1, int length1, double first2, double last2, int length2, double first3, double last3, int length3)
          create a Linear3DSet for domain samples
static Linear1DSet makeDomain(MathType type, double first, double last, int length)
          create a Linear1DSet for domain samples
static Linear2DSet makeDomain(MathType type, double first1, double last1, int length1, double first2, double last2, int length2)
          create a Linear2DSet for domain samples
static Linear3DSet makeDomain(MathType type, double first1, double last1, int length1, double first2, double last2, int length2, double first3, double last3, int length3)
          create a Linear3DSet for domain samples
static Linear1DSet makeDomain(java.lang.String name, double first, double last, int length)
          create a Linear1DSet for domain samples
static Linear2DSet makeDomain(java.lang.String name, double first1, double last1, int length1, double first2, double last2, int length2)
          create a Linear2DSet for domain samples
static Linear3DSet makeDomain(java.lang.String name, double first1, double last1, int length1, double first2, double last2, int length2, double first3, double last3, int length3)
          create a Linear3DSet for domain samples
static RealType makeRealType(java.lang.String name)
          make or get the RealType corresponding to the name; if none exists, make one and return it.
static RealType makeRealType(java.lang.String name, Unit u)
          make or get the RealType corresponding to the name; if none exists, make one and return it.
static MathType makeType(java.lang.String s)
          creates a VisAD MathType from the given string
static Unit makeUnit(java.lang.String name)
          get a VisAD Unit from the name given
static JamaMatrix matrixMultiply(FlatField data1, FlatField data2)
          return matrix multiply of data1 * data2, which should have either 1-D or 2-D gridded domains
static Data max_data(Data data1, Data data2)
          return pointwise maximum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in
static Data max_data(Data data1, double data2)
          return pointwise aximum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in
static Data max_data(double data1, Data data2)
          return pointwise maximum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in
static Data min_data(Data data1, Data data2)
          return pointwise minimum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in
static Data min_data(Data data1, double data2)
          return pointwise minimum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in
static Data min_data(double data1, Data data2)
          return pointwise minimum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in
static double norm1(FlatField data)
          return matrix one norm of data (maximum column sum), which should have either a 1-D or 2-D gridded domain
static double norm2(FlatField data)
          return matrix two norm of data (maximum singular value), which should have either a 1-D or 2-D gridded domain
static double normF(FlatField data)
          return matrix Frobenius norm of data (sqrt of sum of squares of all elements), which should have either a 1-D or 2-D gridded domain
static double normInf(FlatField data)
          return matrix infinity norm of data (maximum row sum), which should have either a 1-D or 2-D gridded domain
static void plot(DataImpl data)
          Displays the given data onscreen.
static void plot(DataImpl data, boolean editMaps)
          Displays the given data onscreen, displaying the edit mappings dialog if specified.
static void plot(DataImpl data, double red, double green, double blue)
          Displays the given data onscreen, using given color default.
static void plot(DataImpl data, ScalarMap[] maps)
          Displays the given data onscreen.
static void plot(java.lang.String name, DataImpl data)
          Displays the given data onscreen.
static void plot(java.lang.String name, DataImpl data, boolean editMaps)
          Displays the given data onscreen in a display with the given name, displaying the edit mappings dialog if specified.
static void plot(java.lang.String namxe, DataImpl data, boolean editMaps, double red, double green, double blue)
          Displays the given data onscreen in a display with the given name, using the given color default and displaying the edit mappings dialog if specified.
static void plot(java.lang.String namxe, DataImpl data, boolean editMaps, double red, double green, double blue, ScalarMap[] maps)
           
static void plot(java.lang.String name, DataImpl data, ScalarMap[] maps)
          Displays the given data onscreen.
static JamaQRDecomposition qr(FlatField data)
          return matrix QR Decomposition of data, as a 2-Tuple (orthogonal_factor, upper_triangular_factor); data should have either a 1-D or 2-D gridded domain
static int rangeDimension(Data data)
           
static MathType rangeType(Data data)
           
static java.lang.String rangeType(Data data, int comp)
          get the name of the given component of the range RealType.
static double rank(FlatField data)
          return matrix effective numerical rank (from SVD) of data, which should have either a 1-D or 2-D gridded domain
static Field resample(Field data, Set s)
          resample the data field into the defined domain set
static Data rint(Data data)
          return pointwise rint value of data (closest integer)
static Data round(Data data)
          return pointwise round value of data (closest integer)
static void saveplot(DisplayImpl disp, java.lang.String filename)
          save the display genreated by a quick graph or showDisplay
static void saveplot(java.lang.String filename)
          save the onscreen data display generated by plot()
static void saveplot(java.lang.String name, java.lang.String filename)
          clear the onscreen data display with the given name
static void setAxesScalesFont(ScalarMap[] sm, java.awt.Font f)
          Set the font to be used for the axes labels and scales
static void showAxesScales(DisplayImpl d, boolean on)
          Turn on/off the axes labels & scales on a Display
static Data sin(Data data)
          return pointwise sin value of data, assuming input values are in radians unless they have units convertable with radians, in which case those units are converted to radians
static Data sinDegrees(Data data)
          return pointwise sin value of data, assuming input values are in degrees unless they have units convertable with degrees, in which case those units are converted to degrees
static JamaMatrix solve(FlatField data1, FlatField data2)
          return matrix soluton X of data1 * X = data2; data12 and data2 should have either 1-D or 2-D gridded domains; return solution if data1 is is square, least squares solution otherwise
static Data sqrt(Data data)
          return pointwise square root value of data
static JamaSingularValueDecomposition svd(FlatField data)
          return matrix Singular Value Decomposition of data, as a 3-Tuple (left_singular_vectors, right_singular_vectors, singular_value_vector); data should have either a 1-D or 2-D gridded domain
static Data tan(Data data)
          return pointwise tan value of data, assuming input values are in radians unless they have units convertable with radians, in which case those units are converted to radians
static Data tanDegrees(Data data)
          return pointwise tan value of data, assuming input values are in degrees unless they have units convertable with degrees, in which case those units are converted to degrees
static double trace(FlatField data)
          return matrix trace of data (sum of the diagonal elements), which should have either a 1-D or 2-D gridded domain
static JamaMatrix transpose(FlatField data)
          return matrix transpose of data, which should have either a 1-D or 2-D gridded domain
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JPythonMethods

public JPythonMethods()
Method Detail

load

public static DataImpl load(java.lang.String location)
                     throws VisADException
Reads in data from the given location (filename or URL).

Throws:
VisADException

plot

public static void plot(DataImpl data)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen.

Parameters:
data - VisAD data object to plot
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(DataImpl data,
                        ScalarMap[] maps)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen.

Parameters:
data - VisAD data object to plot
maps - ScalarMaps for the display
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(DataImpl data,
                        boolean editMaps)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen, displaying the edit mappings dialog if specified.

Parameters:
data - VisAD data object to plot
editMaps - whether to initially display edit mappings dialog
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(java.lang.String name,
                        DataImpl data)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen.

Parameters:
name - name of display in which to plot data
data - VisAD data object to plot
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(java.lang.String name,
                        DataImpl data,
                        ScalarMap[] maps)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen.

Parameters:
name - name of display in which to plot data
data - VisAD data object to plot
maps - ScalarMaps for display
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(java.lang.String name,
                        DataImpl data,
                        boolean editMaps)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen in a display with the given name, displaying the edit mappings dialog if specified.

Parameters:
name - name of display in which to plot data
data - VisAD data object to plot
editMaps - whether to initially display edit mappings dialog
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(DataImpl data,
                        double red,
                        double green,
                        double blue)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen, using given color default.

Parameters:
data - VisAD data object to plot
red - red component of default color to use if there are no color mappings from data's RealTypes; color component values between 0.0 and 1.0
green - green component of default color
blue - blue component of default color
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(java.lang.String namxe,
                        DataImpl data,
                        boolean editMaps,
                        double red,
                        double green,
                        double blue)
                 throws VisADException,
                        java.rmi.RemoteException
Displays the given data onscreen in a display with the given name, using the given color default and displaying the edit mappings dialog if specified.

Parameters:
name - name of display in which to plot data
data - VisAD data object to plot
editMaps - whether to initially display edit mappings dialog
red - red component of default color to use if there are no color mappings from data's RealTypes; color component values between 0.0 and 1.0
green - green component of default color
blue - blue component of default color
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

plot

public static void plot(java.lang.String namxe,
                        DataImpl data,
                        boolean editMaps,
                        double red,
                        double green,
                        double blue,
                        ScalarMap[] maps)
                 throws VisADException,
                        java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException

clearplot

public static void clearplot()
                      throws VisADException,
                             java.rmi.RemoteException
clear the onscreen data display

Throws:
VisADException - part of data and display APIs, shouldn't occur
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

clearplot

public static void clearplot(java.lang.String name)
                      throws VisADException,
                             java.rmi.RemoteException
clear the onscreen data display with the given name

Parameters:
name - name of the display to clear
Throws:
VisADException - part of data and display APIs, shouldn't occur
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

saveplot

public static void saveplot(DisplayImpl disp,
                            java.lang.String filename)
                     throws VisADException,
                            java.rmi.RemoteException,
                            java.io.IOException
save the display genreated by a quick graph or showDisplay

Parameters:
disp - is the DisplayImpl to save
filename - is the name of the JPG file to write
Throws:
VisADException
java.rmi.RemoteException
java.io.IOException

saveplot

public static void saveplot(java.lang.String filename)
                     throws VisADException,
                            java.rmi.RemoteException,
                            java.io.IOException
save the onscreen data display generated by plot()

Throws:
VisADException - part of data and display APIs, shouldn't occur
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.io.IOException

saveplot

public static void saveplot(java.lang.String name,
                            java.lang.String filename)
                     throws VisADException,
                            java.rmi.RemoteException,
                            java.io.IOException
clear the onscreen data display with the given name

Parameters:
name - name of the display to clear
filename - name of the file to save display into
Throws:
VisADException - part of data and display APIs, shouldn't occur
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.io.IOException - part of data and display APIs, shouldn't occur

abs_data

public static Data abs_data(Data data)
                     throws VisADException,
                            java.rmi.RemoteException
return pointwise absolute value of data name changed 1/11/02 to avoid conflicts with Jython built-in

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

acos

public static Data acos(Data data)
                 throws VisADException,
                        java.rmi.RemoteException
return pointwise arccos value of data, in radians

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

acosDegrees

public static Data acosDegrees(Data data)
                        throws VisADException,
                               java.rmi.RemoteException
return pointwise arccos value of data, in degrees

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

asin

public static Data asin(Data data)
                 throws VisADException,
                        java.rmi.RemoteException
return pointwise arcsin value of data, in radians

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

asinDegrees

public static Data asinDegrees(Data data)
                        throws VisADException,
                               java.rmi.RemoteException
return pointwise arcsin value of data, in degrees

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atan

public static Data atan(Data data)
                 throws VisADException,
                        java.rmi.RemoteException
return pointwise arctan value of data, in radians

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atanDegrees

public static Data atanDegrees(Data data)
                        throws VisADException,
                               java.rmi.RemoteException
return pointwise arctan value of data, in degrees

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

ceil

public static Data ceil(Data data)
                 throws VisADException,
                        java.rmi.RemoteException
return pointwise ceil value of data (smallest integer not less than)

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

cos

public static Data cos(Data data)
                throws VisADException,
                       java.rmi.RemoteException
return pointwise cos value of data, assuming input values are in radians unless they have units convertable with radians, in which case those units are converted to radians

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

cosDegrees

public static Data cosDegrees(Data data)
                       throws VisADException,
                              java.rmi.RemoteException
return pointwise cos value of data, assuming input values are in degrees unless they have units convertable with degrees, in which case those units are converted to degrees

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

exp

public static Data exp(Data data)
                throws VisADException,
                       java.rmi.RemoteException
return pointwise exp value of data

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

floor

public static Data floor(Data data)
                  throws VisADException,
                         java.rmi.RemoteException
return pointwise floor value of data (largest integer not greater than)

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

log

public static Data log(Data data)
                throws VisADException,
                       java.rmi.RemoteException
return pointwise log value of data

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

rint

public static Data rint(Data data)
                 throws VisADException,
                        java.rmi.RemoteException
return pointwise rint value of data (closest integer)

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

round

public static Data round(Data data)
                  throws VisADException,
                         java.rmi.RemoteException
return pointwise round value of data (closest integer)

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

sin

public static Data sin(Data data)
                throws VisADException,
                       java.rmi.RemoteException
return pointwise sin value of data, assuming input values are in radians unless they have units convertable with radians, in which case those units are converted to radians

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

sinDegrees

public static Data sinDegrees(Data data)
                       throws VisADException,
                              java.rmi.RemoteException
return pointwise sin value of data, assuming input values are in degrees unless they have units convertable with degrees, in which case those units are converted to degrees

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

sqrt

public static Data sqrt(Data data)
                 throws VisADException,
                        java.rmi.RemoteException
return pointwise square root value of data

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

tan

public static Data tan(Data data)
                throws VisADException,
                       java.rmi.RemoteException
return pointwise tan value of data, assuming input values are in radians unless they have units convertable with radians, in which case those units are converted to radians

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

tanDegrees

public static Data tanDegrees(Data data)
                       throws VisADException,
                              java.rmi.RemoteException
return pointwise tan value of data, assuming input values are in degrees unless they have units convertable with degrees, in which case those units are converted to degrees

Parameters:
data - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

max_data

public static Data max_data(Data data1,
                            Data data2)
                     throws VisADException,
                            java.rmi.RemoteException
return pointwise maximum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in

Parameters:
data1 - VisAD data object
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

min_data

public static Data min_data(Data data1,
                            Data data2)
                     throws VisADException,
                            java.rmi.RemoteException
return pointwise minimum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in

Parameters:
data1 - VisAD data object
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atan2

public static Data atan2(Data data1,
                         Data data2)
                  throws VisADException,
                         java.rmi.RemoteException
return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in radians.

Parameters:
data1 - VisAD data object
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atan2Degrees

public static Data atan2Degrees(Data data1,
                                Data data2)
                         throws VisADException,
                                java.rmi.RemoteException
return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in degrees.

Parameters:
data1 - VisAD data object
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

max_data

public static Data max_data(Data data1,
                            double data2)
                     throws VisADException,
                            java.rmi.RemoteException
return pointwise aximum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in

Parameters:
data1 - VisAD data object
data2 - double value
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

min_data

public static Data min_data(Data data1,
                            double data2)
                     throws VisADException,
                            java.rmi.RemoteException
return pointwise minimum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in

Parameters:
data1 - VisAD data object
data2 - double value
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atan2

public static Data atan2(Data data1,
                         double data2)
                  throws VisADException,
                         java.rmi.RemoteException
return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in radians.

Parameters:
data1 - VisAD data object
data2 - double value
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atan2Degrees

public static Data atan2Degrees(Data data1,
                                double data2)
                         throws VisADException,
                                java.rmi.RemoteException
return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in degrees.

Parameters:
data1 - VisAD data object
data2 - double value
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

max_data

public static Data max_data(double data1,
                            Data data2)
                     throws VisADException,
                            java.rmi.RemoteException
return pointwise maximum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in

Parameters:
data1 - double value
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

min_data

public static Data min_data(double data1,
                            Data data2)
                     throws VisADException,
                            java.rmi.RemoteException
return pointwise minimum value of data1 and data2 name changed 1/11/02 to avoid conflicts with Jython built-in

Parameters:
data1 - double value
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atan2

public static Data atan2(double data1,
                         Data data2)
                  throws VisADException,
                         java.rmi.RemoteException
return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in radians.

Parameters:
data1 - double value
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

atan2Degrees

public static Data atan2Degrees(double data1,
                                Data data2)
                         throws VisADException,
                                java.rmi.RemoteException
return pointwise arc tangent value of data1 / data2 over full (-pi, pi) range, returned in degrees.

Parameters:
data1 - double value
data2 - VisAD data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote data

fft

public static FlatField fft(Field field)
                     throws VisADException,
                            java.rmi.RemoteException
return forward Fourier transform of field, which should have either a 1-D or 2-D gridded domain; uses fft when domain size is a power of two; returns real and imaginary parts

Parameters:
field - VisAD Field data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote field

ifft

public static FlatField ifft(Field field)
                      throws VisADException,
                             java.rmi.RemoteException
return backward Fourier transform of field, which should have either a 1-D or 2-D gridded domain; uses fft when domain size is a power of two; returns real and imaginary parts

Parameters:
field - VisAD Field data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote field

matrixMultiply

public static JamaMatrix matrixMultiply(FlatField data1,
                                        FlatField data2)
                                 throws VisADException,
                                        java.rmi.RemoteException,
                                        java.lang.IllegalAccessException,
                                        java.lang.InstantiationException,
                                        java.lang.reflect.InvocationTargetException
return matrix multiply of data1 * data2, which should have either 1-D or 2-D gridded domains

Parameters:
data1 - VisAD FlatField data object
data2 - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

solve

public static JamaMatrix solve(FlatField data1,
                               FlatField data2)
                        throws VisADException,
                               java.rmi.RemoteException,
                               java.lang.IllegalAccessException,
                               java.lang.InstantiationException,
                               java.lang.reflect.InvocationTargetException
return matrix soluton X of data1 * X = data2; data12 and data2 should have either 1-D or 2-D gridded domains; return solution if data1 is is square, least squares solution otherwise

Parameters:
data1 - VisAD FlatField data object
data2 - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

inverse

public static JamaMatrix inverse(FlatField data)
                          throws VisADException,
                                 java.rmi.RemoteException,
                                 java.lang.IllegalAccessException,
                                 java.lang.InstantiationException,
                                 java.lang.reflect.InvocationTargetException
return matrix inverse of data, which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

transpose

public static JamaMatrix transpose(FlatField data)
                            throws VisADException,
                                   java.rmi.RemoteException,
                                   java.lang.IllegalAccessException,
                                   java.lang.InstantiationException,
                                   java.lang.reflect.InvocationTargetException
return matrix transpose of data, which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

det

public static double det(FlatField data)
                  throws VisADException,
                         java.rmi.RemoteException,
                         java.lang.IllegalAccessException,
                         java.lang.InstantiationException,
                         java.lang.reflect.InvocationTargetException
return matrix determinant of data, which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

norm1

public static double norm1(FlatField data)
                    throws VisADException,
                           java.rmi.RemoteException,
                           java.lang.IllegalAccessException,
                           java.lang.InstantiationException,
                           java.lang.reflect.InvocationTargetException
return matrix one norm of data (maximum column sum), which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

norm2

public static double norm2(FlatField data)
                    throws VisADException,
                           java.rmi.RemoteException,
                           java.lang.IllegalAccessException,
                           java.lang.InstantiationException,
                           java.lang.reflect.InvocationTargetException
return matrix two norm of data (maximum singular value), which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

normInf

public static double normInf(FlatField data)
                      throws VisADException,
                             java.rmi.RemoteException,
                             java.lang.IllegalAccessException,
                             java.lang.InstantiationException,
                             java.lang.reflect.InvocationTargetException
return matrix infinity norm of data (maximum row sum), which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

normF

public static double normF(FlatField data)
                    throws VisADException,
                           java.rmi.RemoteException,
                           java.lang.IllegalAccessException,
                           java.lang.InstantiationException,
                           java.lang.reflect.InvocationTargetException
return matrix Frobenius norm of data (sqrt of sum of squares of all elements), which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

rank

public static double rank(FlatField data)
                   throws VisADException,
                          java.rmi.RemoteException,
                          java.lang.IllegalAccessException,
                          java.lang.InstantiationException,
                          java.lang.reflect.InvocationTargetException
return matrix effective numerical rank (from SVD) of data, which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

cond

public static double cond(FlatField data)
                   throws VisADException,
                          java.rmi.RemoteException,
                          java.lang.IllegalAccessException,
                          java.lang.InstantiationException,
                          java.lang.reflect.InvocationTargetException
return matrix condition of data (ratio of largest to smallest singular value), which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

trace

public static double trace(FlatField data)
                    throws VisADException,
                           java.rmi.RemoteException,
                           java.lang.IllegalAccessException,
                           java.lang.InstantiationException,
                           java.lang.reflect.InvocationTargetException
return matrix trace of data (sum of the diagonal elements), which should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

chol

public static JamaCholeskyDecomposition chol(FlatField data)
                                      throws VisADException,
                                             java.rmi.RemoteException,
                                             java.lang.IllegalAccessException,
                                             java.lang.InstantiationException,
                                             java.lang.reflect.InvocationTargetException
return matrix Cholesky Decomposition of data, as a 1-Tuple (lower_triangular_factor); data should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

eig

public static JamaEigenvalueDecomposition eig(FlatField data)
                                       throws VisADException,
                                              java.rmi.RemoteException,
                                              java.lang.IllegalAccessException,
                                              java.lang.InstantiationException,
                                              java.lang.reflect.InvocationTargetException
return matrix Eigenvalue Decomposition of data, as a 3-Tuple (eigenvector_matrix, real_eigenvalue_components, imaginary_eigenvalue_components); data should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

lu

public static JamaLUDecomposition lu(FlatField data)
                              throws VisADException,
                                     java.rmi.RemoteException,
                                     java.lang.IllegalAccessException,
                                     java.lang.InstantiationException,
                                     java.lang.reflect.InvocationTargetException
return matrix LU Decomposition of data, as a 3-Tuple (lower_triangular_factor, upper_triangular_factor, pivot_permutation_vector); data should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

qr

public static JamaQRDecomposition qr(FlatField data)
                              throws VisADException,
                                     java.rmi.RemoteException,
                                     java.lang.IllegalAccessException,
                                     java.lang.InstantiationException,
                                     java.lang.reflect.InvocationTargetException
return matrix QR Decomposition of data, as a 2-Tuple (orthogonal_factor, upper_triangular_factor); data should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

svd

public static JamaSingularValueDecomposition svd(FlatField data)
                                          throws VisADException,
                                                 java.rmi.RemoteException,
                                                 java.lang.IllegalAccessException,
                                                 java.lang.InstantiationException,
                                                 java.lang.reflect.InvocationTargetException
return matrix Singular Value Decomposition of data, as a 3-Tuple (left_singular_vectors, right_singular_vectors, singular_value_vector); data should have either a 1-D or 2-D gridded domain

Parameters:
data - VisAD FlatField data object
Throws:
VisADException - invalid data
java.rmi.RemoteException - part of data and display APIs, shouldn't occur
java.lang.IllegalAccessException - Jama not installed
java.lang.InstantiationException - Jama not installed
java.lang.reflect.InvocationTargetException - Jama not installed

hist

public static FlatField hist(Field field,
                             Set set)
                      throws VisADException,
                             java.rmi.RemoteException
return histogram of range values of field selected by set, with dimension and bin sampling defined by set

Parameters:
field - VisAD Field data object whose range values are analyzed in histogram
set - VisAD Set data object that defines dimension and bin sampling for histogram
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote field

hist

public static FlatField hist(Field field,
                             int[] ranges)
                      throws VisADException,
                             java.rmi.RemoteException
return histogram of range values of field selected by ranges array, with dimension = ranges.length, and 64 equally spaced bins in each dimension

Parameters:
field - VisAD Field data object whose range values are analyzed in histogram
ranges - int[] array whose elements are indices of into the range Tuple of field, selecting range components as dimensions of the histogram
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote field

hist

public static FlatField hist(Field field,
                             int[] ranges,
                             int[] sizes)
                      throws VisADException,
                             java.rmi.RemoteException
return histogram of range values of field selected by ranges array, with dimension = ranges.length, and with number of equally spaced bins in each dimension determined by sizes array

Parameters:
field - VisAD Field data object whose range values are analyzed in histogram
ranges - int[] array whose elements are indices of into the range Tuple of field, selecting range components as dimensions of the histogram
sizes - int[] array whose elements are numbers of equally spaced bins for each dimension
Throws:
VisADException - invalid data
java.rmi.RemoteException - unable to access remote field

field

public static FlatField field(float[] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with default 1-D domain and with range values given by values array

Parameters:
values - float[] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

field

public static FlatField field(java.lang.String name,
                              float[] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with default 1-D domain, with range values given by values array, and with given range RealType name

Parameters:
name - String defining range RealType name
values - float[] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

field

public static FlatField field(java.lang.String dom0,
                              java.lang.String name,
                              float[] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with default 1-D domain, with range values given by values array, and with given range RealType name

Parameters:
dom0 - String defining domain RealType name
name - String defining range RealType name
values - float[] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

field

public static FlatField field(Set set,
                              java.lang.String name,
                              float[] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with given 1-D domain set, with range values given by values array, and with given range RealType name

Parameters:
set - VisAD Set defining 1-D domain
name - String defining range RealType name
values - float[] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

field

public static FlatField field(float[][] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with default 2-D domain and with range values given by values array

Parameters:
values - float[][] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

field

public static FlatField field(java.lang.String name,
                              float[][] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with default 2-D domain, with range values given by values array, and with given range RealType name

Parameters:
name - String defining range RealType name
values - float[][] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

field

public static FlatField field(java.lang.String dom0,
                              java.lang.String dom1,
                              java.lang.String rng,
                              float[][] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with named default 2-D domain, with range values given by values array and with given range RealType name

Parameters:
dom0 - String defines first domain component
dom1 - String defines second domain component
name - String defining range RealType name
values - float[][] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

field

public static FlatField field(Set set,
                              java.lang.String name,
                              float[][] values)
                       throws VisADException,
                              java.rmi.RemoteException
return a VisAD FlatField with given 2-D domain set, with range values given by values array, and with given range RealType name

Parameters:
set - VisAD Set defining 2-D domain
name - String defining range RealType name
values - float[][] array defining range values of field
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

getDomainDimension

public static int getDomainDimension(Data data)
                              throws VisADException,
                                     java.rmi.RemoteException
get the number of domain components of the Data object

Parameters:
Data - VisAD Data object
Returns:
the number of domain components
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

domainDimension

public static int domainDimension(Data data)
                           throws VisADException,
                                  java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException

getRangeDimension

public static int getRangeDimension(Data data)
                             throws VisADException,
                                    java.rmi.RemoteException
get the number of range components of the Data object

Parameters:
Data - VisAD Data object
Returns:
the number of range components
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

rangeDimension

public static int rangeDimension(Data data)
                          throws VisADException,
                                 java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException

getDomainType

public static RealTupleType getDomainType(Data data)
                                   throws VisADException,
                                          java.rmi.RemoteException
get the domain Type for the field

Parameters:
data - is the field to get the domain Type for
Returns:
the domain
Throws:
VisADException
java.rmi.RemoteException

domainType

public static RealTupleType domainType(Data data)
                                throws VisADException,
                                       java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException

getDomainType

public static RealTupleType getDomainType(FunctionType type)
                                   throws VisADException,
                                          java.rmi.RemoteException
get the domain Type for the FunctionType

Parameters:
type - is the FunctionType
Returns:
the domain type
Throws:
VisADException
java.rmi.RemoteException

getRangeType

public static MathType getRangeType(Data data)
                             throws VisADException,
                                    java.rmi.RemoteException
get the range Type for the field

Parameters:
data - is the field to get the range Type for
Returns:
the range
Throws:
VisADException
java.rmi.RemoteException

rangeType

public static MathType rangeType(Data data)
                          throws VisADException,
                                 java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException

getRangeType

public static MathType getRangeType(FunctionType type)
                             throws VisADException,
                                    java.rmi.RemoteException
get the range Type for the FunctionType

Parameters:
type - is the FunctionType
Returns:
the range Type
Throws:
VisADException
java.rmi.RemoteException

domainType

public static java.lang.String domainType(Data data,
                                          int comp)
                                   throws VisADException,
                                          java.rmi.RemoteException
get the name of the given component of the domain RealType.

Parameters:
Data - VisAD Data object
comp - the domain component index (0...)
Returns:
the name of the RealType
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

rangeType

public static java.lang.String rangeType(Data data,
                                         int comp)
                                  throws VisADException,
                                         java.rmi.RemoteException
get the name of the given component of the range RealType.

Parameters:
Data - VisAD Data object
comp - the component index (0...)
Returns:
the name of the RealType
Throws:
VisADException - unable to construct field
java.rmi.RemoteException - part of data and display APIs, shouldn't occur

makeUnit

public static Unit makeUnit(java.lang.String name)
                     throws NoSuchUnitException,
                            ParseException
get a VisAD Unit from the name given

Parameters:
name - name of unit desired (degC, etc)
Returns:
the Unit corresponding to the name
Throws:
NoSuchUnitException
ParseException

makeDomain

public static Linear1DSet makeDomain(double first,
                                     double last,
                                     int length)
                              throws VisADException
create a Linear1DSet for domain samples

Parameters:
first - is the first value in the linear set
last - is the last value in the linear set
length - is the number of values in the set
Returns:
the created visad.Linear1DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException

makeDomain

public static Linear1DSet makeDomain(MathType type,
                                     double first,
                                     double last,
                                     int length)
                              throws VisADException
create a Linear1DSet for domain samples

Parameters:
type - is the VisAD MathType of this set
first - is the first value in the linear set
last - is the last value in the linear set
length - is the number of values in the set
Returns:
the created visad.Linear1DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException

makeDomain

public static Linear1DSet makeDomain(java.lang.String name,
                                     double first,
                                     double last,
                                     int length)
                              throws VisADException
create a Linear1DSet for domain samples

Parameters:
name - is the name of the VisAD MathType of this set
first - is the first value in the linear set
last - is the last value in the linear set
length - is the number of values in the set
Returns:
the created visad.Linear1DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException

makeDomain

public static Linear2DSet makeDomain(double first1,
                                     double last1,
                                     int length1,
                                     double first2,
                                     double last2,
                                     int length2)
                              throws VisADException
create a Linear2DSet for domain samples

Parameters:
first1 - is the first value in the linear set's 1st dimension
last1 - is the last value in the linear set's 1st dimension
length1 - is the number of values in the set's 1st dimension
first2 - is the first value in the linear set's 2nd dimension
last2 - is the last value in the linear set's 2nd dimension
length2 - is the number of values in the set's 2nd dimension
Returns:
the created visad.Linear2DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException

makeDomain

public static Linear2DSet makeDomain(MathType type,
                                     double first1,
                                     double last1,
                                     int length1,
                                     double first2,
                                     double last2,
                                     int length2)
                              throws VisADException
create a Linear2DSet for domain samples

Parameters:
type - is the VisAD MathType of this set
first1 - is the first value in the linear set's 1st dimension
last1 - is the last value in the linear set's 1st dimension
length1 - is the number of values in the set's 1st dimension
first2 - is the first value in the linear set's 2nd dimension
last2 - is the last value in the linear set's 2nd dimension
length2 - is the number of values in the set's 2nd dimension
Returns:
the created visad.Linear2DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException

makeDomain

public static Linear2DSet makeDomain(java.lang.String name,
                                     double first1,
                                     double last1,
                                     int length1,
                                     double first2,
                                     double last2,
                                     int length2)
                              throws VisADException,
                                     java.rmi.RemoteException
create a Linear2DSet for domain samples

Parameters:
name - is the name of the VisAD MathType of this set
first1 - is the first value in the linear set's 1st dimension
last1 - is the last value in the linear set's 1st dimension
length1 - is the number of values in the set's 1st dimension
first2 - is the first value in the linear set's 2nd dimension
last2 - is the last value in the linear set's 2nd dimension
length2 - is the number of values in the set's 2nd dimension
Returns:
the created visad.Linear2DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException
java.rmi.RemoteException

makeDomain

public static Linear3DSet makeDomain(double first1,
                                     double last1,
                                     int length1,
                                     double first2,
                                     double last2,
                                     int length2,
                                     double first3,
                                     double last3,
                                     int length3)
                              throws VisADException
create a Linear3DSet for domain samples

Parameters:
first1 - is the first value in the linear set's 1st dimension
last1 - is the last value in the linear set's 1st dimension
length1 - is the number of values in the set's 1st dimension
first2 - is the first value in the linear set's 2nd dimension
last2 - is the last value in the linear set's 2nd dimension
length2 - is the number of values in the set's 2nd dimension
first3 - is the first value in the linear set's 3rd dimension
last3 - is the last value in the linear set's 3rd dimension
length3 - is the number of values in the set's 3rd dimension
Returns:
the created visad.Linear3DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException

makeDomain

public static Linear3DSet makeDomain(MathType type,
                                     double first1,
                                     double last1,
                                     int length1,
                                     double first2,
                                     double last2,
                                     int length2,
                                     double first3,
                                     double last3,
                                     int length3)
                              throws VisADException
create a Linear3DSet for domain samples

Parameters:
type - is the VisAD MathType of this set
first1 - is the first value in the linear set's 1st dimension
last1 - is the last value in the linear set's 1st dimension
length1 - is the number of values in the set's 1st dimension
first2 - is the first value in the linear set's 2nd dimension
last2 - is the last value in the linear set's 2nd dimension
length2 - is the number of values in the set's 2nd dimension
first3 - is the first value in the linear set's 3rd dimension
last3 - is the last value in the linear set's 3rd dimension
length3 - is the number of values in the set's 3rd dimension
Returns:
the created visad.Linear3DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException

makeDomain

public static Linear3DSet makeDomain(java.lang.String name,
                                     double first1,
                                     double last1,
                                     int length1,
                                     double first2,
                                     double last2,
                                     int length2,
                                     double first3,
                                     double last3,
                                     int length3)
                              throws VisADException,
                                     java.rmi.RemoteException
create a Linear3DSet for domain samples

Parameters:
name - is the name of the VisAD MathType of this set
first1 - is the first value in the linear set's 1st dimension
last1 - is the last value in the linear set's 1st dimension
length1 - is the number of values in the set's 1st dimension
first2 - is the first value in the linear set's 2nd dimension
last2 - is the last value in the linear set's 2nd dimension
length2 - is the number of values in the set's 2nd dimension
first3 - is the first value in the linear set's 3rd dimension
last3 - is the last value in the linear set's 3rd dimension
length3 - is the number of values in the set's 3rd dimension
Returns:
the created visad.Linear3DSet Note: this is for testing ONLY and may not remain!
Throws:
VisADException
java.rmi.RemoteException

getDomainSet

public static Set getDomainSet(Data data)
                        throws VisADException,
                               java.rmi.RemoteException
return the sampling set for the domain of the Data object

Parameters:
data - is the VisAD data object
Returns:
the sampling Set
Throws:
VisADException
java.rmi.RemoteException

getDomain

public static Set getDomain(Data data)
                     throws VisADException,
                            java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException

resample

public static Field resample(Field data,
                             Set s)
                      throws VisADException,
                             java.rmi.RemoteException
resample the data field into the defined domain set

Parameters:
data - is the input Field
s - is the Set which must have a domain MathType identical to data's original
Returns:
the new Field
Throws:
VisADException
java.rmi.RemoteException

getValue

public static double getValue(Real r)
returns the double value of a Real value.

Parameters:
r - is the Real
Returns:
value of the Real

getValues

public static double[][] getValues(Field data)
                            throws VisADException,
                                   java.rmi.RemoteException
returns the double values of the range

Parameters:
data - is the Field from which to get the numeric values
Returns:
values for all range components in the Field
Throws:
VisADException
java.rmi.RemoteException

combine

public static Field combine(Field[] fields)
                     throws VisADException,
                            java.rmi.RemoteException
combines fields

Parameters:
fields[] - array of fields
Returns:
the new Field
Throws:
VisADException
java.rmi.RemoteException

extract

public static Field extract(Field data,
                            MathType t)
                     throws VisADException,
                            java.rmi.RemoteException
extracts a component of the Field

Parameters:
data - the field with multiple range componenents
t - the MathType of the field to extract
Returns:
the new Field
Throws:
VisADException
java.rmi.RemoteException

extract

public static Field extract(Field data,
                            java.lang.String s)
                     throws VisADException,
                            java.rmi.RemoteException
extracts a component of the Field

Parameters:
data - the field with multiple range componenents
s - the name of the components to extract
Returns:
the new Field
Throws:
VisADException
java.rmi.RemoteException

extract

public static Field extract(Field data,
                            int comp)
                     throws VisADException,
                            java.rmi.RemoteException
extracts a component of the Field

Parameters:
data - the field with multiple range componenents
comp - the index of the component to extract
Returns:
the new Field
Throws:
VisADException
java.rmi.RemoteException

domainFactor

public static Field domainFactor(Field data,
                                 RealType factor)
                          throws VisADException,
                                 java.rmi.RemoteException
factors out the given MathType from the domain of the data object. For example, if the data has a MathType: (Line, Element)->(value) then factoring out Element, creates a new data object with a MathType: Element->(Line->(value))

Parameters:
factor - is the domain component Type to factor out
Returns:
the new Field
Throws:
VisADException
java.rmi.RemoteException

domainFactor

public static Field domainFactor(Field data,
                                 int comp)
                          throws VisADException,
                                 java.rmi.RemoteException
factors out the given domain component (by index) and creates a new data object. See above.

Returns:
the new Field
Throws:
VisADException
java.rmi.RemoteException

evaluate

public static Data evaluate(Field data,
                            Real domain)
                     throws VisADException,
                            java.rmi.RemoteException
creates a VisAD Data by evaluating the Field at the point given in the domain.

Parameters:
data - is the field
domain - is the Real domain where the field should be evaluated
Throws:
VisADException
java.rmi.RemoteException

evaluate

public static Data evaluate(Field data,
                            double domain)
                     throws VisADException,
                            java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException

makeType

public static MathType makeType(java.lang.String s)
                         throws VisADException,
                                java.rmi.RemoteException
creates a VisAD MathType from the given string

Parameters:
s - is the string describing the names in the form: (x,y)->(a) for a Field. It can be as simple as "foo" for a single RealType.
Throws:
VisADException
java.rmi.RemoteException

makeRealType

public static RealType makeRealType(java.lang.String name)
make or get the RealType corresponding to the name; if none exists, make one and return it.

Parameters:
name - is the name of the RealType type.

getRealType

public static RealType getRealType(java.lang.String name)

makeRealType

public static RealType makeRealType(java.lang.String name,
                                    Unit u)
make or get the RealType corresponding to the name; if none exists, make one and return it.

Parameters:
name - is the name of the RealType type.
unit - is the new Unit to associate with this (must be compatible with any existing Unit)

getRealType

public static RealType getRealType(java.lang.String name,
                                   Unit u)

getType

public static MathType getType(Data data)
                        throws VisADException,
                               java.rmi.RemoteException
get the MathType of the named VisAD data object

Parameters:
data - is the VisAD Data object
Throws:
VisADException
java.rmi.RemoteException

showAxesScales

public static void showAxesScales(DisplayImpl d,
                                  boolean on)
                           throws VisADException,
                                  java.rmi.RemoteException
Turn on/off the axes labels & scales on a Display

Parameters:
d - the DisplayImpl to address
onoff - whether to turn the axes labels on (true)
Throws:
VisADException
java.rmi.RemoteException

setAxesScalesFont

public static void setAxesScalesFont(ScalarMap[] sm,
                                     java.awt.Font f)
                              throws VisADException,
                                     java.rmi.RemoteException
Set the font to be used for the axes labels and scales

Parameters:
sm - the array of ScalarMaps
f - the java.awt.Font to use
Throws:
VisADException
java.rmi.RemoteException

dumpTypes

public static void dumpTypes(Data d)
                      throws VisADException,
                             java.rmi.RemoteException
helper method for the dump(Data|Math)Type() methods this will list both the MathType and DataType information to stdout.

Parameters:
d - is the Data object
Throws:
VisADException
java.rmi.RemoteException

getPointDataAdapter

public static PointDataAdapter getPointDataAdapter(java.lang.String request)
                                            throws VisADException,
                                                   java.rmi.RemoteException
Throws:
VisADException
java.rmi.RemoteException