Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

EMAN::IcosahedralSym Class Reference

An encapsulation of icosahedral symmetry Doctor Phil has this to say about icosahedral symmetry: "Each Platonic Solid has 2E symmetry elements. More...

#include <symmetry.h>

Inheritance diagram for EMAN::IcosahedralSym:

Inheritance graph
[legend]
Collaboration diagram for EMAN::IcosahedralSym:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 IcosahedralSym ()
 Constructor calls PlatonicSym::init.
virtual ~IcosahedralSym ()
virtual string get_name () const
 Return IcosahedralSym::NAME.
virtual string get_desc () const
 Get a description.
virtual int get_max_csym () const
 Gets the maximum symmetry of this object.
virtual Transform get_sym (const int n) const
 This function provides access to the unique rotational symmetries of an icosahedron.
virtual int get_nsym () const
 Gets the total number of unique rotational symmetry operations associated with this symmetry For icosahedral symmetry, this is 60.
virtual float get_az_alignment_offset () const
 Get the azimuth alignment offset required to ensure that orientations align correctly with symmetric axes of the icosahedron.

Static Public Member Functions

Symmetry3DNEW ()
 Factory support function NEW.

Static Public Attributes

const string NAME = "icos"
 The name of this class - used to access it from factories etc. Should be "icos".

Private Member Functions

 IcosahedralSym (const IcosahedralSym &)
 Disallow copy construction.
IcosahedralSymoperator= (const IcosahedralSym &)
 Disallow assignment.

Detailed Description

An encapsulation of icosahedral symmetry Doctor Phil has this to say about icosahedral symmetry: "Each Platonic Solid has 2E symmetry elements.

An icosahedron has m=5, n=3, F=20 E=30=nF/2, V=12=nF/m,since vertices shared by 5 triangles It is composed of 20 triangles. E=3*20/2 A dodecahedron has m=3, n=5 F=12 E=30 V=20 It is composed of 12 pentagons. E=5*12/2; V= 5*12/3, since vertices shared by 3 pentagons"

Author:
David Woolford (based on previous work by Phil Baldwin and Steve Ludtke)
Date:
Feb 2008

Definition at line 855 of file symmetry.h.


Constructor & Destructor Documentation

EMAN::IcosahedralSym::IcosahedralSym  )  [inline]
 

Constructor calls PlatonicSym::init.

Definition at line 860 of file symmetry.h.

00860 {init(); }

virtual EMAN::IcosahedralSym::~IcosahedralSym  )  [inline, virtual]
 

Definition at line 861 of file symmetry.h.

00861 { }

EMAN::IcosahedralSym::IcosahedralSym const IcosahedralSym  )  [private]
 

Disallow copy construction.


Member Function Documentation

float IcosahedralSym::get_az_alignment_offset  )  const [virtual]
 

Get the azimuth alignment offset required to ensure that orientations align correctly with symmetric axes of the icosahedron.

This offset is directly related to the way the symmetric operations are generated by get_sym. All orientations generated as a result of using the delimiters supplied by this class should by offset by this azimuth to ensure proper alignment with tetrahedral objects in EMAN2

Reimplemented from EMAN::Symmetry3D.

Definition at line 1783 of file symmetry.cpp.

Referenced by get_sym().

01783 { return 234.0; } // This offset positions a 3 fold axis on the positive x axis

virtual string EMAN::IcosahedralSym::get_desc  )  const [inline, virtual]
 

Get a description.

Returns:
a clear desciption of this class

Implements EMAN::FactoryBase.

Definition at line 879 of file symmetry.h.

00879 { return "Icosahedral symmetry support"; }

virtual int EMAN::IcosahedralSym::get_max_csym  )  const [inline, virtual]
 

Gets the maximum symmetry of this object.

This is used by OrientationGenerators, and is probably not something a general user would utilize.

Returns:
for icosahedral symmetry, this number is 5

Implements EMAN::Symmetry3D.

Definition at line 885 of file symmetry.h.

00885 { return 5; }// 5 is the greatest symmetry

virtual string EMAN::IcosahedralSym::get_name  )  const [inline, virtual]
 

Return IcosahedralSym::NAME.

Returns:
the unique name of this class

Implements EMAN::FactoryBase.

Definition at line 874 of file symmetry.h.

00874 { return NAME; };

virtual int EMAN::IcosahedralSym::get_nsym  )  const [inline, virtual]
 

Gets the total number of unique rotational symmetry operations associated with this symmetry For icosahedral symmetry, this is 60.

Returns:
60

Implements EMAN::Symmetry3D.

Definition at line 899 of file symmetry.h.

00899 { return 60; };

Transform IcosahedralSym::get_sym const int  n  )  const [virtual]
 

This function provides access to the unique rotational symmetries of an icosahedron.

