Re: FindRoot failing in v8 on a system easily solvable in v7

• To: mathgroup at smc.vnet.net
• Subject: [mg114779] Re: FindRoot failing in v8 on a system easily solvable in v7
• From: Grischika <Grischika at mail.ru>
• Date: Fri, 17 Dec 2010 03:26:49 -0500 (EST)

```On 15 15:50, vasil michev <mic... at gmail.com> wrote:
> Consider the following input
>
> eq1:=Block[{u1,u2,u3,u4},u1:=uX-2*NIntegrate[Cos[x]/(Exp[1/1.529266/
> T*(uX*0.004559*(1-Cos[x])+uY*0.004559*(1-Cos[y])+uZ*0.012095*(1-
> Cos[z]))]-1),{x,-\[Pi],\[Pi]},{y,-\[Pi],\[Pi]},{z,-\[Pi],\
> [Pi]},PrecisionGoal->4, MaxPoints->15000000,Method ->
> u2:=uY-2*NIntegrate[Cos[y]/(Exp[1/1.529266/T*(uX*0.004559*(1-Cos[x])
> +uY*0.004559*(1-Cos[y])+uZ*0.012095*(1-Cos[z]))]-1),{x,-\[Pi],\[Pi]},
>
> u3:=uZ-2*NIntegrate[Cos[z]/(Exp[1/1.529266/T*(uX*0.004559*(1-Cos[x])
> +uY*0.004559*(1-Cos[y])+uZ*0.012095*(1-Cos[z]))]-1),{x,-\[Pi],\[Pi]},
>
> u4:=1.529266-NIntegrate[1/(Exp[1/1.529266/T*(uX*0.004559*(1-Cos[x])
> +uY*0.004559*(1-Cos[y])+uZ*0.012095*(1-Cos[z]))]-1),{x,-\[Pi],\[Pi]},
>
> FindRoot[{u1,u2,u3,u4},{{uX,2,2.2},{uY,.5,.8},{uZ,1.5,2.5},{T,
> 0.01,0.1}},AccuracyGoal->5,PrecisionGoal->5]//Quiet]
>
> In v7 I get
>
> {uX->1.08147,uY->1.08147,uZ->2.08043,T->0.023582}
>
> while in v8 I get NIntegrate::inumr errors. Help browser shows no
> changes to FindRoot in v8 and I cant figure out whats failing. A quick
> test shows that the equations dont have any undefined parameters
>
> In[15]:= Block[{uX=1,uY=1,uZ=1,T=1},u1]
> Out[15]= -69.385
>
> so it must be FindRoot thats causing the problem. Any ideas?

This is work
eq1:=Block[{u1,u2,u3,u4},u1[uX_?NumberQ,uY_?NumberQ,uZ_?
NumberQ]:=uX-2*NIntegrate[Cos[x]/(Exp[1/1.529266/T*(uX*0.004559*(1-
Cos[x])+uY*0.004559*(1-Cos[y])+uZ*0.012095*(1-Cos[z]))]-1),{x,-\[Pi],\
[Pi]},{y,-\[Pi],\[Pi]},{z,-\[Pi],\[Pi]},PrecisionGoal->4,MaxPoints-
u2[uX_?NumberQ,uY_?NumberQ,uZ_?NumberQ]:=uY-2*NIntegrate[Cos[y]/
(Exp[1/1.529266/T*(uX*0.004559*(1-Cos[x])+uY*0.004559*(1-Cos[y])
+uZ*0.012095*(1-Cos[z]))]-1),{x,-\[Pi],\[Pi]},{y,-\[Pi],\[Pi]},{z,-\
[Pi],\[Pi]},PrecisionGoal->4,MaxPoints->15000000,Method-
u3[uX_?NumberQ,uY_?NumberQ,uZ_?NumberQ]:=uZ-2*NIntegrate[Cos[z]/
(Exp[1/1.529266/T*(uX*0.004559*(1-Cos[x])+uY*0.004559*(1-Cos[y])
+uZ*0.012095*(1-Cos[z]))]-1),{x,-\[Pi],\[Pi]},{y,-\[Pi],\[Pi]},{z,-\
[Pi],\[Pi]},PrecisionGoal->4,MaxPoints->15000000,Method-
u4[uX_?NumberQ,uY_?NumberQ,uZ_?NumberQ]:=1.529266-NIntegrate[1/
(Exp[1/1.529266/T*(uX*0.004559*(1-Cos[x])+uY*0.004559*(1-Cos[y])
+uZ*0.012095*(1-Cos[z]))]-1),{x,-\[Pi],\[Pi]},{y,-\[Pi],\[Pi]},{z,-\
[Pi],\[Pi]},PrecisionGoal->4,MaxPoints->15000000,Method-