Вы находитесь на странице: 1из 4

CAMPUS TECNOLGICO DE LA UNIVERSIDAD DE NAVARRA.

NAFARROAKO UNIBERTSITATEKO CAMPUS TEKNOLOGIKOA


Paseo de Manuel Lardizbal 13. 20018 Donostia-San Sebastin. Tel.: 943 219 877 Fax: 943 311 442 www.tecnun.es informacion@tecnun.es
Deduccin de la formulacin matricial de un elemento en una ecuacin diferencial lineal
ordinaria de segundo orden con funciones de interpolacin polinmicas de grado M.

Caso 1.- Ecuacin de la forma -[p(X)y']' + q(X)y =g(X).
Funciones de interpolacin polinmicas de grado M.
Considrese el intervalo [, ] dividido en L elementos cuyos extremos son [X
1
, X
M+1
], [X
M+1
, X
2m+1
], [X
2M+1
, X
3M+1
],
., [X
(k-1)M+1
,X
kM+1
], ., [X
(L-1)M+1
, X
LM+1
], donde X
1
= y X
LM+1
= . Se va reducir este estudio al elemento
genrico e
k
, definido en el subintervalo [X
(k-1)M+1
,X
kM+1
]. Sus nodos estn definidos, en coordenadas globales por
los puntos X
(k-1)M+1
, X
(k-1)M+2
, X
(k-1)M+3
, , X
(k-1)M+r
, ., X
(k-1)M+M
, X
kM+1
, que en coordenadas locales seran x
1
(=0),
x
2
, x
3
, , x
r
, , x
M
, x
M+1
, respectivamente. Represe que el cambio de coordenadas globales a locales viene
definido por
X = x + X
(k-1)M+1
por lo que dX = dx: Con este cambio, la ecuacin diferencial expresada en coordenadas locales para el elemento
e
k
tendr la forma:
-[p(x + X
(k-1)M+1
)y']' + q(x + X
(k-1)M+1
)y =g(x + X
(k-1)M+1
)
Las funciones de interpolacin van a ser polinomios de grado M de la forma:
) x x ( ... ) x x ( ) x x ( ... ) x x ( x
) x x ( )... x x ( ) x x ( ... ) x x ( x
) x ( N
1 M r 2 r r 1 r r 2 r r
1 M 2 r 1 r 2 k
r
+
+



donde r = 1, ..., M+1 y k= 1, ..., L. Se puede comprobar que
rs s
k
r
) x ( N
donde
rs
es la delta de Kronecker de 2 orden, que verifica que
rs
= 1 si r = s, pero
rs
= 0 si r s.
Con estas funciones de interpolacin la funcin en este elemento se aproxima mediante la curva definida por:
) x ( N u y
1 M
1 r
k
r r M ) 1 k (
+

+


(1)

donde u
(k-1)M+r
son los valores de las ordenadas en los nodos del elemento.
Llevando esta aproximacin a la ecuacin diferencial se llega a :
[ ] + + + +
+
+

+ + +
) X x ( g ) x ( N u ) x X ( q ' ' y ) x X ( p
1 M ) 1 k (
1 M
1 r
k
r r M ) 1 k ( 1 M ) 1 k ( 1 M ) 1 k (

) u ,..., x ( R
1 k M +

donde R(x, ..., u
Mk+1
) es el residuo, al no verificar (1) la ecuacin diferencial.
Aplicando el mtodo de Galerkin, en el que
1 M ..., , 1 s 0 dx ) x ( N ) u ,..., x ( R
k
h
o
k
s 1 k M
+
+

esta integral conduce a las siguientes integrales cuya suma ha de ser nula:
i) Integrando por partes la integral correspondiente al primer sumando del primer miembro de la ecuacin
diferencial
[ ] [ ] + + +
+ +
k
h
0
k
s 1 M ) 1 k (
k
h
0
k
s 1 M ) 1 k (
) x ( N ' y ) x X ( p dx ) x ( N ' ' y ) x X ( p
dx
dx
) x ( dN
'. y ) x X ( p
k
h
0
k
s
1 M ) 1 k (

+ +
+

ii) El segundo trmino conduce a la integral
dx ) x ( N ) x ( N u ) x X ( q
k
s
k
h
0
1 M
1 r
k
r r M ) 1 k ( 1 M ) 1 k (


+
+

+ +

iii) El tercer trmino, que se le llamar -f
s
, donde, como es sabido s toma los valores 1, , M+1:
s
k
s
k
h
0
1 M ) 1 k (
f dx ) x ( N ) x X ( g +
+

reuniendo los tres resultados e imponiendo que s suma sea cero se llega a
+
+
+ +
+
) h ( N ) X ( ' y ) X ( p ) 0 ( N ) X ( ' y ) X ( p
k
k
s 1 M k
1 M k
k
s
1 M ) 1 k (
1 M ) 1 k (

+ + +

+
dx
dx
) x ( dN
'. y ) x X ( p
k
h
0
k
s
1 M ) 1 k (


2/4

r
k
s
k
h
0
1 M
1 r
k
r r M ) 1 k ( 1 M ) 1 k (
f dx ) x ( N ) x ( N u ) x X ( q +

+ +

Sustituyendo en la integral primera y' por su valor en funcin de las derivadas de las funciones de interpolacin, de
acuerdo con la expresin (1), se obtiene
+
+
+ +
+
) h ( N ) X ( ' y ) X ( p ) 0 ( N ) X ( ' y ) X ( p
k
k
s 1 M k
1 M k
k
s
1 M ) 1 k (
1 M ) 1 k (

,
_

+ + + +

+ +
+

+
dx ) x ( N ) x ( N ) x X ( q
dx
) x ( dN
dx
) x ( dN
) x X ( p u
k
h
0
k
s
k
r 1 M ) 1 k (
k
s
k
r
1 M ) 1 k (
1 M
1 r
r M ) 1 k (

s
f
llamando
dx ) x ( N ) x ( N ) x X ( q
dx
) x ( dN
dx
) x ( dN
) x X ( p K
k
h
0
k
s
k
r 1 M ) 1 k (
k
s
k
r
1 M ) 1 k (
k
sr

,
_

+ + +
+ +

se llega a las siguientes expresiones
1 1 M k
k
1 M , 1 1 M ) 1 k (
k
11 1 M ) 1 k ( 1 M ) 1 k (
f u K .... u K ) X ( ' y ) X ( p + + +
+ + + + +

.
.
1 M s y 1 s para f u K .... u K u K
s 1 M k
k
1 M , s 2 M ) 1 k (
k
2 s 1 M ) 1 k (
k
1 s
+ + + +
+ + + +

.
.
1 M 1 M k
k
1 M , 1 M 1 M ) 1 k (
k
1 , 1 M 1 kM 1 kM
f u K .... u K ) X ( ' y ) X ( p
+ + + + + + + +
+ + +
Si se define la matriz simtrica
1
1
1
1
1
1
1
]
1

