Author: bugman Date: Thu Jun 25 15:58:39 2009 New Revision: 9154 URL: http://svn.gna.org/viewcvs/relax?rev=9154&view=rev Log: Bug fixes for the generate_vector_dist() function. The protons were not being correctly stitched together! Modified: branches/frame_order/generic_fns/structure/geometric.py Modified: branches/frame_order/generic_fns/structure/geometric.py URL: http://svn.gna.org/viewcvs/relax/branches/frame_order/generic_fns/structure/geometric.py?rev=9154&r1=9153&r2=9154&view=diff ============================================================================== --- branches/frame_order/generic_fns/structure/geometric.py (original) +++ branches/frame_order/generic_fns/structure/geometric.py Thu Jun 25 15:58:39 2009 @@ -504,6 +504,9 @@ if phi[j_min] < max_angle: break + # The number of j increments. + num_j = inc/2+2 - j_min + # Loop over the radial array of vectors (change in longitude). for i in range(inc): # Loop over the vectors of the radial array (change in latitude). @@ -536,11 +539,11 @@ # Connect across the radial arrays (to generate the latitudinal lines). if i != 0: - mol.atom_connect(index1=atom_num-1, index2=atom_num-1-j_min-2) + mol.atom_connect(index1=atom_num-1, index2=atom_num-1-num_j) # Connect the last radial array to the first (to zip up the geometric object and close the latitudinal lines). if i == inc-1: - mol.atom_connect(index1=atom_num-1, index2=origin_num-1+j+2) + mol.atom_connect(index1=atom_num-1, index2=origin_num-1+(j-j_min)) # Increment the atom number. atom_num = atom_num + 1