Difference between revisions of "Contrib:Claws/Code Aster/comms"

From CAELinuxWiki
Jump to: navigation, search
Line 86: Line 86:
 
*Write the table 'Table' we just created.
 
*Write the table 'Table' we just created.
 
*Format it as 'TABLEAU' - other formats are also available
 
*Format it as 'TABLEAU' - other formats are also available
*UNITE: this is the unique number of the file you want to write the results to. This number should correspond to the number selected in ASTK, using the 'datg' file format. If you leave this unselected in your comm file, the results will be written to the .resu file
+
*UNITE: this is the unique number of the file you want to write the results to. This number should correspond to the number selected in ASTK, using the 'mast' file format. If you leave this unselected in your comm file, the results will be written to the .resu file
 
*SEPARATEUR: using comma (,) as a separator - select any character you want.
 
*SEPARATEUR: using comma (,) as a separator - select any character you want.
 
*TITRE: Name of the table
 
*TITRE: Name of the table
Line 96: Line 96:
 
  "#Reac/Force at nodes",,,,,,,,,,,,,
 
  "#Reac/Force at nodes",,,,,,,,,,,,,
 
  "#Reac/Force at nodes                                                                  ",,,,,,,,,,,,,
 
  "#Reac/Force at nodes                                                                  ",,,,,,,,,,,,,
  " ","INTITULE        ","NOEUD    ","RESU    ","NOM_CHAM        ","NUME_ORDRE  ","INST        ","ABSC_CURV     ","COOR_X      ","COOR_Y      ","COOR_Z      ","DX          ","DY          ","DZ          "
+
                                                              ",,,,,,,,,,,,,
  " ","node_reac        ","N1      ","RESU    ","REAC_NODA        ",1,0.00E+000,0.00E+000,3.00E+003,3.75E+002,1.97E+002,-9.20E+004,-1.03E+004,-5.40E+004
+
  " ","INTITULE        ","NOEUD    ","RESU    ","NOM_CHAM        ","NUME_ORDRE  ","INST        ","ABSC_CURV   ","COOR_X      ","COOR_Y      ","COOR_Z      ","DX          ","DY          ","DZ          "
" ","node_reac        ","N2      ","RESU    ","REAC_NODA        ",1,0.00E+000,3.94E+002,3.00E+003,3.75E+002,-1.97E+002,-8.17E+004,-9.48E+003,4.91E+004
+
  " ","ReacXYZ          ","-        ","RESU    ","REAC_NODA        ",1,0.00E+000,"-           ","-            ","-            ","-            ",-1.36E+006,-1.19E+005,-3.42E+002
  " ","node_reac        ","N3      ","RESU    ","REAC_NODA       ",1,0.00E+000,4.22E+002,3.00E+003,3.47E+002,-1.97E+002,1.20E-010,2.17E-010,9.13E-011
+
  " ","ForceXYZ        ","-        ","RESU    ","FORC_NODA       ",1,0.00E+000,"-           ","-            ","-            ","-            ",-1.36E+006,-1.19E+005,-3.42E+002
" ","node_reac        ","N4      ","RESU    ","REAC_NODA        ",1,0.00E+000,5.90E+002,3.00E+003,3.47E+002,-2.87E+001,-6.37E-012,-1.50E-011,5.84E-011
+
" ","node_reac        ","N5      ","RESU    ","REAC_NODA        ",1,0.00E+000,6.18E+002,3.00E+003,3.27E+002,-8.65E+000,5.65E-010,1.66E-010,1.93E-010
+

Revision as of 13:15, 3 April 2009

Comm files

Contents

Extracting max/min principal stress of a model

IMPR_RESU(FORMAT='RESULTAT',
         RESU=_F(RESULTAT=RESU,
                 NOM_CHAM='EQUI_NOEU_SIGM',
                 FORM_TABL='OUI',
                 VALE_MAX='OUI',
                 VALE_MIN='OUI',
                 SOUS_TITRE='Principal_max_min',),);

Explanation:

  • IMPR_RESU means 'write result', that can either be written to a 3d-model or printed to the .resu file (or other file)
  • FORMAT = RESULTAT means that the result should be formatted for text as opposed to a 3d-model file format such as 'med', I-DEAS or other.
  • RESULTAT=RESU: Use the calculated result 'RESU'
  • NOM_CHAM: Name of field to write; we want the 'equivalent nodal stress'
  • FORM_TABL: Format as a table
  • VALE_MIN/MAX: Display min/max values of the field
  • SOUS_TITRE: Sub-title in the .resu file

Applying this to your comm file should yield the following table:

======>
------>
Principal_max_min                                                              

