0% found this document useful (0 votes)
14 views50 pages

04-A Simple Mechanical Study

Uploaded by

Giuseppe
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views50 pages

04-A Simple Mechanical Study

Uploaded by

Giuseppe
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 50

A simple

mechanical study

code_aster, salome_meca course material


GNU FDL licence (http://www.gnu.org/copyleft/fdl.html)
Outline

1. Introducing a simple study


2. Starting the study
3. Data settings
4. Solving the problem
5. Post-processing the results
GNU FDL licence | code_aster, salome_meca course material
1. Introducing a simple study

A pump of the safety injection system (RIS)

 Under a constant internal pressure

Inlet pipe

Outlet pipe

GNU FDL licence | code_aster, salome_meca course material 3


1. Introducing a simple study

A pump of the safety injection system (RIS)

 Simplifications and hypotheses


Haut
 Simplify the connexions

Intake, Exhaust : supported forces

Intake
 Simplify the fixation :

Haut, Face_bas are clamped

Exhaust

Face_Bas

GNU FDL licence | code_aster, salome_meca course material 4


Outline

1. Introducing a simple study


2. Starting the study
3. Data settings
4. Solving the problem
5. Post-processing the results
GNU FDL licence | code_aster, salome_meca course material
2. Starting the study

Mesh in code_aster

 Mesh consists of
 Coordinates of nodes

 Cells defined by their connectivity

 Groups of cells (GROUP_MA) and groups of nodes (GROUP_NO)

GNU FDL licence | code_aster, salome_meca course material 6


2. Starting the study

Mesh in code_aster

GNU FDL licence | code_aster, salome_meca course material 7


2. Starting the study

Mesh in code_aster

 Import mesh in different formats


 MED format (default input format)

 Aster format and other foramts (GIBI, IDEAS, GMSH)

MAIL = LIRE_MAILLAGE ( FORMAT = … )

 Orientation of the normals


 Check for plate/shell elements or the borders where a pressure is applied

 Reorients properly the cells where contact is defined

 Command MODI_MAILLAGE Direct display

Keywords : ORIE_NORM_COQUE, ORIE_PEAU_2D, ORIE_PEAU_3D

GNU FDL licence | code_aster, salome_meca course material 8


Outline

1. Introducing a simple study


2. Starting the study
3. Data settings
4. Solving the problem
5. Post-processing the results
GNU FDL licence | code_aster, salome_meca course material
3. Data setting

Finite elements

 What is a finite element ?


 A geometric description, provided by the mesh

 Shape functions

 Degrees of freedom

 The choice determines


 equations to solve

 Discretization and integration hypothesis

 Unknowns fields

GNU FDL licence | code_aster, salome_meca course material 10


3. Data setting

Finite elements

GNU FDL licence | code_aster, salome_meca course material 11


3. Data setting

Finite elements

 Defined by command AFFE_MODELE


 Example for mechanical phenomenon, with 3D elements:
MODE = AFFE_MODELE ( AFFE = _F ( GROUP_MA ='ZONE_1',
PHENOMENE = 'MECANIQUE‘,
3D isoparametric
mechanical element MODELISATION = '3D'),)

 Different choices for 3D, 2D, 1D, 0D elements

MODELISATION = / '3D' / 'D_PLAN' / 'POU_D_T'

/ '3D_SI' / 'C_PLAN' / 'TUYAU'

/ '3D_THM' / 'DKT' / …

/ … / …

GNU FDL licence | code_aster, salome_meca course material 12


3. Data setting

Finite elements

 Mixture of finite elements Direct display

 Kinematic connections between different degrees of freedom ( in the definitions of


loadings and boundary conditions)

GNU FDL licence | code_aster, salome_meca course material 13


3. Data setting

Materials – Definition

 Defined through numerical parameters of properties


 Units are not managed by code_aster: the user must use a consistent system of units
throughout the study

 Example:

Coordinates of the mesh nodes mm m

Young's modulus MPa Pa

Applied force N N

Stress obtained as a result MPa Pa

GNU FDL licence | code_aster, salome_meca course material 14


3. Data setting

Materials – Definition

GNU FDL licence | code_aster, salome_meca course material 15


3. Data setting

Materials – Assignment

 Assigned to the mesh


GR1
 Overloading rule

 Example: GR2

1 2

STEEL1 = DEFI_MATERIAU( ELAS = _F( E = 305000.0E6, NU = 0.3, ), )


STEEL2 = DEFI_MATERIAU( ELAS = _F( E = 405000.0E6, NU = 0.3, ), )

CHMAT1 = AFFE_MATERIAU( MAILLAGE=MESH,


AFFE =(_F(GROUP_MA=('GR1','GR2',),
1
MATER=STEEL1,),
Direct display _F(GROUP_MA=('GR2',), 2
MATER=STEEL2,),),)

GNU FDL licence | code_aster, salome_meca course material 16


3. Data setting

Materials – Assignment

 Assigned to the mesh


 Assignment after the definition, and used directly in the solving operators

 Example:
STEEL1 = DEFI_MATERIAU( ELAS = _F( E = 205000.0E6, NU = 0.3, ), )
STEEL2 = DEFI_MATERIAU( ELAS = _F( E = 305000.0E6, NU = 0.3, ), )
STEEL3 = DEFI_MATERIAU( ELAS = _F( E = 405000.0E6, NU = 0.3, ), )

CHMAT1 = AFFE_MATERIAU( MAILLAGE=MESH,


AFFE =_F(TOUT='OUI',
MATER= STEEL2,),)
CHMAT2 = AFFE_MATERIAU( MAILLAGE=MESH,
AFFE =_F(TOUT='OUI',
MATER= STEEL3,),)
RESU = MECA_STATIQUE(...
CHAM_MATER= CHMAT1,
...)
GNU FDL licence | code_aster, salome_meca course material 17
3. Data setting

Materials – Consistency with constitutive equation

 Materials must be consistent with the resolution assumptions


 Example: VMIS_ISOT_TRAC, constitutive equation for von Mises elasto-plasticity with
isotropic nonlinear hardening

steel=DEFI_MATERIAU( ELAS =_F(E=2.1.E11, NU=0.3,),)


TRACTION =_F( SIGM = CTRACB),)

