I've encountered a very strange issue with Maple. Hopefully to get an answer from here.
The result returns differently with solve and fsolve after/before a variable is given a certain value. See attachment and/or PDF exported from Maple
The result comes from solve (with variable epsilon) returns value of the same variable with imaginary part while the fsolve returns the correct answer.
Now how can I achieve the same result as fsolve via solve?
Thanks!
The error is because of the way you use
assign. The output of yoursolvestep is multiple lists on the formIf you try to run
assign(%)then only the last list will be used. That meansx = 2,z = 3andywill be unassigned.Instead, get the values of $d_0$ by a sequence call, taking the first element of each list and print it. We have used
allvaluesbecausesolvewas returning expressions involving RootOfs.Alternatively, you can set
epsilonbefore thesolvestep to avoid theallvaluespart.Note that the
fsolveonly captures one of the analytic solutions as expected.