Question: issues about smart plot and implicit 2d plot for complicated expression containing v,z

Hi all guys, first I would express my gratitude to @mmcdara . He helped me construct the matrix polynomial properly. Then on basis of it, I explore more but meet with issues. Notation : v1 and v2 is eigenvalues which consists of complicated expression containg component v and z, now I wanna implicitplot the region: abs(v1)<=1 & abs(v2)<=1 (satisfy at the same time). But I don't know how to command the code. So I define eq1:=( abs(v1)-1)* (abs(v2)<=1) and implicit it. (I know it is false but I just wanna try first). But I command the implicitplot code, the evaluating time is so long(25mins no end still). So I recall the smartplot, I once I have triggered this command, it seems that I put the mouse on the expression result (the end of the blue font), and implicit3d appears in the work bar on the right (of course this is in another file). In the file I uploaded, I tried this but failed. So I want to understand how to ensure that smartplot is triggered 100%? (Because I feel that smartplot runs very fast) and how to draw the desired region (abs(v1)<=1 & abs(v2)<=1)?

restart;
v=lambda*h;
z=mu*h;
k=lambda/mu;

v = lambda*h

 

z = mu*h

 

k = lambda/mu

(1)

with(LinearAlgebra):

A := Matrix([[0, 0, 0], [-(cos(alpha*v)-1)/v^2, 0, 0], [0, -(cos(beta*v)-1)/(cos(alpha*v)*v^2), 0]]);

Matrix(3, 3, {(1, 1) = 0, (1, 2) = 0, (1, 3) = 0, (2, 1) = -(cos(alpha*v)-1)/v^2, (2, 2) = 0, (2, 3) = 0, (3, 1) = 0, (3, 2) = -(cos(beta*v)-1)/(cos(alpha*v)*v^2), (3, 3) = 0})

(2)

C := Matrix([0, alpha, -beta])

Vector[row](3, {(1) = 0, (2) = alpha, (3) = -beta})

(3)

e := Vector(3, 1)

Vector(3, {(1) = 1, (2) = 1, (3) = 1})

(4)

E := IdentityMatrix(3)

Matrix(3, 3, {(1, 1) = 1, (1, 2) = 0, (1, 3) = 0, (2, 1) = 0, (2, 2) = 1, (2, 3) = 0, (3, 1) = 0, (3, 2) = 0, (3, 3) = 1})

(5)

G := Matrix([[0], [sin(alpha*v)/(alpha*v)], [((sin(beta*v)*cos(alpha*v)+sin(alpha*v)*cos(beta*v)-sin(alpha*v)))/(v*cos(alpha*v)*(beta))]])

Vector(3, {(1) = 0, (2) = sin(alpha*v)/(alpha*v), (3) = (sin(beta*v)*cos(alpha*v)+sin(alpha*v)*cos(beta*v)-sin(alpha*v))/(v*cos(alpha*v)*beta)})

(6)

b := Vector(3, [1/24, (-sin(beta*v)*v^3+12*cos(beta*v)*v^2+24*cos(beta*v)*cos(v)-24*sin(beta*v)*sin(v)+24*sin(beta*v)*v-24*cos(beta*v))/(24*v^3*(cos(beta*v)*sin(alpha*v)+sin(beta*v)*cos(alpha*v))), -(sin(alpha*v)*v^3+12*cos(alpha*v)*v^2+24*cos(v)*cos(alpha*v)+24*sin(v)*sin(alpha*v)-24*v*sin(alpha*v)-24*cos(alpha*v))/(24*v^3*(cos(beta*v)*sin(alpha*v)+sin(beta*v)*cos(alpha*v)))])

Vector(3, {(1) = 1/24, (2) = (1/24)*(-sin(beta*v)*v^3+12*cos(beta*v)*v^2+24*cos(beta*v)*cos(v)-24*sin(beta*v)*sin(v)+24*sin(beta*v)*v-24*cos(beta*v))/(v^3*(sin(beta*v)*cos(alpha*v)+sin(alpha*v)*cos(beta*v))), (3) = -(1/24)*(sin(alpha*v)*v^3+12*cos(alpha*v)*v^2+24*cos(v)*cos(alpha*v)+24*sin(v)*sin(alpha*v)-24*v*sin(alpha*v)-24*cos(alpha*v))/(v^3*(sin(beta*v)*cos(alpha*v)+sin(alpha*v)*cos(beta*v)))})

