I realise this is more of a general programming question to a certain extent but it's related to the specifics of the processor and peculiarities of the Axoloti number range. I hope someone will humour me but please delete this if it's considered to be off topic.
I'm trying to make a "no gain" version of dist/soft for use in things like feedback loops. Using a graphing calculator I've worked out that what I need is x-(x^3)/3, what I'm actually wondering is if anyone knows a shortcut to working out the /3 bit.
As I understand it, division is quite expensive, so avoiding directly dividing would be beneficial. One idea I had was to use init to store a number in a variable, that when used with ___SMMUL would be like multiplying by 0.33333. Is that the best approach or is there a better one?
So sort of a programming question, but hopefully not an annoying "teach me C++ pls" post.
Cheers,
SPF