I would like to use FindRoot for a problem of this type:
{f[x, y] == 0, g[x, y] == 0, 0 < y < x < 10}
My problem is that the interval is dependent on $ x, y $, so I don't know if it is possible to tell FindRoot to restrict its search. I tried including the inequality into the "equation" part as such :
FindRoot[{f[x, y] == 0, g[x, y] == 0, y < x}, {{x, 2, 0, 10}, {y, 1, 0, 10}}]
But of course this returns an error since FindRoot should take only equations.
Is there a way to do it or I have to program it myself from scratch?
To make myself clearer, I really need to find these solutions numerically, as there is no hope of finding them analytically. Here is the type of function I need to find the roots of, as per request:
f[m1_, m2_] := (2 l1)/(Sqrt[A] Sqrt[sp[m1, m2]]) ((EllipticK[sm[m1,m2]/sp[m1, m2]] (m1 - m2))/(m1 l1^2) + ((T^2 + Tc^2) - (m1 - m2)/(m1 l1^2)) EllipticPi[-((m1 l1^2)/sp[m1, m2]), sm[m1, m2]/sp[m1, m2]])
g[m1_,m2_] := (2 l2)/(Sqrt[A] Sqrt[sp[m1, m2]]) ((EllipticK[sm[m1, m2]/sp[m1, m2]] (m2 - m1))/(m2 l2^2) + ((T^2 - Tc^2) - (m2 - m1)/(m2 l2^2)) EllipticPi[-((m2 l2^2)/sp[m1, m2]), sm[m1, m2]/sp[m1, m2]])
Where l1, l2, A, sm[m1, m2], sp[x, y], T, Tc are numerical parameters/rational functions that are fixed. Not sure if this will be of much help.
Including the full definition of the functions is too long, I will try to produce a minimal working example that exhibits the same behavior as my functions.
NSolve? – MarcoB Dec 11 '20 at 16:56FindMinimum[{f[x, y]^2 + g[x, y]^2, y < x}, {{x, 2, 0, 10}, {y, 1, 0, 10}}]work for you? You didn't include the full definitions, so I can't test & adjust. – Michael E2 Dec 11 '20 at 17:44FindMinimum[{f[x, y]^2 + g[x, y]^2, y < x}, {{x, 1, 0, 10}, {y, 2, 0, 10}}]`
– Michael E2 Dec 11 '20 at 17:52