(7)

bp := Vector(3, [1/12, -(sin(beta*v)*v^2+12*cos(beta*v)*sin(v)-12*cos(beta*v)*v+12*cos(v)*sin(beta*v)-12*sin(beta*v))/(12*v^2*(cos(beta*v)*sin(alpha*v)+sin(beta*v)*cos(alpha*v))), -(sin(alpha*v)*v^2+12*cos(v)*sin(alpha*v)-12*cos(alpha*v)*sin(v)+12*cos(alpha*v)*v-12*sin(alpha*v))/(12*v^2*(cos(beta*v)*sin(alpha*v)+sin(beta*v)*cos(alpha*v)))])

Vector(3, {(1) = 1/12, (2) = -(1/12)*(sin(beta*v)*v^2+12*cos(beta*v)*sin(v)-12*cos(beta*v)*v+12*cos(v)*sin(beta*v)-12*sin(beta*v))/(v^2*(sin(alpha*v)*cos(beta*v)+sin(beta*v)*cos(alpha*v))), (3) = -(1/12)*(sin(alpha*v)*v^2+12*cos(v)*sin(alpha*v)-12*cos(alpha*v)*sin(v)+12*cos(alpha*v)*v-12*sin(alpha*v))/(v^2*(sin(alpha*v)*cos(beta*v)+sin(beta*v)*cos(alpha*v)))})

(8)

L0 := E + z^2 *~ A

Matrix(3, 3, {(1, 1) = 1, (1, 2) = 0, (1, 3) = 0, (2, 1) = -z^2*(cos(alpha*v)-1)/v^2, (2, 2) = 1, (2, 3) = 0, (3, 1) = 0, (3, 2) = -z^2*(cos(beta*v)-1)/(cos(alpha*v)*v^2), (3, 3) = 1})

(9)

L1 := simplify(L0^(-1))

Matrix(3, 3, {(1, 1) = 1, (1, 2) = 0, (1, 3) = 0, (2, 1) = z^2*(cos(alpha*v)-1)/v^2, (2, 2) = 1, (2, 3) = 0, (3, 1) = z^4*(cos(beta*v)-1)*(1-sec(alpha*v))/v^4, (3, 2) = z^2*(cos(beta*v)-1)*sec(alpha*v)/v^2, (3, 3) = 1})

(10)

AUX := simplify(L1 . G . C . e, size)

Vector(3, {(1) = 0, (2) = sin(alpha*v)*(alpha-beta)/(alpha*v), (3) = -((z^2*beta*sec(alpha*v)*(cos(beta*v)-1)*sin(alpha*v)+v^2*alpha*sin(beta*v))*cos(alpha*v)+sin(alpha*v)*alpha*v^2*(cos(beta*v)-1))*(-alpha+beta)/(v^3*alpha*cos(alpha*v)*beta)})

(11)

N1 := simplify((1 - z^2/2) + z^4 * (b^+ . AUX), size)

(1/24)*(z^4*(cos(beta*v)-1)*(v^3-24*v+24*sin(v))*(-alpha+beta)*(sec(alpha*v)*z^2*beta*cos(alpha*v)+v^2*alpha)*sin(alpha*v)^2-12*(-sec(alpha*v)*z^6*beta*(cos(beta*v)-1)*(v^2+2*cos(v)-2)*(-alpha+beta)*cos(alpha*v)+((2*z^4*(-alpha+beta)^2*cos(v)+(-alpha+beta)^2*(v^2-2)*z^4+v^4*z^2*beta*alpha-2*v^4*beta*alpha)*cos(beta*v)-(1/12)*(-alpha+beta)*z^4*((v^3-24*v+24*sin(v))*(beta+alpha)*sin(beta*v)-12*alpha*(v^2+2*cos(v)-2)))*v^2)*cos(alpha*v)*sin(alpha*v)-12*sin(beta*v)*(-2*(-alpha+beta)*z^4*cos(v)-(v^2-2)*(-alpha+beta)*z^4+v^4*z^2*beta-2*v^4*beta)*v^2*alpha*cos(alpha*v)^2)/(v^6*(sin(alpha*v)*cos(beta*v)+sin(beta*v)*cos(alpha*v))*alpha*cos(alpha*v)*beta)

