I believe this is one of the initial steps an aircraft INS uses to find north while it is aligning, but it's been too long since I had aircraft systems theory in the front of my brain.
There were various workarounds you had to use in the Navy, where the ship has not only usually moved from the last place the jet thought it was, but it's generally moving as the jet tries to re-align itself. GPS made things easier, and there wasn't a whole lot of thinking involved, but it always took the jet a bit more (or a lot more depending on model) thinking to get a stable platform underway.