correct critical bug (phi's and theta's were swapped)