(12)

N2 := simplify(1 - z^2 * (b^+ . L1 . e), size)

(1/24)*((12*z^4*(v-z)*(v+z)*(v^2+2*cos(v)-2)*(sec(alpha*v)-1)*cos(beta*v)-12*z^4*(v-z)*(v+z)*(v^2+2*cos(v)-2)*sec(alpha*v)-(-24*z^4*sin(v)+(-v^3+24*v)*z^4+v^5*z^2-24*v^5)*v^2*sin(beta*v)+12*z^2*(v-z)*(v+z)*(v^2+z^2)*(v^2+2*cos(v)-2))*cos(alpha*v)+(sin(alpha*v)*z^4*(v-z)*(v+z)*(v^3-24*v+24*sin(v))*sec(alpha*v)+(24*z^6*sin(v)+(v^3-24*v)*z^6-v^7*z^2+24*v^7)*sin(alpha*v)-12*v^2*z^2*(v-z)*(v+z)*(v^2+2*cos(v)-2))*cos(beta*v)+(v^3-24*v+24*sin(v))*(-sin(alpha*v)*z^2*sec(alpha*v)+(v^2+z^2)*sin(alpha*v)+sin(beta*v)*v^2)*z^2*(v+z)*(v-z))/(v^7*(sin(alpha*v)*cos(beta*v)+sin(beta*v)*cos(alpha*v)))

(13)

N3 := simplify(-z^2 + z^4 * (bp^+ . AUX), size)

-(-(1/12)*z^2*(cos(beta*v)-1)*(v^2+12*cos(v)-12)*(-alpha+beta)*(sec(alpha*v)*z^2*beta*cos(alpha*v)+v^2*alpha)*sin(alpha*v)^2+(-sec(alpha*v)*z^4*beta*(cos(beta*v)-1)*(-alpha+beta)*(v-sin(v))*cos(alpha*v)+((-z^2*(-alpha+beta)^2*sin(v)+(z^2*(-alpha+beta)^2+v^2*beta*alpha)*v)*cos(beta*v)-(1/12)*(-alpha+beta)*z^2*((v^2+12*cos(v)-12)*(beta+alpha)*sin(beta*v)-12*alpha*(v-sin(v))))*v^2)*cos(alpha*v)*sin(alpha*v)+sin(beta*v)*((-alpha+beta)*z^2*sin(v)+v*((alpha-beta)*z^2+v^2*beta))*v^2*alpha*cos(alpha*v)^2)*z^2/(v^5*(sin(alpha*v)*cos(beta*v)+sin(beta*v)*cos(alpha*v))*alpha*cos(alpha*v)*beta)

(14)

NULL

N4 := simplify(1 - z^2 * (bp^+ . L1 . e), size):
alpha:= 1/2 + 1/10*sqrt(5);
beta:= -1/2 + 1/10*sqrt(5);
det := simplify(N1*N4 - N2*N3, size):
tr := simplify(N1 + N4, size):
#eq1:=algsubs(v=lambda*h,det):
#eq2:=algsubs(z=mu*h,eq1):
#eq3:=algsubs(lambda=mu*k,eq2):
#eq4:=algsubs(v=lambda*h,eq3):
#csgn(sqrt(mu^10*k^10/v^10)*h^5):=1:
#simplify(series(sqrt(eq4),h,10));
#series(simplify(algsubs(v=,simplify(series(1-sqrt(det),z,8)))),z,8);
#eq1:=(sec(sqrt(5)*z/10)*(-cos(z/2)*z + 12*sin(z/2)) - 5*z)/(24*z*k);
#simplify(eq1);

1/2+(1/10)*5^(1/2)

 

-1/2+(1/10)*5^(1/2)

(15)

lambda1 := (tr-sqrt(tr^2-4*det))*(1/2); lambda2 := (tr+sqrt(tr^2-4*det))*(1/2)

with(plots); with(plots, implicitplot)

eq11 := lambda1*lambda2-abs(lambda1)-abs(lambda2)+1 <= 0

Download 2d_implicit_plot_[v_z].mw

Please Wait...