DEBUT(identifier=u'0:1',
      )

elem0 = LIRE_MAILLAGE(identifier=u'1:1',
                      FORMAT='MED',
                      UNITE=20)

model = AFFE_MODELE(identifier=u'2:1',
                    AFFE=_F(GROUP_MA='edge',
                            MODELISATION='BARRE',
                            PHENOMENE='MECANIQUE'),
                    MAILLAGE=elem0)

carael = AFFE_CARA_ELEM(identifier=u'3:1',
                        BARRE=_F(CARA='A',
                                 GROUP_MA='edge',
                                 SECTION='GENERALE',
                                 VALE=1),
                        MODELE=model)

prop = DEFI_MATERIAU(identifier=u'4:1',
                     ELAS=_F(ALPHA=0.01,
                             E=2.1e+11,
                             NU=0.3,
                             RHO=7800))

material = AFFE_MATERIAU(identifier=u'5:1',
                         AFFE=_F(MATER=prop,
                                 TOUT='OUI'),
                         MAILLAGE=elem0)

B_1 = AFFE_CHAR_MECA(identifier=u'6:1',
                     DDL_IMPO=(_F(GROUP_NO='hold',
                                  LIAISON='ENCASTRE'),
                               _F(DZ=0,
                                  GROUP_NO='slide'),
                               _F(DY=0,
                                  GROUP_MA='edge')),
                     FORCE_NODALE=_F(FZ=-2,
                                     GROUP_NO='load'),
                     MODELE=model)

results = MECA_STATIQUE(identifier=u'7:1',
                        CARA_ELEM=carael,
                        CHAM_MATER=material,
                        EXCIT=_F(CHARGE=B_1),
                        MODELE=model)

result1 = CALC_CHAMP(identifier=u'8:1',
                     CONTRAINTE=('EFGE_ELNO', 'SIEF_NOEU'),
                     RESULTAT=results)

IMPR_RESU(identifier=u'9:1',
          FORMAT='MED',
          RESU=_F(RESULTAT=result1),
          UNITE=80)

IMPR_RESU(identifier=u'10:1',
          FORMAT='RESULTAT',
          RESU=_F(NOM_CHAM=('EFGE_ELNO', ),
                  RESULTAT=result1),
          UNITE=2)

IMPR_RESU(identifier=u'11:1',
          FORMAT='RESULTAT',
          RESU=_F(NOM_CHAM=('SIEF_NOEU', ),
                  RESULTAT=result1),
          UNITE=3)

FIN(identifier=u'12:1',
    )
