I’ve been using microprocessors since I was in college in the late 70’s. One of the (many) things that make me smile is the present need to have Ghz processors to do trigonometry things.
This link (https://hackaday.com/2020/05/20/looking-for-pi-in-the-8087-math-coprocessor-chip/) talks about the 8087 math co-processor, which for the times was pretty amazing. One of the secrets was the CORDIC design. (https://en.wikipedia.org/wiki/CORDIC)
Some hairy math stuff at the front, but some very simple code at the bottom so scroll down.
This is an example of “work smarter not harder”. Back in my mainframe days when mainframes that supported 100 people had less power than your cell phone, things like this made some serious science still possible.
It’s well worth a look on how some lookup tables and some math can work to your advantage.