public double getMaxDimension ( ) { if ( maxDimension != 0 ) { return maxDimension ; } Point3d vert0 = new Point3d ( 0 , 0 , 0 ) ; Point3d vert1 = new Point3d ( 1 , 0 , 0 ) ; transfToOrthonormal ( vert1 ) ; Point3d vert2 = new Point3d ( 0 , 1 , 0 ) ; transfToOrthonormal ( vert2 ) ; Point3d vert3 = new Point3d ( 0 , 0 , 1 ) ; transfToOrthonormal ( vert3 ) ; Point3d vert4 = new Point3d ( 1 , 1 , 0 ) ; transfToOrthonormal ( vert4 ) ; Point3d vert5 = new Point3d ( 1 , 0 , 1 ) ; transfToOrthonormal ( vert5 ) ; Point3d vert6 = new Point3d ( 0 , 1 , 1 ) ; transfToOrthonormal ( vert6 ) ; Point3d vert7 = new Point3d ( 1 , 1 , 1 ) ; transfToOrthonormal ( vert7 ) ; ArrayList < Double > vertDists = new ArrayList < Double > ( ) ; vertDists . add ( vert0 . distance ( vert7 ) ) ; vertDists . add ( vert3 . distance ( vert4 ) ) ; vertDists . add ( vert1 . distance ( vert6 ) ) ; vertDists . add ( vert2 . distance ( vert5 ) ) ; maxDimension = Collections . max ( vertDists ) ; return maxDimension ; }
Gets the maximum dimension of the unit cell .