mater=AFFE_MATERIAU(MAILLAGE=mesh,
AFFE=_F(TOUT='OUI', MATER=steel,),)

result=STAT_NON_LINE( ... CHAM_MATER=mater,


COMPORTEMENT=_F(
RELATION = 'VMIS_ISOT_TRAC'),)

GNU FDL licence | code_aster, salome_meca course material 18


3. Data setting

Boundary conditions and loading

GNU FDL licence | code_aster, salome_meca course material 19


3. Data setting

Boundary conditions and loading

 Commands AFFE_CHAR_****(_F) Direct display

 With _F => functions

 **** => MECA / CINE / THER

 Example – different choices of boundary conditions in MECA:


Imposed relationships on the degrees of freedom (DOF)

| DDL_IMPO Unknowns imposed on a node or group


| FACE_IMPO Unknowns imposed on the nodes of a cell or a group of cells
| LIAISON_SOLIDE Rigid body element on a set of nodes or cells
| LIAISON_ELEM 3D-beam, beam-shell, 3D-pipe connections …
| LIAISON_COQUE connection between shells
 Be careful of the consistency with the DOF allowed by the chosen finite element

GNU FDL licence | code_aster, salome_meca course material 20


3. Data setting

Boundary conditions and loading

 Commands AFFE_CHAR_****(_F) Direct display

 Loadings used as boundary conditions

 Example – different choices of loadings in MECA

Loadings inside the Loadings specific to


continuous media Border loadings structural elements

| PESANTEUR | FORCE_FACE | FORCE_POUTRE


| ROTATION | FORCE_ARETE | FORCE_COQUE
| FORCE_INTERNE | FORCE_CONTOUR | FORCE_TUYAU
| FORCE_NODALE | PRES_REP . . .
. . . . . .

GNU FDL licence | code_aster, salome_meca course material 21


Outline

1. Introducing a simple study


2. Starting the study
3. Data settings
4. Solving the problem
5. Post-processing the results
GNU FDL licence | code_aster, salome_meca course material
4. Solving the problem

Setting of solving operators

 ~ 15 resolution operators to solve the physical problems


 Thermics: THER_LINEAIRE, THER_NON_LINE

 Mechanics: MECA_STATIQUE, STAT_NON_LINE

 Dynamics: DYNA_VIBRA, DYNA_NON_LINE

 Modal calculation: CALC_MODES

