private Vector3d getReferenceAxisCylicWithSubunitAlignment ( ) { if ( rotationGroup . getPointGroup ( ) . equals ( "C2" ) ) { return referenceVector ; } // find subunit that extends the most in the xy-plane List < List < Integer > > orbits = getOrbitsByXYWidth ( ) ; // get the last orbit which is the widest List < Integer > widestOrbit = orbits . get ( orbits . size ( ) - 1 ) ; List < Point3d > centers = subunits . getCenters ( ) ; int subunit = widestOrbit . get ( 0 ) ; // calculate reference vector Vector3d refAxis = new Vector3d ( ) ; refAxis . sub ( centers . get ( subunit ) , subunits . getCentroid ( ) ) ; refAxis . normalize ( ) ; return refAxis ; }
Returns a reference vector for the alignment of Cn structures .