## 2 Heliostat Orientation
### Target-Aligned (TA) Orientation  
To obtain the mirror center and orientation, the following procedure can be applied, assuming that the heliostat initially points to the target and the local mechanical model is either azimuth-elevation or tilt-roll (see Figure 4). In the first case, the origin is at the secondary axis, b (in green), while in the second case, the origin is at the primary axis, a (in purple).  
1. Build the target referential as follows: \[\overset{\rightarrow}{\widetilde{\text{z}}}=\frac{\overset{\rightarrow}{t}}{ \left|\overset{\rightarrow}{t}\right|}\implies\overset{\rightarrow}{ \widetilde{\text{x}}}=(\text{z}_{2},-\text{z}_{1},0)\implies\overset{ \rightarrow}{\widetilde{\text{y}}}=\overset{\rightarrow}{\widetilde{\text{ z}}}\times\overset{\rightarrow}{\widetilde{\text{x}}}\] (6)
2. Convert the sun vector to the target referential as follows (target and center vectors are along the z axis): \[\overset{\rightarrow}{\widetilde{s}}=\frac{\overset{\rightarrow}{S}}{ \left|\overset{\rightarrow}{\widetilde{s}}\right|}\implies\left(\overset{ \rightarrow}{\widetilde{s}}\cdot\overset{\rightarrow}{\widetilde{\text{x}}},\overset{\rightarrow}{\widetilde{s}}\cdot\overset{\rightarrow}{\widetilde{ \text{y}}},\overset{\rightarrow}{\widetilde{\text{y}}}\cdot\overset{ \rightarrow}{\widetilde{\text{z}}}\right)\] (7)  
Figure 3: Model to orient a tilt-roll heliostat, showing fixed quantities (vector target \(\overset{\rightarrow}{t}\), vector sum \(\overset{\rightarrow}{s}\), offsets o1, o2) and variable quantities (vector \(\overset{\rightarrow}{c}\), angles \(\alpha\), \(\beta\) around axes a, b). Axes x, y, and z point east, north, and toward the sky, respectively.  
3. Apply steps 1, 2, and 3 of the azimuth-elevation model or steps 1, 2, and 3 of the tilt-roll model until convergence is reached for the \(\alpha\) and \(\beta\) angles. This can be accomplished because the new target-aligned xyz z referential works exactly like the Earth sky-aligned xyz referential: first, rotate the secondary x-axis to fix the altitude, and then rotate the primary z-axis to fix the azimuth (the new elevation-azimuth model, referred to here as TA/AE); or first, rotate the secondary y-axis to fix azimuth, and then rotate the primary x-axis to fix altitude (the new tilt-roll model, referred to here as TA/TR).
4. Convert the normal and center vectors back to the Earth referential as follows: \[\overset{\rightarrow}{n}=n_{x}\overset{\rightarrow}{\times}+n_{y}\overset{ \rightarrow}{\text{y}}+n_{z}\overset{\rightarrow}{\text{z}}\] (8) \[\overset{\rightarrow}{c}=c_{x}\overset{\rightarrow}{\times}+c_{y}\overset{ \rightarrow}{\text{y}}+c_{z}\overset{\rightarrow}{\text{z}}\] (9)  
There is a key difference between AE, TR heliostats (initially pointing to the sky) and TA/TE, TA/TR heliostats (initially pointing to the target) that should be noted. In the AE and TR models, the angle controlling altitude (\(\beta\) in AE, \(\alpha\) in TR) is always positive. In the TA/AE and TA/TR models, this altitude angle can be positive or negative, depending on whether the sun is above or below the target, as seen from the heliostat. A negative \(\beta\) angle in the TA/AE model is handled by adding a 180\({}^{\circ}\) rotation to the \(\alpha\) angle, as the mechanical system always assumes a positive \(\beta\) rotation. In the TA/TR model, there is no such solution, so the mechanical system must be able to handle a negative \(\alpha\) rotation. In the TA/AE model, the allowed angular range is [\(-\)180\({}^{\circ}\), 180\({}^{\circ}\)] for \(\alpha\) and [0, 90\({}^{\circ}\)] for \(\beta\). In the TA/TR model, the allowed angular range is [\(-\)90\({}^{\circ}\), 90\({}^{\circ}\)] for \(\alpha\) and [\(-\)90\({}^{\circ}\), 90\({}^{\circ}\)] for \(\beta\).