plugins.big.bigsnakeutils.icy.ellipsoid
Class Ellipsoid3D

java.lang.Object
  extended by plugins.big.bigsnakeutils.icy.ellipsoid.AbstractEllipsoid
      extended by plugins.big.bigsnakeutils.icy.ellipsoid.Ellipsoid3D

public class Ellipsoid3D
extends AbstractEllipsoid

Class describing a 3D ellipsoid.

Version:
May 3, 2014
Author:
Julien Jacquemot, Ricard Delgado-Gonzalo (ricard.delgado@gmail.com)

Field Summary
 double a
          One of the axis of the ellipsoid.
 double alpha
          One of the angle of the ellipsoid.
 double b
          One of the axis of the ellipsoid.
 double beta
          One of the angle of the ellipsoid.
 double c
          One of the axis of the ellipsoid.
 double gamma
          One of the angle of the ellipsoid.
 double x0
          x coordinate of the center of the ellipsoid.
 double y0
          y coordinate of the center of the ellipsoid.
 double z0
          z coordinate of the center of the ellipsoid.
 
Constructor Summary
Ellipsoid3D()
          Default constructor.
Ellipsoid3D(Ellipsoid3D other)
          Copy constructor.
Ellipsoid3D(int t)
          Default constructor.
 
Method Summary
 AbstractEllipsoid clone()
          Return another instance of this descriptor sharing the same properties.
 boolean contains(double x, double y, double z)
          Returns true if the given point is inside the ellipsoid.
 boolean contains(double x, double y, double z, double[] R)
          Returns true if the give point is insid the ellipsoid.
 double getMaximalRadius()
          Maximum radius of the ellipsoid.
 double getMinimalRadius()
          Minimum radius of the ellipsoid.
 double getPerimeter()
          Perimeter of the ellipsoid (surface in 3D).
 double[] getRotationMatrix()
          Return the matrix of rotation corresponding to the ellipsoid orientation.
 double getVolume()
          Volume of the ellipsoid (surface in 2D).
 Ellipsoid2D intersectionAtZ(int layer)
          Returns the intersection of this ellipsoid with a plan z = layer.
 boolean isOver(double x, double y, double z)
          Return true if the given point is on the surface of the ellipsoid.
 boolean isValid()
          Return true if the descriptor represents a valid ellipsoid.
 icy.roi.ROI toROI()
          Return a new ROI corresponding to this descriptor.
 java.lang.String toString()
           
 
Methods inherited from class plugins.big.bigsnakeutils.icy.ellipsoid.AbstractEllipsoid
applyRotation, getProperty, getT, multiplyMatrices, setProperty, setT, transposeMatrix
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

a

public double a
One of the axis of the ellipsoid.


b

public double b
One of the axis of the ellipsoid.


c

public double c
One of the axis of the ellipsoid.


x0

public double x0
x coordinate of the center of the ellipsoid.


y0

public double y0
y coordinate of the center of the ellipsoid.


z0

public double z0
z coordinate of the center of the ellipsoid.


alpha

public double alpha
One of the angle of the ellipsoid.


beta

public double beta
One of the angle of the ellipsoid.


gamma

public double gamma
One of the angle of the ellipsoid.

Constructor Detail

Ellipsoid3D

public Ellipsoid3D()
Default constructor.


Ellipsoid3D

public Ellipsoid3D(int t)
Default constructor.

Parameters:
t - Time corresponding to this cell.

Ellipsoid3D

public Ellipsoid3D(Ellipsoid3D other)
Copy constructor.

Parameters:
other - Cell to copy.
Method Detail

clone

public AbstractEllipsoid clone()
Description copied from class: AbstractEllipsoid
Return another instance of this descriptor sharing the same properties.

Specified by:
clone in class AbstractEllipsoid

isValid

public boolean isValid()
Description copied from class: AbstractEllipsoid
Return true if the descriptor represents a valid ellipsoid.

Specified by:
isValid in class AbstractEllipsoid

getMinimalRadius

public double getMinimalRadius()
Description copied from class: AbstractEllipsoid
Minimum radius of the ellipsoid.

Specified by:
getMinimalRadius in class AbstractEllipsoid

getMaximalRadius

public double getMaximalRadius()
Description copied from class: AbstractEllipsoid
Maximum radius of the ellipsoid.

Specified by:
getMaximalRadius in class AbstractEllipsoid

getPerimeter

public double getPerimeter()
Description copied from class: AbstractEllipsoid
Perimeter of the ellipsoid (surface in 3D).

Specified by:
getPerimeter in class AbstractEllipsoid

getVolume

public double getVolume()
Description copied from class: AbstractEllipsoid
Volume of the ellipsoid (surface in 2D).

Specified by:
getVolume in class AbstractEllipsoid

getRotationMatrix

public double[] getRotationMatrix()
Description copied from class: AbstractEllipsoid
Return the matrix of rotation corresponding to the ellipsoid orientation.

Specified by:
getRotationMatrix in class AbstractEllipsoid

toROI

public icy.roi.ROI toROI()
Description copied from class: AbstractEllipsoid
Return a new ROI corresponding to this descriptor.

Specified by:
toROI in class AbstractEllipsoid

toString

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

intersectionAtZ

public Ellipsoid2D intersectionAtZ(int layer)
Returns the intersection of this ellipsoid with a plan z = layer.

Returns:
If the plane doesn't intersect the ellispoid, returns null.

contains

public boolean contains(double x,
                        double y,
                        double z)
Returns true if the given point is inside the ellipsoid.


contains

public boolean contains(double x,
                        double y,
                        double z,
                        double[] R)
Returns true if the give point is insid the ellipsoid.

Parameters:
R - Rotation matrix of the ellipse.

isOver

public boolean isOver(double x,
                      double y,
                      double z)
Return true if the given point is on the surface of the ellipsoid.