LeeHoYeung

Mr. Ho Yeung Lee

535 Reputation

10 Badges

12 years, 238 days

Social Networks and Content at Maplesoft.com

Seldom to ask question after retired math hobby Welcome August, February, July, May born girl And waited for her email to mavio@protonmail.com

MaplePrimes Activity


These are questions asked by LeeHoYeung

How to calculate colimit with only substitution and solve? Any simple example to show the steps.

run a command string in C# by calling maple

it can run in maple if copy into maple

however return input string was not in correct format

String commandstring = "restart;with(LinearAlgebra):with(ExcelTools): filename := "0257.HK";open3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "B2:B100");high3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "C2:C100");low3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "D2:D100");close3 := Import(cat(cat("C://Temp//HK//Transportation//",filename),".xls"), filename, "E2:E100");n := 30;Round := proc(x,n::integer:=1) parse~(sprintf~(cat("%.",n,"f"),x)); end proc: t:=1; gg :=Matrix(n+1,1); ggg :=Matrix(n+1,1); for k from 0 to n do InputMatrix3 := Matrix([[close3[t+1+k] , close3[t+k], close3[t+2+k]],[close3[t+k], close3[t+2+k],0],[close3[t+2+k],0 , 0]]): InputMatrix3b := Matrix([[close3[t+2+k], close3[t+1+k] , close3[t+3+k]],[close3[t+1+k] , close3[t+3+k],0],[close3[t+3+k],0 , 0]]): InputMatrix3c := Matrix([[close3[t+3+k] , close3[t+2+k], close3[t+4+k]],[close3[t+2+k], close3[t+4+k],0],[close3[t+4+k],0 , 0]]): Old_Asso_eigenvector := Eigenvectors(MatrixMatrixMultiply(Transpose(InputMatrix3), InputMatrix3)): Old_Asso_eigenvector2 := Eigenvectors(MatrixMatrixMultiply(Transpose(InputMatrix3b), InputMatrix3b)): Old_Asso_eigenvector3 := Eigenvectors(MatrixMatrixMultiply(Transpose(InputMatrix3c), InputMatrix3c)): gg[k+1,1] :=Old_Asso_eigenvector[2][1,1]; od;Round(Re(gg[1,1][1,1]));";

alpha:= (1/2)*(-y*t2-x*t1-y*t3+sqrt(y^2*t2^2+2*y*t2*x*t1+2*y^2*t2*t3+x^2*t1^2+2*x*t1*y*t3+y^2*t3^2-4*x*t4*y*t9-4*x*t4*y*t8-4*x^2*t4*t7-4*y^2*t5*t9-4*y^2*t5*t8-4*y*t5*x*t7-4*y^2*t6*t9-4*y^2*t6*t8-4*y*t6*x*t7))/(x*t4+y*t5+y*t6);
g := -y/x;
f := (-x+sqrt(x^2-x*y-2*y^2))/(2*y+x);
subs(p=f,subs(q=f,subs(x=p,subs(y=q,g))));
g := (1/2)*(-x+sqrt(x^2-4*y*x-4*y^2))/(x+y);
f := x*y;
gof := subs(p=f,subs(q=f,subs(x=p,subs(y=q,g))));
lhsgofoalpha := subs(q= alpha,subs(p=alpha, subs(x=p,subs(y=q,gof))));
foalpha := subs(p= alpha,subs(q=alpha,subs(x=p,subs(y=q,f))));
rhsgofoalpha := subs(x= foalpha,subs(y= foalpha, g));
osys := lhsgofoalpha = rhsgofoalpha;
sys1 := subs(x=0, osys);
sys2 := subs(y=0, osys);
sys3 := subs(x=1, osys);
sys4 := subs(y=1, osys);
sys5 := subs(x=2, osys);
sys6 := subs(y=2, osys);
sys7 := subs(x=3, osys);
sys8 := subs(y=3, osys);
sys9 := subs(x=4, osys);
sys1 := subs(x=3,subs(y=2, osys));
sys2 := subs(x=5,subs(y=1, osys));
sys3 := subs(x=1,subs(y=5, osys));
sys4 := subs(x=1,subs(y=2, osys));
sys5 := subs(x=2,subs(y=5, osys));
sys6 := subs(x=5,subs(y=2, osys));
sys7 := subs(x=2,subs(y=1, osys));
sys8 := subs(x=3,subs(y=5, osys));
sys9 := subs(x=5,subs(y=3, osys));
res:=solve([sys1, sys2, sys3, sys4, sys5, sys6, sys7, sys8, sys9], {t1,t2,t3,t4,t5,t6,t7,t8,t9});
eval(osys,res);
simplify(%);
`~`[lhs](select(evalb, res));

 

