General Algorithms and Numerical Computing
Angle, error, data processing, interpolation and root finding are general tools for calculating astronomical problems.
First understand the angle and accuracy, and then enter interpolation, fitting and iteration.
Let’s look at the phenomena in life first →
- After turning around in a full circle, why are you still facing the same house?
Use turning to find the direction, and distinguish "how much you turned" and "where you ended up heading."
- The calculator calculated 32°, why is the target in the opposite direction?
Two opposite directions can have the same slope. By leaving only a ratio, you're throwing away the symbols you really need.
- The two weighings are almost the same. Can we tell how much is missing by subtracting them?
First write down the two readings and then see how rounding changes that small difference.
- Does the error in the ephemeris come from the input, the formula, or the machine?
The same result has to go through four levels: input, algorithm, internal operation, and final display. Don't confuse them into one "accuracy".
- How to arrange a stack of disordered observation records in a correct and trouble-free manner?
First compare which record is earlier, then move the entire record and see with your own eyes how the data is arranged.
- The table only records once a day. Where does the number at that time of night come from?
Use several records before and after to fill in nearby moments that are not directly listed.
- The ephemeris only records a few times, so how to find the "most recent" and "just past zero" moments?
In addition to filling in an intermediate value, interpolation can also find local minima or zero crossings; provided that the data is really nearby.
- If the recording time is not neat, can I still fill in the data in between?
There is no need to forcibly move the record to the hour, so that every real input position can be included in the calculation.
- Readings are high and low. How to find the trend behind it?
Put the scattered observation records together and find a line that is closest to them as a whole.
- How to turn a long garden into a square step by step?
Keep the area unchanged, adjust the two sides, and see with your own eyes that "the more you guess, the more accurate you will be."
- Why do you sometimes get more and more outrageous after repeatedly "improving your answers"?
Not all repeated calculations will come close to the answer; for the same question, the rewriting method and starting point will all affect the result.