Welcome to the forums. Please post in English or French.

You are not logged in.

#1 2019-04-01 07:57:55

chenghui62000
Member
From: Norway
Registered: 2018-06-19
Posts: 63

assign the force using champ method

Dear all,

suppose I would like to add a force field to all the nodes in the model, Can I use the following structure?

    TES = CREA_CHAMP(MODELE=model, 
                    OPERATION='AFFE', 
                    TYPE_CHAM='NOEU_FORC_R',
                    AFFE=_F(GROUP_NO=('allnodes', ), 
                            NOM_CMP=('FX', 'FY','FZ',), 
                            VALE=(0.1, 0.2,0.0)
                            ), 
                    ) 
    LOAD1=AFFE_CHAR_MECA(MODELE=model,
                        EVOL_CHAR=TES,)

actually, it gives an error message, I have no idea how to change the syntax mistake.

CR phase d'initialisation
   Etape : AFFE_CHAR_MECA    ligne : 110    fichier : u'fort.1'
      Mot-clé simple : EVOL_CHAR
         !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
         ! <code_aster.Cata.Legacy.DS.co_cham_gd_sdaster.cham_no_sdaster object at         !
         ! 0x7f93fa1313d0> (de type <class                                                 !
         ! 'code_aster.Cata.Legacy.DS.co_cham_gd_sdaster.cham_no_sdaster'>) n'est pas d'un !
         ! type autorisé: (<class                                                          !
         ! 'code_aster.Cata.Legacy.DS.co_resultat_sdaster.evol_char'>,)                    !
         !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
      Fin Mot-clé simple : EVOL_CHAR
   Fin Etape : AFFE_CHAR_MECA
fin CR phase d'initialisation

best regards,
Hui Cheng

Offline

#2 2019-04-01 17:46:16

chenghui62000
Member
From: Norway
Registered: 2018-06-19
Posts: 63

Re: assign the force using champ method

HI, I got the answer to that question.
it needs "crea_resu" to create the evol_char type structure. and then it can be applied to the model.

    TES[k] = CREA_CHAMP(MODELE=model, 
                    OPERATION='AFFE', 
                    TYPE_CHAM='NOEU_FORC_R',
                    AFFE=_F(GROUP_NO=('allnodes', ), 
                            NOM_CMP=('FX',), 
                            VALE=(0.1)
                            ), 
                    ) 

    cham[k]=CREA_RESU(OPERATION='AFFE',
                   TYPE_RESU='EVOL_CHAR',
                   NOM_CHAM='FORC_NODA',
                   AFFE=(_F(CHAM_GD=TES[k], MODELE=model, INST=k,),
                        ),
                  );
    LOAD1[k]=AFFE_CHAR_MECA(MODELE=model,
                        EVOL_CHAR=cham[k],

Offline

Board footer