shimaa sadk

35 Reputation

5 Badges

2 years, 247 days

MaplePrimes Activity


These are replies submitted by shimaa sadk

@mmcdara 

thanks for your help sir i preciated it so much 

@dharr 

thanks alot sir  for your help my last Question why null doesn't work with fsolve comand inside my loop

@dharr 

actually i want to look for the solving in +ve region and to break the loop and reapeat it with same assign of so 

@Kitonum 

No that what i didnt mean sir, what i ment that, i have an equation as apart of my loop and some times maple can't solve it so i was looking for acomand that  help me to test if the equation cant be solved then i assign to it another value

@tomleslie 

thanks alot sir for your help, but  fsolve comand  is not always work and help me in solving my equations . is there is any comand help me to solve my equation for example 

 

Reylighood*distribution;
with(LinearAlgebra); with(VectorCalculus); with(Student[LinearAlgebra]); with(SignalProcessing); with(RandomTools); with(Statistics); with(stats);
f[1] := n*R+sum((1/2)*x[g]^2, g = 1 .. n)-(sum((1/2)*(2+a[g])*x[g]^2/(1-(1-Q)*exp(-x[g]^2/(2*R))), g = 1 .. n));
f[2] := m*S+sum((1/2)*y[t]^2, t = 1 .. m)-(sum((1/2)*(2+b[t])*y[t]^2/(1-(1-Q)*exp(-y[t]^2/(2*S))), t = 1 .. m));
f[3] := (n+m+sum(a[g], g = 1 .. n)+sum(b[t], t = 1 .. m))/Q-(sum((2+a[g])/(exp(x[g]^2/(2*R))-1+Q), g = 1 .. n))-(sum((2+b[t])/(exp(y[t]^2/(2*S))-1+Q), t = 1 .. m));
sum(f[i]^2, i = 1 .. 3);

ggrad := Matrix([[diff(sum(f[i]^2, i = 1 .. 3), R)], [diff(sum(f[i]^2, i = 1 .. 3), S)], [diff(sum(f[i]^2, i = 1 .. 3), Q)]]);
n := 50; m := 50;
a := [seq(0, i = 1 .. 50)]; b := [seq(0, i = 1 .. 50)];

;

E1[1] := 0.5e-1; E2[1] := 0.5e-1; E3[1] := 0.5e-1;
K := 1000;

for so from 0 to K do W := GenerateUniform(n, 0, 1); for iii to n do vv[iii] := W[iii]^(1/(iii+sum(a[jjj], jjj = n-iii+1 .. n))) end do; for sss to n do uu[sss] := 1-product(vv[n-jjj+1], jjj = 1 .. sss); x[sss] := fsolve(1-3/(exp(t^2/(2*.6))-(1-3)) = uu[sss], t = 0 .. infinity) end do; U := GenerateUniform(m, 0, 1); for ii to m do v[ii] := U[ii]^(1/(ii+sum(b[jj], jj = m-ii+1 .. m))) end do; for ss to m do u[ss] := 1-product(v[m-jj+1], jj = 1 .. ss); y[ss] := fsolve(1-3/(exp((1/2)*t^2)-(1-3)) = u[ss], t = 0 .. infinity) end do; C := describe[quartile[1]]([seq(x[i], i = 1 .. n)]); CC := describe[quartile[2]]([seq(x[i], i = 1 .. n)]); CCC := describe[quartile[3]]([seq(x[i], i = 1 .. n)]); L := describe[quartile[1]]([seq(y[i], i = 1 .. m)]); LL := describe[quartile[2]]([seq(y[i], i = 1 .. m)]); LLL := describe[quartile[3]]([seq(y[i], i = 1 .. m)]); R[1] := fsolve(3*exp(C^2/(2*R))-exp(CC^2/(2*R)) = 2, R = 0 .. infinity); S[1] := fsolve(3*exp(L^2/(2*S))-exp(LL^2/(2*S)) = 2, S = 0 .. infinity); Q[1] := ((eval(exp(CC^2/(2*R))-1, R = R[1])+eval(exp(LL^2/(2*S))-1, S = S[1]))*(1/2)+(eval(3*exp(L^2/(2*S))-3, S = S[1])+eval(3*exp(C^2/(2*R))-3, R = R[1]))*(1/2))*(1/2) end do;
 

 

