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

mesh = LIRE_MAILLAGE(identifier=u'1:1',
                     UNITE=3)

model = AFFE_MODELE(identifier=u'2:1',
                    AFFE=_F(MODELISATION=('DKT', ),
                            PHENOMENE='MECANIQUE',
                            TOUT='OUI'),
                    MAILLAGE=mesh)

shell = AFFE_CARA_ELEM(identifier=u'3:1',
                       COQUE=_F(EPAIS=0.01,
                                GROUP_MA=('Shell', )),
                       MODELE=model)

steel = DEFI_MATERIAU(identifier=u'4:1',
                      ELAS=_F(E=2.1e+11,
                              NU=0.3))

fieldmat = AFFE_MATERIAU(identifier=u'5:1',
                         AFFE=_F(MATER=(steel, ),
                                 TOUT='OUI'),
                         MAILLAGE=mesh,
                         MODELE=model)

load = AFFE_CHAR_MECA(identifier=u'6:1',
                      DDL_IMPO=_F(GROUP_NO=('Fix', ),
                                  LIAISON='ENCASTRE'),
                      FORCE_NODALE=_F(FZ=-100.0,
                                      GROUP_NO=('Load', )),
                      MODELE=model)

reslin = MECA_STATIQUE(identifier=u'7:1',
                       CARA_ELEM=shell,
                       CHAM_MATER=fieldmat,
                       EXCIT=_F(CHARGE=load),
                       MODELE=model)

stress = CALC_CHAMP(identifier=u'8:1',
                    CARA_ELEM=shell,
                    CHAM_MATER=fieldmat,
                    CONTRAINTE=('SIGM_ELNO', ),
                    CRITERES=('SIEQ_ELNO', ),
                    MODELE=model,
                    RESULTAT=reslin,
                    TOUT_ORDRE='OUI')

unnamed0 = POST_CHAMP(identifier=u'9:1',
                      EXTR_COQUE=_F(NIVE_COUCHE='SUP',
                                    NOM_CHAM=('SIGM_ELNO', 'SIEQ_ELNO'),
                                    NUME_COUCHE=1),
                      RESULTAT=stress)

Final = CALC_CHAMP(identifier=u'10:1',
                   CARA_ELEM=shell,
                   CONTRAINTE=('SIGM_NOEU', ),
                   CRITERES=('SIEQ_NOEU', ),
                   RESULTAT=unnamed0,
                   TOUT_ORDRE='OUI')

IMPR_RESU(identifier=u'11:1',
          FORMAT='MED',
          RESU=(_F(MAILLAGE=mesh,
                   RESULTAT=Final),
                _F(MAILLAGE=mesh,
                   RESULTAT=reslin)),
          UNITE=80)

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