+ + +
+
+
k
1 M , 1 M
k
1 , 1 M
k
1 M , M
k
21
k
1 M 1
k
12
k
11
k
el
K K
K
K
K K K
K
y los vectores

,
_


+ +
+ +
) X ( ' y ) X ( p
0
0
) X ( ' y ) X ( p
1 M k 1 M k
1 M ) 1 k ( 1 M ) 1 k (
k
C

,
_


+
+
+
1 M k
2 M ) 1 k (
1 M ) 1 k (
k
u
u
u
u
y

,
_

+1 M
1
k
f
f
f

3/4

las ecuaciones anteriores adoptan la forma:
k k k
el
f u K C +


Caso 2.- Ecuacin de la forma p(X)y'' + q(X)y' + r(x)y(X) = g(X).
Haciendo las mismas consideraciones que en el caso anterior en cuanto a funciones de interpolacin y al clculo
del residuo, aplicando Galerkin, se llega a las siguientes integrales:
i) Integrando por partes la integral correspondiente al primer sumando del primer miembro de la ecuacin
diferencial
[ ] + + +
+ +
k
h
0
k
s 1 M ) 1 k (
k
h
0
k
s 1 M ) 1 k (
) x ( N ' y ) x X ( p dx ) x ( N " y ) x X ( p
dx
dx
) x X ( dp
'. y ) x ( N dx
dx
) x ( dN
'. y ) x X ( p
k
h
0
1 M ) 1 k (
k
s
k
h
0
k
s
1 M ) 1 k (

+
+ + +
+
+

ii) El segundo sumando define la integral
dx ) x ( N
dx
) x ( dN
u ) x X ( q
k
s
k
h
0
1 M
1 r
k
r
r M ) 1 k ( 1 M ) 1 k (


+
+

+ +

iii) El tercer trmino conduce a la integral
dx ) x ( N ) x ( N u ) x X ( r
k
s
k
h
0
1 M
1 r
k
r r M ) 1 k ( 1 M ) 1 k (


+
+

+ +

iv) El cuarto trmino se llamar -f
s
, al igual que en el caso anterior:
s
k
s
k
h
0
1 M ) 1 k (
f dx ) x ( N ) x X ( g +
+

Llamando
+

,
_

+
+

+
+
dx
dx
) x ( dN
dx
) x X ( dp
) x ( N
dx
) x ( dN
dx
) x ( dN
) x X ( p K
k
h
0
k
s
1 M ) 1 k (
k
s
k
s
k
r
1 M ) 1 k (
k
sr

dx ) x ( N ) x ( N ) x X ( r ) x ( N
dx
) x ( dN
) x X ( q
k
h
0
k
s
k
r 1 M ) 1 k (
k
s
k
r
1 M ) 1 k (

,
_

+ + + +
+ +

Se llega, de modo parecido al caso anterior, a la ecuacin matricial
k k k
el
f u K C +
donde u
k
y f
k
coinciden con las expresiones anteriores y la matriz, ahora no simtrica,
1
1
1
1
1
1
1
]
1

+ + +
+
+
k
1 M , 1 M
k
1 , 1 M
k
1 M , M
k
21
k
1 M 1
k
12
k
11
k
el
K K
K
K
K K K
K
y el vector

,
_

+ +
+ +
) X ( ' y ) X ( p
0
0
) X ( ' y ) X ( p
1 M k 1 M k
1 M ) 1 k ( 1 M ) 1 k (
k
C


Cdigo en Maple
Caso 1.-
Funciones de la ecuacin diferencial, en la forma -(p(x)y')' + q(x)y - g(x) = 0:
> p:=x->;

4/4

> q:=x->;
> g:=x->;
Definicin de las funciones de interpolacin: es usual que los nodos estn igualmente espaciados dentro de un
elemento, espacio h_k/M, siendo h_k la longitud del elemento y M el grado del polinomio de interpolacin; r es el
nmero de la funcin de interpolacin (vara entre 1 y M+1).
> N:=proc(r,x,h_k) local s,k,t; global M; for k from 1 to M+1 do t[k]:=(k-1)*h_k/M od ; if r>M+1 then `Error` elif r=1
then mul(x-t[s],s = 2 .. M+1)/mul(t[1] -t[s],s = 2 .. M+1) elif r=M+1 then mul(x-t[s],s = 1 .. M)/mul(t[r] -t[s],s = 1 .. M)
else mul(x-t[s],s = 1 .. r-1)*mul(x-t[s],s = r+1 .. M+1)/(mul(t[r] -t[s],s = 1 .. r-1)*mul(t[r]-t[s],s = r+1 .. M+1)) fi end;
Derivada respecto a x de las funciones de interpolacin
> DN:=proc(r,x,h_k);
> diff(N(r,x,h_k),x);
> end;
Integracin de los trminos de la matriz de rigidez de un elemento genrico
> for j from 1 to M+1 do for r from 1 to M+1 do
>K_el[j,r]:=int(N(j,x,h_k)*N(r,x,h_k)*q(X_k+x)+DN(j,x,h_k)*DN(r,x,h_k)*p(X_k+x),x=0..h_k)od od:
Vector del segundo miembro
> for j from 1 to M+1 do fel[j]:=int(g(x+X_k)*N(j,x,h_k),x=0..h_k) od:
> for j from 1 to L do f_e[j]:=matrix(M+1,1,0):
> for k from 1 to M+1 do f_e[j][k,1]:=evalf(subs(X_k=X[j],h_k=H[j],fel[k])) od:

Caso 2.-
Funciones de la ecuacin diferencial de la forma p(x)y'' + q(x)y' +r(x)y = g(x) :
> p:=x->;
> q:=x->;
> r:=x->;
> g:=x->;
> Dp:=D(p);
Definicin de las funciones de interpolacin: r es el nmero de la funcin de interpolacin (vara entre 1 y M+1);
h_k es la longitud del elemento.
> N:=proc(r,x,h_k)
> local s,k,t; global M;
> for k from 1 to M+1 do t[k]:=(k-1)*h_k/M od ;
> if r>M+1 then `Error`
> elif r=1 then mul(x-t[s],s = 2 .. M+1)/mul(t[1] -t[s],s = 2 .. M+1)
> elif r=M+1 then mul(x-t[s],s = 1 .. M)/mul(t[r] -t[s],s = 1 .. M)
> else mul(x-t[s],s = 1 .. r-1)*mul(x-t[s],s = r+1 .. M+1)/(mul(t[r] -t[s],s = 1 .. r-1)*mul(t[r]-t[s],s = r+1 .. M+1)) fi end;
Derivada respecto a x de las funciones de interpolacin
> DN:=proc(r,x,h_k);
> diff(N(r,x,h_k),x);
> end;
Integracin de los trminos de la matriz de rigidez de un elemento genrico
> for j from 1 to M+1 do
> for s from 1 to M+1 do
> K_el[s,j]:=int(-DN(j,x,h_k)*N(s,x,h_k)*Dp(X_k+x)-
DN(j,x,h_k)*DN(s,x,h_k)*p(X_k+x)+DN(j,x,h_k)*N(s,x,h_k)*q(X_k+x)+N(j,x,h_k)*N(s,x,h_k)*r(X_k+x),x=0..h_k)od
od:
Vector del segundo miembro
> for j from 1 to M+1 do fel[j]:=int(g(x+X_k)*N(j,x,h_k),x=0..h_k) od:
> for j from 1 to L do f_e[j]:=matrix(M+1,1,0):
> for k from 1 to M+1 do f_e[j][k,1]:=evalf(subs(X_k=X[j],h_k=H[j],fel[k])) od:

Вам также может понравиться