GNU FDL licence | code_aster, salome_meca course material 23


4. Solving the problem

Setting of solving operators

GNU FDL licence | code_aster, salome_meca course material 24


4. Solving the problem

Setting of solving operators

 Input the description of the problem prior to solving


 The model: MODELE
Analysis Summary
 Materials: CHAM_MATER

 Geometrical characteristics (for structural elements): CARA_ELEM

 Loadings: EXCIT

 A time stepping if necessary: LIST_INST (Appendix)

 One can also change settings on the resolution algorithm =>


advanced usage
 In most cases, the default values are suitable

GNU FDL licence | code_aster, salome_meca course material 25


4. Solving the problem

Setting of solving operators

 Choosing the linear solver


 via the keyword SOLVEUR / METHODE, Relevant depending on the problem

 Direct solvers

MUMPS (MUltifrontal Massively Parallel sparse direct Solver): Default method. external
solver. Slightly broader scope than MULT_FRONT. Provides access to parallelism.

MULT_FRONT (multi-frontal): Universal solver, very robust. Not recommended for mixed
models of X-FEM, incompressible ...

GNU FDL licence | code_aster, salome_meca course material 26


4. Solving the problem

Setting of solving operators

 Choosing the linear solver


 via the keyword SOLVEUR / METHODE, Relevant depending on the problem

 Iterative solvers

GCPC (Preconditioned conjugate gradient): recommended method for thermics. Useful for
well conditioned, large problems.

PETSC: external multi-method solver. Very fast and robust when associated with pre-
conditioner LDLT_SP. Provides access to parallelism.

GNU FDL licence | code_aster, salome_meca course material 27


4. Solving the problem

Setting of solving operators

 Use of parallelism
 Choose SOLVEUR=_F(METHODE=‘MUMPS’) or
SOLVEUR=_F(METHODE=‘PETSC’)

 Choose a MPI version of code_aster

 Choose the number of processors

 Moderate parallelism: Up to 8 processors, the gains are virtually guaranteed for large
enough problems (50000 unknowns)

 Massive parallelism: for huge studies (Exemple, 200 millions DOF and 2000 time steps
during 5h with 2000 processors

GNU FDL licence | code_aster, salome_meca course material 28


Outline

1. Introducing a simple study


2. Starting the study
3. Data settings
4. Solving the problem
5. Post-processing the results
GNU FDL licence | code_aster, salome_meca course material
5. Post-processing the results

Results in code_aster

GNU FDL licence | code_aster, salome_meca course material 30


5. Post-processing the results

Results in code_aster – fields, tables, functions

 Fields: CALC_CHAMP / CREA_CHAMP

 Tables: POST_ELEM / CREA_TABLE / CALC_TABLE /


POST_RELEVE_T / MACR_LIGN_COUPE

 Functions: RECU_FONCTION

GNU FDL licence | code_aster, salome_meca course material 31


5. Post-processing the results

Results in code_aster – Output files

 IMPR_RESU
 Meshes / Fields / Data contained in a result data structure.

 Different formats: RESULTAT / ASTER/ MED / GMSH/ IDEAS

 IMPR_TABLE
 Different formats: Print the contents of a table in a listing or an Excel file, also plot
curves

 IMPR_FONCTION
 Extract the evolution of a quantity as a function of another

 Formats ‘TABLEAU’ or ‘XMGRACE’,

GNU FDL licence | code_aster, salome_meca course material 32


5. Post-processing the results

Results in code_aster – Post-process

GNU FDL licence | code_aster, salome_meca course material 33


5. Post-processing the results

Results in code_aster

 Single field, single physical quantity: cham_gd


 Type;

 Several components;

 A single access number (no time step for example).

 Result data structure: resultat


 Gathering several fields of quantities in a given physics;

 Several access numbers;

 Parameters (depending on the model).

GNU FDL licence | code_aster, salome_meca course material 34


5. Post-processing the results

Results in code_aster - Fields

 Naming rule XXXX_YYYY :


 Four first characters: name of the quantity (SIGM, EPSI, ERRE, etc);

 Four last characters : location (NOEU, ELGA, ELNO or ELEM).

 Examples:
 Exception! DEPL, VITE, ACCE

 SIEQ_ELNO, SIGM_ELNO

GNU FDL licence | code_aster, salome_meca course material 35


5. Post-processing the results

Results in code_aster - Fields

 Location of the values:


 Fields on nodes (NOEU) ;

 On the elements: (ELGA) (ELNO) (ELEM).

GNU FDL licence | code_aster, salome_meca course material 36


5. Post-processing the results

Results in code_aster – Data structure resultat

 Produced by resolution operators


 The type depends on the operator:

EVOL_ELAS (linear mechanics), EVOL_NOLI (non-linear mechanics), EVOL_THER


(linear thermics), MODE_MECA (modal analysis), ...

 At each computation step, one or more fields are stored in the


data structure resultat
 Fields are identified by access variables: INST, NUME_ORDRE, FREQ, NUME_MODE, ...

 Examples of stored fields


Temperatures for a list of time steps / Displacements for the first n modes
Displacements and stresses for a list of time steps
GNU FDL licence | code_aster, salome_meca course material 37
Outline

1. Introducing a simple study


2. Starting the study
Go
3. Data settings further !
4. Solving the problem
5. Post-processing the results
GNU FDL licence | code_aster, salome_meca course material
Go further

Redo this study with assistant

 Step 1: Choose the type of your study


GNU FDL licence | code_aster, salome_meca course material 39


Go further

Redo this study with assistante

 Step 2 : Edit et/or add commands


GNU FDL licence | code_aster, salome_meca course material 40


Go further

Analysis summary before the launch

 Verifier the data setting of the study

GNU FDL licence | code_aster, salome_meca course material 41


Go further

Calculation information

 Follow-up

GNU FDL licence | code_aster, salome_meca course material 42


Go further

Study with several stages

 Good practice for several cases:


 Analysis + Post-processing

 Thermal analysis + mechanical analysis

GNU FDL licence | code_aster, salome_meca course material 43


Go further

Calculation information

 Messages : find the error quickly (only redo post-processing)

GNU FDL licence | code_aster, salome_meca course material 44


Go further

Calculation information

 Messages : find the error quickly (only redo post-processing)

GNU FDL licence | code_aster, salome_meca course material 45


Go further

Results view in Post-Process

GNU FDL licence | code_aster, salome_meca course material 46


Go further

Access to other modules

 MESH: dynamic link

 (Post-Process =>)ParaVIS

 ADAO

 OpenTurns
 Variables

 One value (Table in Numpy format) => Launch to verfify

 (Click CurrentCase) Export to OpenTurns

GNU FDL licence | code_aster, salome_meca course material 47


End of presentation

Is something missing or unclear in this document?


Or feeling happy to have read such a clear tutorial?

Please, we welcome any feedbacks about Code_Aster training materials.


Do not hesitate to share with us your comments on the Code_Aster forum
dedicated thread.

GNU FDL licence | code_aster, salome_meca course material


Appendix

Special commands

 DEBUT command
 Begins execution, previous lines are ignored

 POURSUITE command
 Restarts execution from a database provided as an input
 Useful to continue a calculation initiated with the same version of code_aster
 Recommended to separate the calculation from the post-processing
Calculation: DEBUT() … FIN()
 FIN command Post-processing: POURSUITE() … FIN()
 Ends the command file and ends the run, following lines are ignored
 Closes the database at the end of execution
 Specifies the format used for the produced base: HDF or Aster

GNU FDL licence | code_aster, salome_meca course material 49


Appendix

Functions and time stepping

 Functions
 Define a real or complex function of a real variable

 Usually for the loading or boundary conditions, which depends on space or time
FUNC = DEFI_FONCTION( NOM_PARA = ‘Y’,
VALE = ( 0.0, 200000.0, 4.0, 0.0) )

 Time stepping
 Time list for the calculation

 Time management for the iterative algorithms


listr = DEFI_LIST_REEL( DEBUT = 0.0,
INTERVALLE = _F( JUSQU_A = 10.0,
NOMBRE = 10 ) )
time = DEFI_LIST_INST( DEFI_LIST = _F( LIST_INST = listr,) )

GNU FDL licence | code_aster, salome_meca course material 50

You might also like