Package schrodinger :: Package application :: Package matsci :: Module shapes :: Class Cylinder
[hide private]
[frames] | no frames]

Class Cylinder

object --+
         |
        Cylinder

Class to manage a cylinder.

Instance Methods [hide private]
 
__init__(self, radius, length, center=[0.0, 0.0, 0.0])
Create an instance.
float
getVolume(self, radius, length)
Return the volume.
float
getSurfaceArea(self, radius, length)
Return the surface area.
bool
pointInside(self, point)
Return True if the query point is either on or inside of this cylinder.

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  NAME = 'cylinder'
  DEFAULT = [5.0, 25.0]
  DESCRIPTION = ['radius', 'length']
  TYPE = 'basic'
  NUM_UNIQUE_EDGES = 0
hash(x)
  NUM_UNIQUE_FACES = 1
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, radius, length, center=[0.0, 0.0, 0.0])
(Constructor)

 

Create an instance.

Parameters:
  • radius (float) - the radius of the cylinder
  • length (float) - the length of the cylinder
  • center (numpy.array) - the center of the cylinder
Overrides: object.__init__

getVolume(self, radius, length)

 

Return the volume.

Parameters:
  • radius (float) - radius in Angstrom
  • length (float) - length in Angstrom
Returns: float
volume in cubic Angstrom

getSurfaceArea(self, radius, length)

 

Return the surface area.

Parameters:
  • radius (float) - radius in Angstrom
  • length (float) - length in Angstrom
Returns: float
surface area in square Angstrom

pointInside(self, point)

 

Return True if the query point is either on or inside of this cylinder.

Parameters:
  • point (numpy.array) - the point in question
Returns: bool
True if the point in question is either on or inside this cylinder, False otherwise