The previous code was too long. I've revised it to just the bare minimum.
The attached code works in Mathematica 9 (see attached simple M9).
But it doesn't work in Mathematica 14 (see simple M14).
simpleM9 and simpleM14 are exactly the same, but the results are different when you calculate it in Mathematica 9 and Mathematica 14.
The difference is in the FindMinimum command.
The last part of the program, g - y, checks the answer, but in Mathematica 9, it is almost 0, and FindMinimum is functioning normally.
In contrast, in Mathematica 14,g - y is not 0, and FindMinimum is not functioning normally.
How should I modify FindMinimum to get the same calculation results as in Mathematica 9 in order to run this program in Mathematica 14?
Attachments: