My best guess is that theres an actual example in the training corpus that its pulling from. Or that this is being gamed in some way.
Luckily this problem can be solved as you can prompt the model to not solve math, but instead transform them into a structure that can be fed into an API (like wolfram alpha).
With a multistep process it would be easy to have ChatGPT generate accurate answers to advanced math problems:
1. Instruct ChatGPT to not solve mathematical expression it sees in the prompt, instead only extract the expression(s) into a list. 2. Programmatically scan the output, and make API calls to get the answers. 3. Submit the answers to ChatGPT and tell it to answer the original question with the newly supplied information. 4. Voila! You can solve almost any mathematical question using natural language.