-
-
Notifications
You must be signed in to change notification settings - Fork 217
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ITRS Hour angle and declination #510
Comments
Am I correct that hour angle is simply right ascension relative to LST? I would almost be tempted to say “a single subtraction is a simple enough operation that it might not be worth a separate method” — except that my own attempt to perform the simple subtraction is not getting close agreement with HORIZONS. Any idea where my script needs to be tweaked?
The output:
Here’s the HORIZONS output:
|
I found these references in my travels a while back, might help:
The magic formula being |
Hmm, However, I'm not asking for apparent hour angle and declination here. I'm asking for ITRS hour angle and declination as derived from azimuth and elevation using geodetic latitude. This is the hour angle and declination for an equatorial mount aligned with the ITRS pole rather than the CIP. In a non-airless model, it also includes refraction. |
@Bernmeister That is correct, however there is a slight rotation of the pole involved here due to polar motion. This is the difference between TIRS and ITRS hour angle. |
Yes. I'm seeing something similar on my side also. For my moon data, the difference in apparent right ascension between my data and that of Horizons is 51.27 mas, while the difference in LST is 110.66 mas. This yields a difference in apparent hour angle of 59.39 mas. Since LST is derived from UT1, I expect that this due to a slight difference in DUT1 between my data and that of Horizons. |
In that case, am I correct that the angle you are asking for is not the angle that HORIZONS is determining? Your hour angle would be a rotation around the ITRS pole. Their hour angle, by contrast, seems to be a rotation around the “Earth's axis of-date” by which I think they would mean the rotational axis — from their HA definition above:
Their HA is the angle between two planes, both of which have in common the “Earth's axis of-date”, which I think means their HA can be computed as the difference between two right ascensions in the equinox-and-equator-of-date? Your emphasizing “geodetic latitude” certainly points out a flaw in my first attempt above: I asked “where is Boston relative to the geocenter?” instead of “where does Boston’s zenith point?” which would not make a difference if polar motion was zero — since longitude, the operative quantity here, ignores Earth flattening and the difference between geodetic and geocentric coordinates — but does indeed matter in the case of polar motion, which knocks the ITRS slightly askew of the equator-and-equinox-of-date and mixes a little bit of longitude into latitude and vice versa in the rotation to the frame of reference of Earth’s rotation. Alas, though, when I try factoring that into my script, moving my focus from Boston to its zenith, I get farther from the HORIZONS number rather than closer!
Output:
Instead of matching HORIZONS, let's instead focus on whether my computations can match yours. Can you share the exact hour angle you're getting for these circumstances, and maybe suggest where my calculation could be adjusted to match yours? |
OK. Here's my data from my usual run of the Moon on April 6th, 2017. Rather than azimuth and elevation, I am printing ITRS hour angle and declination (HAO, DECO) here for an airless model. moon_topo_4_6_2017_mkb_sf_v5_hadec.csv.txt If we take a Cartesian vector in az/el coordinates such that the X axis points South, the Y axis points West and the Z axis points up, then the difference between an Alt/Az mount and an equatorial mount is a counter-clockwise rotation by 90 - latitude around the Y axis such that the Z axis points to the ITRS pole. Please note that in a non-airless model, this rotation must be done after atmospheric refraction has been applied. |
There will be a slight difference between your data and mine as I am neglecting the deflection of light in the Earth's gravitational field. |
Thanks for the data file! Unless someone else wants to jump in and try replicating the numbers using Skyfield code, I should have some time the week after Christmas to take a look. (And: happy holidays, everyone!) |
OK. This works for me using Skyfield version 1.34. skyfield_topo_hadec_test.py.txt While doing this, I noticed that I had forgotten that this is a left handed coordinate system. I amended my previous post accordingly. |
I also notice that your DUT1 doesn't quite agree with |
Merry Christmas, and happy holidays everyone! |
@brandon-rhodes It's been nearly a month now. I don't want to push. I realize that you've been busy, just wondering if this somehow fell off your radar. |
Thanks for checking in! It's still on my radar. The holidays have been busy, and also one or two bugs appeared that needed attention before a new feature (or at least that's how I tend to prioritize). |
And sometimes I add features that help me answer questions that I myself have. I just landed new code that when the user runs
That will prevent me from having to double-check those numbers manually. |
If only GitHub had a way to attach a to-do list to an Issue. (Besides editing the original issue description to include it, which I avoid if I didn’t write the issue myself.) But here are TODO items from this issue at this point in time: [Edit: switched from a numbered list to bullets, to not falsely imply that these have a necessary order; in particular, the first item will probably be the last tackled.]
|
|
Oh, and here's the JPL Horizons data if you want to try this out yourself. |
I can vary the implementation later (for now I directly use the known longitude of the observer), but
If the numbers look good, we can close this issue, and I can separately track the possible additional to-do items mentioned above. Oh, and, to respond to the comments about them:
|
I've been hesitant to try installing from the development branch because I'm unsure what that will do. Will it write over my current installation of Skyfield without changing the version number? Or will it install a separate version alongside my currently installed version? A couple of comments on your implementation:
|
Yes, that's what it would do. It removes and replaces the current install but the version number will be the current one from PyPI, as I don't increment it til it's time to release (lest I accidentally release early). If you're wary I can close the issue on the strength of the passing test, then you can re-open if you see problems after the next version comes out.
The raw position vector is topocentric GCRS. The geographic longitude is an ITRS angle, and thus is over on the other side of the transform that includes the TIO locator. So when I apply the ITRS transform to the topocentric GCRS, which includes the TIO locator, aren’t I generating an angle that’s directly comparable to the geographic longitude? Your suggestion sounds like it would apply the TIO locator twice, but maybe I don't see where exactly it would go in the code.
Understood: at the moment my target is the Hour Angle described in the Supplement, which accounts for polar motion but not for atmosphere. The code will indeed have to become more complicated, as shown in your script, if in the future we go beyond the almanac concept of HA. |
Sorry to be long in responding. I saw my error immediately, but I got tangled up in signs until I realized that you use alibi transformations in your rotations so that your wobble matrix subtracts the TIO locator from the sublongtiude rather than adding it. So, yes, you're fine there as is. |
No problem! It’s the weekend; and, as you are my only correspondent who regularly checks my work at this level of precision, your comments are valuable whether they take a day or a week. I'm going to close this issue out pending a release soon, and it can be re-opened if the new HA routine winds up breaking for someone. Thanks for the input, everyone! |
I tried installing the development branch using your instructions, but it didn't work. After downloading 93.6 MB, I got:
and it did nothing. |
You should probably document the fact that your ITRS hour angle and declination don't include refraction. |
I'll adjust the install-from-a-GitHub-zip template I use to add And, yes, I guess the zip includes all the files in the repository, even the ones that aren't needed for the install. I'll think about whether there's a way around that.
Done. |
To complement
altaz
, it would be good if Skyfield could also provide hour angle and declination (hadec
) for an equatorially mounted telescope. This is the ITRS hour angle and declination taking into account both polar motion and atmospheric refraction.The text was updated successfully, but these errors were encountered: