810
810
/* this basically works by using the cosine rule in conjunction */
811
811
/* with a few geometric constraints (eg normalized vectors) */
813
820
/* compute the translation vector for b */
816
823
b3 = 0.0; /* constrain a,b to remain on the x,y plane */
818
831
/* compute the translation vector for c */
820
833
c2 = (2.0*cos(data->pbc[3]) + b1*b1 + b2*b2 - 2.0*b1*c1 - 1.0)/(2.0*b2);