clear all G = [1 2 3]; F=[1 2 3]; syms x y for j=1:1:3 a(j)=F(j)+(G(j)).^2*(1-x)^2; xsoln(j) = solve(a(j),x); end
MATLAB: I am trying to solve for x; but I am getting an error. With a linear system of equations this works. I would appreciate your suggestions. Thanks
nonlinear system of equations
Related Solutions
There are 3 solutions, which you will find by setting the 'ReturnConditions' option to true:
syms x A alpha h2msyms b positive rationalpsi = A*exp(-(b*x^2));V = alpha*x^4;H = -h2m*diff(diff(psi)) + V*psi;Hall = psi*H;avgE=int(Hall,x,-inf,inf);pretty(simplify(Hall))pretty(simplify(avgE))fmin = diff(avgE,b);pretty(simplify(fmin));eqn = (fmin == 0);minb = solve(eqn,b ,'ReturnConditions',true);minb.conditionsminb.b
results are:
ans = 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & ((~0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) & ~0 < alpha/h2m | ~in(((15*alpha)/(16*h2m))^(1/3), 'rational') & (~0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) & 0 < alpha/h2m | 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (~in(((15*alpha)/(16*h2m))^(1/3), 'rational') | ~0 < alpha/h2m) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1))) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (~0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (~in(((15*alpha)/(16*h2m))^(1/3), 'rational') | ~0 < alpha/h2m) & A ~= 0 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & ((~0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) & ~0 < alpha/h2m | ~in(((15*alpha)/(16*h2m))^(1/3), 'rational') & (~0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) & 0 < alpha/h2m | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (~in(((15*alpha)/(16*h2m))^(1/3), 'rational') | ~0 < alpha/h2m) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1))) | 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (~0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (~in(((15*alpha)/(16*h2m))^(1/3), 'rational') | ~0 < alpha/h2m) & A ~= 0 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (~0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | ~0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (~0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | ~0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1) | ~0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1) | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (~0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (~0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & ~in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) | 0 < (- 1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & 0 < (1 + 3^(1/2)*1i)^2*((15*alpha)/(16*h2m))^(1/3) & in(((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3), 'rational') & in(((15*alpha)/(16*h2m))^(1/3), 'rational') & A ~= 0 & 0 < alpha/h2m & (signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 | signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 & signIm(((3^(1/2)*1i)/2 - 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) ~= 1 & (signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == -1 | signIm(((3^(1/2)*1i)/2 + 1/2)*((15*alpha)/(16*h2m))^(1/6)*1i) == 1)) ans = ((3^(1/2)*1i)/2 - 1/2)^2*((15*alpha)/(16*h2m))^(1/3) ((3^(1/2)*1i)/2 + 1/2)^2*((15*alpha)/(16*h2m))^(1/3) ((15*alpha)/(16*h2m))^(1/3)
>> x = [1,2,3];>> tmp = bsxfun(@gt,x,x(:));>> sum(tmp(:))ans = 3
Best Answer