As you suspected, Jeremy, the simplify=False didn't have any visible affect.
BTW, earlier, I should have posted this as the code:
equ1 = =Q_1*s_1 - Q_2*s_1 + 2*Q_2 - Q_dp_1 - 2*sqrt(Q_2*(Q_1*s_1 - Q_2*s_1
+ Q_2 + 2*sqrt(Q_1*Q_2*s_1*(1 - s_1)))) + 2*sqrt(Q_1*Q_2*s_1*(1 - s_1))
s1, s2, q_dp1, q_dp2 = sym.symbols('s_1, s_2, Q_dp_1, Q_dp_2')
eq1 = equ1.subs({ s: s1 }) - q_dp1
md( "$" + sym.latex(eq1) + " = 0$\n" )
eq2 = equ1.subs({ s: s2 }) - q_dp2
md( "$" + sym.latex(eq2) + " = 0$\n" )
soln = sym.solve([eq1, eq2], q1, q2)
print(f"soln = {soln}")
On Thursday, August 4, 2022 at 9:54:24 PM UTC-7 Kevin Pauba wrote:
> And eq1=Q_1*s_1 - Q_2*s_1 + 2*Q_2 - Q_dp_1 - 2*sqrt(Q_2*(Q_1*s_1 - Q_2*s_1
> + Q_2 + 2*sqrt(Q_1*Q_2*s_1*(1 - s_1)))) + 2*sqrt(Q_1*Q_2*s_1*(1 - s_1)) ...
> sorry, long day!
>
> On Thursday, August 4, 2022 at 9:39:53 PM UTC-7 Kevin Pauba wrote:
>
>> Sorry, Jeremy. Good suggestion!
>>
>> s1, s2, q_dp1, q_dp2 = sym.symbols('s_1, s_2, Q_dp_1, Q_dp_2')
>> eq1 = equ1.subs({ s: s1 }) - q_dp1
>> md( "$" + sym.latex(eq1) + " = 0$\n" )
>>
>> eq2 = equ1.subs({ s: s2 }) - q_dp2
>> md( "$" + sym.latex(eq2) + " = 0$\n" )
>>
>> soln = sym.solve([eq1, eq2], q1, q2)
>> print(f"soln = {soln}")
>>
>> I'll set simplify to False and see how it goes ...
>> On Thursday, August 4, 2022 at 8:18:00 PM UTC-7 Kevin Pauba wrote:
>>
>>> I've attached a portion of a jupyter notebook. I'm attempting to solve
>>> a simultaneous equation using sympy. The sym.solve() in the green input
>>> box doesn't return (well, I waited over night on my macbook pro). Might
>>> the solution be intractable? Is there another way to get a solution? Any
>>> help is greatly appreciated.
>>
>>
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/sympy/55366c61-c3ca-445e-b792-b2dcb2fdfe65n%40googlegroups.com.