convertVectorFromBaseToPupil

lsst.cbp.coordUtils.convertVectorFromBaseToPupil(vectorBase, pupilAzAlt)

Given a vector in base coordinates and the pupil pointing, compute the vector in pupil coordinates.

Parameters:
vectorBasesequence of 3 float

3-dimensional vector in the base frame.

pupilAzAltlsst.geom.SpherePoint

Pointing of the pupil frame as internal azimuth, altitude.

Returns:
vectorPupilnp.array of 3 float

3-dimensional vector in the pupil frame.

Notes

This could be implemented as the following Euler angle rotation matrix, which is: - first rotate about the z axis by azimuth - then rotate about the rotated -y axis by altitude - there is no third rotation

c1*c2 -s1 -c1*s2 c2*s1 c1 s1s2 s1 0 c2

where angle 1 = azimuth, angle 2 = altitude, sx = sine(angle x) and cx = cosine(angle x).

Knowing this matrix is helpful, e.g. for math inside computeAzAltFromBasePupil.