To fit a polynomial through a set of eclipse element values sampled at discrete times, we use a bit of simple linear algebra. We construct a Vandermonde matrix based on the chosen time values (relative to a central reference time \(t_0\)). Each row of the matrix corresponds to a different time sample, and each column corresponds to a power of that time (0th, 1st, 2nd, etc.).
Suppose we have \(n\) sample times \(t_1, t_2, ..., t_n\) having corresponding element values \(y_1, y_2, ..., y_n\) obtained from the ephemerides. The Vandermonde matrix \(\mathbf{V}\) looks like this:
$$ \mathbf{V} = \begin{bmatrix} 1 & t_1 & t_1^2 & \cdots & t_1^{n-1} \\ 1 & t_2 & t_2^2 & \cdots & t_2^{n-1} \\ \vdots & \vdots & \vdots & \ddots & \vdots \\ 1 & t_n & t_n^2 & \cdots & t_n^{n-1} \end{bmatrix} $$
We wish to find the polynomial coefficients \(\vec{c}\) such that:
$$ \mathbf{V} \cdot \vec{c} = \vec{y} $$
To solve this, we premultiply both sides of the equation by the inverse of \(\mathbf{V}\):
$$ \vec{c} = \mathbf{V}^{-1} \cdot \vec{y} $$
We also choose to use 13 values for each of the elements, extracted from the ephemerides, and evenly spaced every 30 min, centered on \(t_0\). In other words, in our world \(n = 13\) and \( t_i - t_{i-1} = 0.5 \) for \( i = 2 \text{ to } n \).
(Note that calculating the inverse of a 13x13 matrix is more than a bit challenging. But never fear - we give it all to you below!)
This multiplication gives us the coefficients of our polynomial reduction: constant term, linear term, quadratic term, and so on. Each of these corresponds to a time derivative of that element evaluated at \(t_0\), and scaled appropriately. In practice, we will use only the first few derivative values to fill out our table of Besselian elements.
The Vandermonde matrix method works well when the sample times are well-spaced and the number of samples is moderate. If the times are too closely packed or too numerous, the matrix can become ill-conditioned. But for eclipse modeling, where we use a (somewhat) reasonable number of evenly-spaced times, it is an ideal method that gives a clean, interpretable polynomial fit for each Besselian element.
NOTE: Use these ONLY if you have 13 values of each element calculated at times centered on \(t_0\) using a time step of 30 min! (If you have something else going on, you'll have to figure out your own matrices. And yes, we know you won't actually use \(\mathbf{V}\), but here it is anyway — for completeness.)
Here are the matrices \(\mathbf{V}\) and \(\mathbf{V}^{-1}\), which assume 13 values of \(t\) evenly spaced at 30-min intervals surrounding \(t_0\):
⎡ 1 -3 9 -27 81 -243 729 -2187 6561 -19683 59049 -177147 531441 ⎤ ⎢ 1 -2.5 6.25 -15.625 39.0625 -97.65625 244.140625 -610.351562 1525.878906 -3814.697266 9536.743164 -23841.85791 59604.64478 ⎥ ⎢ 1 -2 4 -8 16 -32 64 -128 256 -512 1024 -2048 4096 ⎥ ⎢ 1 -1.5 2.25 -3.375 5.0625 -7.59375 11.390625 -17.085938 25.628906 -38.443359 57.665039 -86.497559 129.746338 ⎥ ⎢ 1 -1 1 -1 1 -1 1 -1 1 -1 1 -1 1 ⎥ ⎢ 1 -0.5 0.25 -0.125 0.0625 -0.03125 0.015625 -0.007812 0.003906 -0.001953 0.000977 -0.000488 0.000244 ⎥ ⎢ 1 0 0 0 0 0 0 0 0 0 0 0 0 ⎥ ⎢ 1 0.5 0.25 0.125 0.0625 0.03125 0.015625 0.007812 0.003906 0.001953 0.000977 0.000488 0.000244 ⎥ ⎢ 1 1 1 1 1 1 1 1 1 1 1 1 1 ⎥ ⎢ 1 1.5 2.25 3.375 5.0625 7.59375 11.390625 17.085938 25.628906 38.443359 57.665039 86.497559 129.746338 ⎥ ⎢ 1 2 4 8 16 32 64 128 256 512 1024 2048 4096 ⎥ ⎢ 1 2.5 6.25 15.625 39.0625 97.65625 244.140625 610.351562 1525.878906 3814.697266 9536.743164 23841.85791 59604.64478 ⎥ ⎣ 1 3 9 27 81 243 729 2187 6561 19683 59049 177147 531441 ⎦
⎡ 0 0 0 0 0 0 1 0 0 0 0 0 0 ⎤ ⎢ 0.000361 -0.005195 0.035714 -0.15873 0.535714 -1.71429 9.691030e-14 1.71429 -0.535714 0.15873 -0.035714 0.005195 -0.000361 ⎥ ⎢ -0.00012 0.002078 -0.017857 0.10582 -0.535714 3.42857 -5.96556 3.42857 -0.535714 0.10582 -0.017857 0.002078 -0.00012 ⎥ ⎢ -0.002112 0.030159 -0.204127 0.876367 -2.66012 3.36952 3.817480e-13 -3.36952 2.66012 -0.876367 0.204127 -0.030159 0.002112 ⎥ ⎢ 0.000704 -0.012063 0.102063 -0.584245 2.66012 -6.73905 9.14494 -6.73905 2.66012 -0.584245 0.102063 -0.012063 0.000704 ⎥ ⎢ 0.003064 -0.042681 0.275573 -1.06208 2.23896 -2.19894 -1.668680e-13 2.19894 -2.23896 1.06208 -0.275573 0.042681 -0.003064 ⎥ ⎢ -0.001021 0.017072 -0.137787 0.708054 -2.23896 4.39788 -5.49049 4.39788 -2.23896 0.708054 -0.137787 0.017072 -0.001021 ⎥ ⎢ -0.00164 0.021693 -0.127196 0.399471 -0.702381 0.616508 4.819160e-14 -0.616508 0.702381 -0.399471 0.127196 -0.021693 0.00164 ⎥ ⎢ 0.000547 -0.008677 0.063598 -0.266314 0.702381 -1.23302 1.48296 -1.23302 0.702381 -0.266314 0.063598 -0.008677 0.000547 ⎥ ⎢ 0.000353 -0.004233 0.021164 -0.057848 0.092064 -0.07619 -6.181300e-15 0.07619 -0.092064 0.057848 -0.021164 0.004233 -0.000353 ⎥ ⎢ -0.000118 0.001693 -0.010582 0.038566 -0.092064 0.152381 -0.179753 0.152381 -0.092064 0.038566 -0.010582 0.001693 -0.000118 ⎥ ⎢ -2.565340e-05 0.000257 -0.001129 0.002822 -0.004233 0.003386 2.997280e-16 -0.003386 0.004233 -0.002822 0.001129 -0.000257 2.565340e-05 ⎥ ⎣ 8.551120e-06 -0.000103 0.000564 -0.001881 0.004233 -0.006772 0.007901 -0.006772 0.004233 -0.001881 0.000564 -0.000103 8.551120e-06 ⎦