Download super2.dgibi

Back to the list

* fichier :  super2.dgibi
opti echo 0;
opti dime 2;
*
* automatic normalization
*
opti norm auto;
*
* definition of the mesh points and of the elements
*
p1=1 0; p2=2 0; p3=2 0; p4=3 0;
mes1=manu 'SUPE' p1 p2; mes2=manu 'SUPE' p3 p4;
*
* definition of 2 matrices K1=|2 1| and K2=|1 1|
*                             |1 1|        |1 2|
*
lis1=prog 2 1 1 1; 
rig1=manu 'RIGIDITE' 'TYPE' 'RIGIDITE' mes1 (mots 'UY') lis1;
lis2=prog 1 1 1 2;
rig2=manu 'RIGIDITE' 'TYPE' 'RIGIDITE' mes2 (mots 'UY') lis2;
*
* definition of the relation and "assembly" of K
*
rel1=rela 'UY' p2 - 'UY' p3;
rig1=rig1 et rig2 et rel1;
*
* use of the 'MASSE' option
*
masbl1=mass 'UY' 1 p4;
super1=super 'RIGIDITE' rig1 masbl1;
bb2 mas2=super 'MASSE' super1 masbl1 'LCHP';
u2=extr bb2 1;
*
*mess 'Solution with the "MASSE" option';
*mess (extr u2 'UY' p1) (extr u2 'UY' p2) (extr u2 'UY' p4);
*
* solution of the dirichlet problem
*
bl1=bloq p4 'UY';
f1=depi 1 bl1;
u1=reso (rig1 et bl1) f1;
u1=redu u1 (extr u2 'MAIL');
*
* error check
*
er1=u2-u1;
si ((xtx er1) > 1.D-15); erre 5;
sinon;                 ; erre 0; finsi;
FIN;
 

© Cast3M 2003 - All rights reserved.
Disclaimer