mehdibgh

235 Reputation

6 Badges

7 years, 92 days

MaplePrimes Activity


These are questions asked by mehdibgh

I have two big symbolic and numerical matrices in a worksheet, whats the best way and easiest way to transfer them to another maple worksheet?

I have a big vector composed of different real values elements. I want to extract the value of elements that are between specified interval (x1<val<x2) and their corresponding element numbers. How is it possible in Maple in simplest way?

For example suppose R:=[ 4,-1,9,11,-4,2,4,1,-1,2.2,112,44,-134,0.124,34,41,7,97,13.22123]:

I want the elements that their values are in the interval of -2<val<3 and their corresponding element numbers. 

Namely: vals:=[-1,2,1,-1,2.2,0.124] and their corresponding numbers: Numbs:=[2,6,8,9,10,14]

I have two square matrices (LS,RS) in the form of generalized eigen-value problem as below:

LS*z=omega*RS*z

One time, I am using inverse of RS multiplying by LS to get the eigen values as
MS := MatrixInverse(RS) . LS:
VL1, VR1 := Eigenvectors(MS):

Next time, I am using direct method as below to get the eigen values 

VL2, VR2 := Eigenvectors(LS, RS);
 

I am wondering there are meaningful differences between VL1 and VL2 as well as VR1 and VR2.

Does anybody know why?

RS.mw

LS.mw

 

 

 

I have a big vector (1*10000) composed of negative, positive and HFloat(infinity) elements. How to extract only positive elements of this messy big vector with corresponding number of element,except positive infinities?

For example, suppose only the 111,181, 206th elemenst of this vector are positive values as: 101.2109e11,19211.129,87211.

How to get both 111,181, 206 and their corresponding values, 101.2109e11,19211.129,87211?



I did dummy indices implication using add command as below. is it OK or there are mistakes?

Is there another way to imply dummy index summation in maple instead of using add command?

any suggestion???

restart

II := 9:

JJ := 9:

with(LinearAlgebra):

 

 

F := add(add(add(add(R[i, m]*R[k, m]*(U[i, j]*U[k, j]+U[i, j]*V[k, j]+V[i, j]*V[k, j]+W[i, j]*W[k, j])/((2*m+1)*(2*j+1)), i = 0 .. II), k = 0 .. II), m = 0 .. II), j = 0 .. JJ):

EqU := seq(seq(diff(F, U[i, j]), j = 0 .. JJ), i = 0 .. II):

EqV := seq(seq(diff(F, V[i, j]), j = 0 .. JJ), i = 0 .. II):

EqW := seq(seq(diff(F, W[i, j]), j = 0 .. JJ), i = 0 .. II):

var := [seq(seq(U[i, j], j = 0 .. JJ), i = 0 .. II), seq(seq(V[i, j], j = 0 .. JJ), i = 0 .. II), seq(seq(W[i, j], j = 0 .. JJ), i = 0 .. II)]:

NULL

sys := [EqU, EqV, EqW]:

Aa, bb := GenerateMatrix(sys, var):

Aa

RTABLE(18446744074191847422, anything, Matrix, rectangular, Fortran_order, [], 2, 1 .. 300, 1 .. 300)

(1.1)

``


 

Download Mesal.mw

 

 

 

First 9 10 11 12 13 14 15 Page 11 of 18