@Mariusz Iwaniuk 

iam sorry if i bothering you; could you look please for my last  uplood wrk sheat and 
help me with any suggestion?

thanks alot for your help  god please you

@Mariusz Iwaniuk 
thanks alot sir for your help..........i have another Question
how can i prevent all this writting from apperence and what does this writting means ??
when i applay it into another integration i have the following massage 
Error, (in evalf/int) invalid method, ftocms
here is my proplem i dealing with and unfortunately my proplem still the same
 


 

``

with(LinearAlgebra):

r[1] := int(VectorCalculus:-`*`(VectorCalculus:-`*`(VectorCalculus:-`*`(lambda[1], alpha^2), exp(VectorCalculus:-`*`(lambda[1], Z))), 1/VectorCalculus:-`*`(VectorCalculus:-`+`(exp(VectorCalculus:-`*`(lambda[1], Z)), VectorCalculus:-`-`(VectorCalculus:-`+`(1, VectorCalculus:-`-`(alpha))))^2, VectorCalculus:-`+`(exp(VectorCalculus:-`*`(lambda[2], Z)), VectorCalculus:-`-`(VectorCalculus:-`+`(1, VectorCalculus:-`-`(alpha)))))), Z = 0 .. infinity);

int(lambda[1]*alpha^2*exp(lambda[1]*Z)/((exp(lambda[1]*Z)-1+alpha)^2*(exp(lambda[2]*Z)-1+alpha)), Z = 0 .. infinity)

(1)

``

NULL

``

R[1] := Expand(diff(r[1], lambda[1])):

lambda[1] := VectorCalculus:-`*`(3, 1/10):

aa[1] := 0:

r_r[1] := Re(simplify(r[1]))

(10/27)*3^(5/6)*arctan(3^(5/6)/(-2+3^(1/3)))+(1/27)*3^(2/3)*ln(3^(2/3)-3^(1/3)+1)-(2/27)*3^(2/3)*ln(1+3^(1/3))-(5/27)*3^(1/3)*ln(3^(2/3)-3^(1/3)+1)+(10/27)*3^(1/3)*ln(1+3^(1/3))+(2/9)*3^(1/6)*arctan(3^(5/6)/(-2+3^(1/3)))+(2/9)*3^(1/2)*Pi-(2/3)*ln(3^(2/3)-3^(1/3)+1)-(2/3)*ln(1+3^(1/3))+2*ln(2)+1/3

(2)

R_R[1] := Re(evalf(R[1]));

Float(undefined)

 

-5.223468552

 

2.445216045

 

Warning,  computation interrupted

 

-1.616996143

 

2.445216045

 

4.417156107

 

-0.8798088751e-1

 

0.88621008e-2

 

Warning,  computation interrupted

 

-0.8798088751e-1

 

Warning,  computation interrupted

 

``


Download aquestion.mw

@Carl Love 

hi sir, iam trying to generate asample of binomial distribution as he does, but the problem is X[i] is given as alist of one number and 

x[i+1] :=x[i]-3  so x[i+1] can't be evaluated becoust it's consist of alist is there any way to transform this list to just anumber??

@Kitonum 

the problem occurs when i solve three equations in threes unkown parameters the result is given by 

and i want the first value is given to anew sympol for example called <R[0]> and so on 
is there a way to solve agroup of equations and the result  came in a list instead of agroup and could i control the naming of the results

@acer  

what i meant  that if a:=0.6364562590  its approximatly a:=0.64 how i evaluate this approximation by maple

@Carl Love thanks alot sir it actually doesnt work in 3d plot 

@vv excuse me sir but could you explain more what did you mean  by the inner sum and outer sum 
(thanks alot for your help)

@Carl Love actually sir it does work when i replease infinity with 100 but does it mathematically true

1 2 Page 2 of 2