
# PATRON 
# ANALYSE STATIQUE
# POUTRE

DEBUT();
# MISE EN DONNEES

MAIL=LIRE_MAILLAGE();

MAIL=DEFI_GROUP(reuse =MAIL,
                MAILLAGE=MAIL,
                CREA_GROUP_MA=_F(NOM='TOUT',
                                 TOUT='OUI',),);

MODMECA=AFFE_MODELE(MAILLAGE=MAIL,
                    AFFE=_F(GROUP_MA='TOUT',
                            PHENOMENE='MECANIQUE',
                            MODELISATION='POU_D_T',),);

ACIER=DEFI_MATERIAU(ELAS=_F(E=2.E10,
                            NU=0.3,),);

CHMAT=AFFE_MATERIAU(MAILLAGE=MAIL,
                    AFFE=_F(TOUT='OUI',
                            MATER=ACIER,),);
R1 = 1.0;

EP1 = 0.001;


CARA_POU=AFFE_CARA_ELEM(MODELE=MODMECA,
                        POUTRE=_F(GROUP_MA='TOUT',
                                  SECTION='CERCLE',
                                  CARA=('R','EP',),
                                  VALE=(R1,EP1,),),);

# CONDITIONS AUX LIMITES ET CHARGEMENT

#POINT A : ENCASTREMENT

BLOQUAGE=AFFE_CHAR_MECA(MODELE=MODMECA,
                        DDL_IMPO=_F(GROUP_NO='PA',
                                    LIAISON='ENCASTRE',),);
#POINT B : FORCE IMPOSEE

CHARGT=AFFE_CHAR_MECA(MODELE=MODMECA,
                      FORCE_NODALE=_F(GROUP_NO='PB',
                                      FY=1000.0,),);
# RESOLUTION DU PROBLEME ELASTIQUE

RESU1=MECA_STATIQUE(MODELE=MODMECA,
                    CHAM_MATER=CHMAT,
                    CARA_ELEM=CARA_POU,
                    EXCIT=(_F(CHARGE=BLOQUAGE,),
                           _F(CHARGE=CHARGT,),),);
# CALCUL DES EFFORTS

RESU1=CALC_ELEM(reuse =RESU1,
                RESULTAT=RESU1,
                OPTION='EFGE_ELNO_DEPL',);
# RESULTATS FORMAT GMSH

IMPR_RESU(MODELE=MODMECA,
          FORMAT='GMSH',
          RESU=_F(MAILLAGE=MAIL,
                  RESULTAT=RESU1,
                  NOM_CHAM=('DEPL','EFGE_ELNO_DEPL',),),);

FIN();