(g o f ) o alpha =g o (f o alpha)
restart;alpha := (1/2)*(-x-x*t1-y*t2-y*t3+sqrt(x^2+2*x^2*t1+2*x*y*t2+2*x*y*t3+x^2*t1^2+2*x*t1*y*t2+2*x*t1*y*t3+y^2*t2^2+2*y^2*t2*t3+y^2*t3^2-4*x*t4*y*t9-4*x^2*t4*t7-4*x*t4*y*t8-4*y^2*t9-4*y*x*t7-4*y^2*t8-4*y^2*t5*t9-4*y*t5*x*t7-4*y^2*t5*t8-4*y^2*t6*t9-4*y*t6*x*t7-4*y^2*t6*t8))/(x*t4+y+y*t5+y*t6);
g := -y/x;
f := (-x+sqrt(x^2-x*y-2*y^2))/(2*y+x);
subs(p=f,subs(q=f,subs(x=p,subs(y=q,g)))); # -1
g := (-x+sqrt(x^2-x*y-2*y^2))/(2*y+x);
f := x*y;
gof := subs(p=f,subs(q=f,subs(x=p,subs(y=q,g)))); # -(1/3)*(y/x+sqrt(-2*y^2/x^2))*x/y
lhsgofoalpha := subs(q= alpha,subs(p=alpha, subs(x=p,subs(y=q,gof))));
foalpha := subs(p= alpha,subs(q=alpha,subs(x=p,subs(y=q,f))));
rhsgofoalpha := subs(x= foalpha,subs(y= foalpha, g));
osys := lhsgofoalpha = rhsgofoalpha;
sys1 := subs(x=0, osys);
sys2 := subs(y=0, osys);
sys3 := subs(x=1, osys);
sys4 := subs(y=1, osys);
sys5 := subs(x=2, osys);
sys6 := subs(y=2, osys);
sys7 := subs(x=3, osys);
sys8 := subs(y=3, osys);
sys9 := subs(x=4, osys);
sys1 := subs(x=3,subs(y=2, osys));
sys2 := subs(x=5,subs(y=1, osys));
sys3 := subs(x=1,subs(y=5, osys));
sys4 := subs(x=1,subs(y=2, osys));
sys5 := subs(x=2,subs(y=5, osys));
sys6 := subs(x=5,subs(y=2, osys));
sys7 := subs(x=2,subs(y=1, osys));
sys8 := subs(x=3,subs(y=5, osys));
sys9 := subs(x=5,subs(y=3, osys));
res:=solve([sys1, sys2, sys3, sys4, sys5, sys6, sys7, sys8, sys9], {t1,t2,t3,t4,t5,t6,t7,t8,t9});
eval(osys,res);
simplify(%);
`~`[lhs](select(evalb, res));

How to test  associativity?

How to determine which of below has associativity?

 

The definition x*(y*z) = (x*y)*z.

asso := -(1/2)*(x+y+sqrt(x^2+2*x*y-3*y^2))/y;
asso := -(1/4)*(2*x+y+sqrt(4*x^2+4*x*y-7*y^2))/y;
asso := -(2*x+y)/(y+z);
asso := (1/2)*(-y-z+sqrt(y^2-2*z*y+z^2-8*z*x))/z;
asso := (1/2)*(-z+sqrt(z^2-4*z*x-4*z*y))/z;

First 101 102 103 104 105 106 107 Last Page 103 of 141