edu.jhu.bme.smile.commons.math.specialFunctions
Class SphericalHarmonics

java.lang.Object
  extended by edu.jhu.bme.smile.commons.math.specialFunctions.SphericalHarmonics

public class SphericalHarmonics
extends java.lang.Object


Field Summary
protected  int[] L
           
protected  int[] M
           
protected  ComplexMatrix matSHProj
           
protected  ComplexMatrix matSHRecon
           
 
Constructor Summary
SphericalHarmonics()
           
 
Method Summary
static double[][] cart2sph(int SHorder, float[][] grads)
           
static void createLM(int order, int[][] LM)
           
static SphericalHarmonics evenOrderTransform(int order, double[] TH, double[] PH)
           
static SphericalHarmonics evenOrderTransform(int SHorder, float[][] grads)
           
static Complex getCoeff(int L, int M, double Theta, double Phi)
          % NOTE: It is very important to keep the various usages of THETA and PHI % straight.
static double getFRTCoeff(int L, int M, double Theta, double Phi)
           
 int getL(int r)
           
 int getM(int r)
           
 ComplexMatrix getRecon()
           
 ComplexVector inverseTransform(double[] realData)
           
 ComplexVector inverseTransform(double[] realData, double[] imagData)
           
 ComplexVector inverseTransform(SphericalHarmonicRepresentation complexData)
           
 ComplexMatrix matSHProj()
           
static int numberOfCoefficientsInEvenOrder(int order)
           
 void recordLM(int[][] LM)
           
 java.lang.String toString()
           
 SphericalHarmonicRepresentation transform(double[] realData)
           
 SphericalHarmonicRepresentation transform(double[] realData, double[] imagData)
           
 SphericalHarmonicRepresentation transform(SphericalHarmonicRepresentation complexData)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

matSHRecon

protected ComplexMatrix matSHRecon

matSHProj

protected ComplexMatrix matSHProj

L

protected int[] L

M

protected int[] M
Constructor Detail

SphericalHarmonics

public SphericalHarmonics()
Method Detail

recordLM

public void recordLM(int[][] LM)

getL

public int getL(int r)

getM

public int getM(int r)

getRecon

public ComplexMatrix getRecon()

matSHProj

public ComplexMatrix matSHProj()

numberOfCoefficientsInEvenOrder

public static int numberOfCoefficientsInEvenOrder(int order)

createLM

public static void createLM(int order,
                            int[][] LM)

evenOrderTransform

public static SphericalHarmonics evenOrderTransform(int order,
                                                    double[] TH,
                                                    double[] PH)

transform

public SphericalHarmonicRepresentation transform(SphericalHarmonicRepresentation complexData)

transform

public SphericalHarmonicRepresentation transform(double[] realData)

transform

public SphericalHarmonicRepresentation transform(double[] realData,
                                                 double[] imagData)

inverseTransform

public ComplexVector inverseTransform(SphericalHarmonicRepresentation complexData)

inverseTransform

public ComplexVector inverseTransform(double[] realData)

inverseTransform

public ComplexVector inverseTransform(double[] realData,
                                      double[] imagData)

getCoeff

public static Complex getCoeff(int L,
                               int M,
                               double Theta,
                               double Phi)
% NOTE: It is very important to keep the various usages of THETA and PHI % straight. For this function THETA is the Azimuthal/Longitude/Circumferential % coordinate and is defined on the interval [0,2*pi], whereas PHI is the % Altitude/Latitude/Elevation and is defined on the interval [0,pi]. Also note that % the conversion to cartesian coordinates requires that PHI be offset by pi/2 so % that the conversion is on the interval [-pi/2,pi/2].

Parameters:
L - - Spherical harmonic degree, [1x1]
M - - Spherical harmonic order, [1x1]
Theta - - Circumferential coordinates
Phi - - Latitudinal coordinates
Returns:

getFRTCoeff

public static double getFRTCoeff(int L,
                                 int M,
                                 double Theta,
                                 double Phi)

evenOrderTransform

public static SphericalHarmonics evenOrderTransform(int SHorder,
                                                    float[][] grads)

cart2sph

public static double[][] cart2sph(int SHorder,
                                  float[][] grads)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object