Package cds.healpix.common.sphgeom

# Class Cone

java.lang.Object
cds.healpix.common.sphgeom.CooXYZ
cds.healpix.common.sphgeom.Cone

public final class Cone extends CooXYZ
Defines a cone on the unit sphere.

Author:
  F.-X. Pineau

## Constructor Summary

Constructors
Constructor
Description
`Cone(double lonRad, double latRad, double radiusRad)`
Creator.
`Cone(double x, double y, double z, double radiusRad)`
Creator.
`Cone(CooXYZ center, double radiusRad)`
Creator.

## Method Summary

Modifier and Type
Method
Description
`boolean`
`contains(CooXYZ coo)`
Returns `true` if the given point is inside the cone.
`double`
`radiusRad()`
Returns the angle of the cone (the distance between its center and the its edge), in radians.
`String`
`toString()`

### Methods inherited from class cds.healpix.common.sphgeom.CooXYZ

`arcCenter, arcCenter, boundingCone, circumCenter, circumCenter, circumRadiusSphe, circumRadiusSphe, crossProd, euclDist, havDist, lat, lon, mec, mec, mec, normalizedSum, scalarProd, scalarProd, spheDist, toEquaCooXYZ, x, y, z`

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Constructor Details

### Cone

public Cone(CooXYZ center, double radiusRad)
Creator.

Parameters:
  `center` - cetner of the cone
  `radiusRad` - radius of the cone, in radians

### Cone

public Cone(double lonRad, double latRad, double radiusRad)
Creator.

Parameters:
  `lonRad` - longitude of the center of the cone, in radians
  `latRad` - latitude of the center of the cone, in radians
  `radiusRad` - radius of the cone, in radians

### Cone

public Cone(double x, double y, double z, double radiusRad)
Creator.

Parameters:
  `x` - first Cartesian coordinate of the center of the cone
  `y` - second Cartesian coordinate of the center of the cone
  `z` - third Cartesian coordinate of the center of the cone
  `radiusRad` - radius of the cone, in radians

## Method Details

### radiusRad

public double radiusRad()
Returns the angle of the cone (the distance between its center and the its edge), in radians.

Returns:
  the angle of the cone (the distance between its center and the its edge), in radians.

### contains

public boolean contains(CooXYZ coo)
Returns `true` if the given point is inside the cone.

Parameters:
  `coo` - position to be tested
Returns:
  `true` if the given point is inside the cone.

### toString

public String toString()

Overrides:
  `toString` in class `CooXYZ`