LA VALEUR MAXIMALE DE VMIS     EST  1.34509E+03 EN    1 NOEUD(S) : N2      
LA VALEUR MAXIMALE DE TRESCA   EST  1.46813E+03 EN    1 NOEUD(S) : N2      
LA VALEUR MAXIMALE DE PRIN_1   EST  1.54083E+02 EN    1 NOEUD(S) : NS2689  
LA VALEUR MAXIMALE DE PRIN_2   EST  2.19908E+02 EN    1 NOEUD(S) : NS2856  
LA VALEUR MAXIMALE DE PRIN_3   EST  4.36280E+02 EN    1 NOEUD(S) : NS2856  
LA VALEUR MAXIMALE DE VMIS_SG  EST  7.11318E+02 EN    1 NOEUD(S) : NS2835  
LA VALEUR MAXIMALE DE TRSIG    EST  0.00000E+00 EN **** NOEUD(S) : N1      
LA VALEUR MINIMALE DE VMIS     EST -6.91240E+01 EN    1 NOEUD(S) : NS12279 
LA VALEUR MINIMALE DE TRESCA   EST -7.77194E+01 EN    1 NOEUD(S) : NS12279 
LA VALEUR MINIMALE DE PRIN_1   EST -1.25101E+03 EN    1 NOEUD(S) : N2      
LA VALEUR MINIMALE DE PRIN_2   EST -2.95197E+02 EN    1 NOEUD(S) : NS3361  
LA VALEUR MINIMALE DE PRIN_3   EST -1.44362E+02 EN    1 NOEUD(S) : NS10331 
LA VALEUR MINIMALE DE VMIS_SG  EST -1.45302E+03 EN    1 NOEUD(S) : N2      
LA VALEUR MINIMALE DE TRSIG    EST  0.00000E+00 EN **** NOEUD(S) : N1

Extracting node reactions and forces

Extracting the results

Table=POST_RELEVE_T(ACTION=(_F(OPERATION='EXTRACTION',
                              INTITULE='ReacXYZ',
                              RESULTAT=RESU,
                              NOM_CHAM='REAC_NODA',
                              PRECISION=0.0001,
                              GROUP_NO='load',
                              RESULTANTE=('DX','DY','DZ',),
                              MOYE_NOEUD='OUI',),
                           _F(OPERATION='EXTRACTION',
                              INTITULE='ForceXYZ',
                              RESULTAT=RESU,
                              NOM_CHAM='FORC_NODA',
                              TOUT_ORDRE='OUI',
                              GROUP_NO='load',
                              RESULTANTE=('DX','DY','DZ',),),
  • INTITULE: Name of the table
  • RESULTAT: Extract from the 'RESU' calculation
  • NOM_CHAM: Name of field, here REAC_NODA and FORC_NODA
  • Default precision
  • GROUP_NO: the node group - this has to be a node group (I'll describe how to extract from a whole model further down)
  • RESULTANTE: Vectorial components
  • MOYE_NOEUD: Average the result around a node


Writing the table to a file:

IMPR_TABLE(TABLE=Table,
          FORMAT='TABLEAU',
          UNITE=26,
          SEPARATEUR=' ,',
          TITRE='Reac/Force at nodes',);


Explanation:

  • Write the table 'Table' we just created.
  • Format it as 'TABLEAU' - other formats are also available
  • UNITE: this is the unique number of the file you want to write the results to. This number should correspond to the number selected in ASTK, using the 'mast' file format. If you leave this unselected in your comm file, the results will be written to the .resu file
  • SEPARATEUR: using comma (,) as a separator - select any character you want.
  • TITRE: Name of the table

The result should look something like this (table is a little mangled by the wiki):

"#",,,,,,,,,,,,,
"#--------------------------------------------------------------------------------",,,,,,,,,,,,,
"#",,,,,,,,,,,,,
"#Reac/Force at nodes",,,,,,,,,,,,,
"#Reac/Force at nodes                                                                  ",,,,,,,,,,,,,
                                                              ",,,,,,,,,,,,,
" ","INTITULE         ","NOEUD    ","RESU     ","NOM_CHAM         ","NUME_ORDRE   ","INST         ","ABSC_CURV    ","COOR_X       ","COOR_Y       ","COOR_Z       ","DX           ","DY           ","DZ          "
" ","ReacXYZ          ","-        ","RESU     ","REAC_NODA        ",1,0.00E+000,"-            ","-            ","-            ","-            ",-1.36E+006,-1.19E+005,-3.42E+002
" ","ForceXYZ         ","-        ","RESU     ","FORC_NODA        ",1,0.00E+000,"-            ","-            ","-            ","-            ",-1.36E+006,-1.19E+005,-3.42E+002