We have placed the icosahedral symmetry group with a face along the z-axis. In all, there are 60 (accessed by get_nysm) unique rotational symmetric operations for the icosahedron.

Parameters:
n the symmetric operation number.
Returns:
a transform containing the correct rotational symmetry operation.

Implements EMAN::Symmetry3D.

Definition at line 1785 of file symmetry.cpp.

References get_az_alignment_offset().

01786 {
01787         // These rotations courtesy of Phil Baldwin
01788         static double  lvl0=0.; //  there is one pentagon on top; five-fold along z
01789         static double  lvl1= 63.4349; // that is atan(2)  // there are 5 pentagons with centers at this height (angle)
01790         static double  lvl2=116.5651; //that is 180-lvl1  // there are 5 pentagons with centers at this height (angle)
01791         static double lvl3=180.0;
01792 
01793         static double ICOS[180] = { // This is with a pentagon normal to z
01794                 0,lvl0,0,    0,lvl0,288,   0,lvl0,216,   0,lvl0,144,  0,lvl0,72,
01795   0,lvl1,36,   0,lvl1,324,   0,lvl1,252,   0,lvl1,180,  0,lvl1,108,
01796   72,lvl1,36,  72,lvl1,324,  72,lvl1,252,  72,lvl1,180,  72,lvl1,108,
01797   144,lvl1,36, 144,lvl1,324, 144,lvl1,252, 144,lvl1,180, 144,lvl1,108,
01798   216,lvl1,36, 216,lvl1,324, 216,lvl1,252, 216,lvl1,180, 216,lvl1,108,
01799   288,lvl1,36, 288,lvl1,324, 288,lvl1,252, 288,lvl1,180, 288,lvl1,108,
01800   36,lvl2,0,   36,lvl2,288,  36,lvl2,216,  36,lvl2,144,  36,lvl2,72,
01801   108,lvl2,0,  108,lvl2,288, 108,lvl2,216, 108,lvl2,144, 108,lvl2,72,
01802   180,lvl2,0,  180,lvl2,288, 180,lvl2,216, 180,lvl2,144, 180,lvl2,72,
01803   252,lvl2,0,  252,lvl2,288, 252,lvl2,216, 252,lvl2,144, 252,lvl2,72,
01804   324,lvl2,0,  324,lvl2,288, 324,lvl2,216, 324,lvl2,144, 324,lvl2,72,
01805   0,lvl3,0,    0,lvl3,288,   0,lvl3,216,   0,lvl3,144,   0,lvl3,72
01806         };
01807 
01808         int idx = n % 60;
01809         Dict d("type","eman");
01810 //      Transform3D ret;
01811         if (get_az_alignment_offset() == 234.0) {
01812                 d["az"] =(float)ICOS[idx * 3 ]+90;
01813                 d["alt"] = (float)ICOS[idx * 3 + 1];
01814                 d["phi"] = (float)ICOS[idx * 3 + 2]-90;
01815 //              ret.set_rotation((float)ICOS[idx * 3 ]+90,(float)ICOS[idx * 3 + 1], (float)ICOS[idx * 3 + 2]-90);
01816         }
01817         else {
01818                 d["az"] =(float)(float)ICOS[idx * 3 ];
01819                 d["alt"] = (float)ICOS[idx * 3 + 1];
01820                 d["phi"] = (float)ICOS[idx * 3 + 2];
01821 //              ret.set_rotation((float)ICOS[idx * 3 ],(float)ICOS[idx * 3 + 1], (float)ICOS[idx * 3 + 2]);
01822         }
01823 
01824 //      ret.set_rotation((float)ICOS[idx * 3 ],(float)ICOS[idx * 3 + 1], (float)ICOS[idx * 3 + 2]);
01825 //      if ( get_az_alignment_offset() != 0 ) {
01826 //              Transform3D t(get_az_alignment_offset(),0,0);
01827 //              ret = t*ret;
01828 //      }
01829         return Transform(d);
01830 
01831 }

Symmetry3D* EMAN::IcosahedralSym::NEW  )  [inline, static]
 

Factory support function NEW.

Returns:
a newly instantiated class of this type

Definition at line 866 of file symmetry.h.

00867                 {
00868                         return new IcosahedralSym();
00869                 }

IcosahedralSym& EMAN::IcosahedralSym::operator= const IcosahedralSym  )  [private]
 

Disallow assignment.


Member Data Documentation

const string IcosahedralSym::NAME = "icos" [static]
 

The name of this class - used to access it from factories etc. Should be "icos".

Definition at line 45 of file symmetry.cpp.


The documentation for this class was generated from the following files:
Generated on Tue Jun 11 13:43:10 2013 for EMAN2 by  doxygen 1.3.9.1