Andrei Bobrov

30 Reputation

3 Badges

12 years, 42 days

MaplePrimes Activity


These are answers submitted by Andrei Bobrov

P:=`<|>`(u,v,w,x,y,z);
out := `<|>`(LinearAlgebra:-BandMatrix(P[..5],0,5)^++MTM:-triu(`<,>`(P[..5]$5),1),`<,>`(P[6]$5));

N := 8;

LinearAlgebra:-BandMatrix([-1,2,-1],1,N);

1.

> ListTools:-Transpose(L1)[2];

2.

> L2[[seq(i,i=2:nops(L2),2)]];

ArrayTools[Reshape](A1^+,1,MTM[prod](A1)); # row

ArrayTools[Reshape](A1^+,MTM[prod](A1),1); # column

restart: with(MTM):

g1 := Vector[column](5,symbol=G1):
g2 := Vector[column](5,symbol=G2):
Tau := Matrix(5,symbol=tau):
Sigma := Matrix(5,symbol=sigma):
out := sum(Kn~(times(Sigma,<seq(g1^+,i = 1..5)>)+ times(Tau,<seq(g2^+,i = 1..5)>)),2);

Dr:=Matrix([[1,5],[2,6],[4,7]]);

Y:=Dr[..,2];

ty:=Dr[..,1];

P:=unapply(Y^+.cos~(omega*(ty -~ 1/(2*omega*tan(MTM:-sum(sin~(2*omega*ty)))))),omega);

 

coeff(algsubs(1/r=k,a),k);

restart:

a:=<<1|2|3>,<4| 5| 6>>;

v1 := convert(a^+,Vector);

v2 := convert(a^+,Vector)^+;

n := convert(MTM:-size(a),list);

k := `*`(op(n));

C := Matrix(op(n),[seq(MTM:-sum(<seq(v1[i]*v2[j],i = 1 .. k)>),j = 1 .. k)]);

MultMatrix2 := proc(A::Matrix,B::Matrix)

       local n,i,j,out;

       n := MTM:-size(A, 1); 

       out := Matrix(n);  

       for i to n do

             for j to n do

                  out[i,j] := A[i,..].B[j,..];

             end;

       end;

       return out;

end;

 

restart:

 

MultMatrix := proc(A::Matrix,B::Matrix)

     A.B^+;

end;

 

A := LinearAlgebra[RandomMatrix](3, 4,density = 1, generator = -8 .. 8);

B := LinearAlgebra[RandomMatrix](3, 4,density = .8, generator = 30 .. 70);

out := MultMatrix(A,B);

 

 

 

 

restart:
assume(m>=0);
out := evalf(subs(m = sqrt(exp(1)-1),int((x-m^2)/(x+1),x=0..m^2)));

Try this is:

 

restart:
int((x-m^2)/(x+1),x=0..m^2)  assuming m > 0;

Hi Kazzy! Use data in matrices of float type. eg:

restart:
Matlab:-det(Matrix([[1,2.56],[1,2.56^2]]));

restart:

a:=<<1|z>,<1|z^2>>;
MTM:-det(a); 

Page 1 of 1