Question: need to procedure for calculating...

hi....how i can extract Coefficients  (i.e. {f1[2],f2[2],f2[3],f3[2],.....f3[6]}) from every algebric equations and create matrix A ,in form AX=0, (X are f1[2],f2[2],f2[3],f3[2],.....f3[6] ) then the determinant of the matrix of coefficients (A) set to zero for obtaining unknown parameter omega.?

Note that  if m=3 then 6 equations is appeare and if m=4 then 9 equations is appeare.thus i need a procedure that works for every arbitary value of ''m''.

in attached file below m=4 thus we have 9 equations, i.e. 3 for eq1[k_] and 3 for eq2[k_] and so on...

also we should use boundary conditions for some amount of fi[j] (i=1,2,3 and j=2,3,...,7)

be extacting above Coefficients for example from first equation ,

''**:= (1/128)*f1[2]*omega^2-(1/4)*f2[2]-(1/2)*f2[3]+(1/4)*f2[4]+(1/4)*f3[2]-(1/2)*f3[3]+(1/4)*f3[4]+140*f1[2]-80*f1[3]+20*f1[4]'''

must compute

coeff(**, f1[2]); coeff(**, f2[2]) and so on...

 

 

 

 

 

fdm-maple.mw

 

 ############################Define some parameters

 

 
restart; Digits := 15; A1 := 10; A2 := 10; A3 := 10; A4 := 1; A5 := 1; A6 := 1; A7 := 1; A8 := 1; A9 := 1; A10 := 1; A11 := 1; B1 := 10; B2 := 10; B3 := 10; B4 := 1; B5 := 1; B6 := 1; B7 := 1; B8 := 1; B9 := 1; B10 := 1; B11 := 1; C1 := 10; C2 := 10; C3 := 10; C4 := 1; C5 := 1; C6 := 1; C7 := 1; C8 := 1; C9 := 1; C10 := 1; C11 := 1; C12 := 1; C13 := 1; C14 := 1; C15 := 1; C16 := 1; A12 := 1; B12 := 1; C18 := 1; C17 := 1; C19 := 1; n := 1; U := proc (x, theta) options operator, arrow; f1(x)*cos(n*theta) end proc; V := proc (x, theta) options operator, arrow; f2(x)*sin(n*theta) end proc; W := proc (x, theta) options operator, arrow; f3(x)*cos(n*theta) end proc; n := 1; m := 4; len := 1; h := len/m; nn := m+1
 ############################Define some equation

eq1[k_] := -2*f1[k]*(-A11*n^4+A10*n^2+A12*omega^2)*h^4+(A6*(f2[k-1]-f2[k+1])*n^3+A9*(f3[k-1]-f3[k+1])*n^2-A5*(f2[k-1]-f2[k+1])*n-A8*(f3[k-1]-f3[k+1]))*h^3+(4*(f1[k]-(1/2)*f1[k-1]-(1/2)*f1[k+1]))*(A3*n^2-A2)*h^2+(-A4*(f2[k-2]-2*f2[k-1]+2*f2[k+1]-f2[k+2])*n-A7*(f3[k-2]-2*f3[k-1]+2*f3[k+1]-f3[k+2]))*h+12*A1*(f1[k]+(1/6)*f1[k-2]-(2/3)*f1[k-1]-(2/3)*f1[k+1]+(1/6)*f1[k+2]):
  ``

 

 

 

 

                                     ######################################  APPLY BOUNDARY CONDITIONS

f1[nn+1] := f1[m]:
 

for k from 2 to m do eq1[k_]; eq2[k_]; eq3[k_] end do

-(1/64)*f2[4]+(1/128)*f2[3]+(1/64)*(f3[4]-(1/2)*f3[3])*(omega^2-1)-(1/64)*f1[2]+(1/32)*f1[3]+(1/64)*f1[4]-280*f3[4]-120*f3[2]+300*f3[3]+20*f3[7]

(1)

``



Download fdm-maple.mw

 

Please Wait...