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

You are not logged in.

## #1 2016-11-30 16:36:51

Abel_Jül
Member
Registered: 2016-11-30
Posts: 3

### Mapping of material properties

Hello everybody,

In the past I successfully used salome & code_aster for a femur bone model which was derived from CT data. Back then I segmented the bone into several parts depending on their grey-values and gave each group their respective Young's modulus & Poisson's ratio like shown below

[...]
bone_1=DEFI_MATERIAU(ELAS=_F(E=40,
NU=0.4,),);

bone_2=DEFI_MATERIAU(ELAS=_F(E=300,
NU=0.4,),);

bone_3=DEFI_MATERIAU(ELAS=_F(E=900,
NU=0.4,),);

bone_4=DEFI_MATERIAU(ELAS=_F(E=3300,
NU=0.4,),);

bone_5=DEFI_MATERIAU(ELAS=_F(E=15000,
NU=0.4,),);

MODELE=FEMLin,
AFFE=(_F(GROUP_MA=('VLow1','VLow2','VLow3',),
MATER=bone_2,),
_F(GROUP_MA='Low',
MATER=bone_3,),
_F(GROUP_MA=('Medium1','Medium2',),
MATER=bone_4,),
_F(GROUP_MA='High',
MATER=bone_5,),
_F(GROUP_MA='PMMA',
MATER=bone_4,),),);
[...]

This method worked but also came with the loss of a lot of information due to the smoothing necessary to create usable geometries.

The alternative I found is the "direct" mapping of material properties on a mesh (for example through programs like Bonemat) oftentimes used with commerical programs like Abaqus.

Is there a way to do this with Salome & Code_Aster? I have a sample geometry containing 64612 tetrahedrons and a corresponding scalar field with a grey value (which corresponds to a Young's Modulus) for each tetrahedron.

In comparison to my "old" way I'd require a way to make every single element a group itself with its own material properties.

best regards
Alexander

Offline

## #2 2016-11-30 21:53:28

RichardS
Member
From: Munich, Germany
Registered: 2010-09-28
Posts: 550
Website

### Re: Mapping of material properties

Hello Alexander,
very interesting project! Also not a trivial task....
I see one possibility using a fake thermomechanical analysis:

1. read the material data with LIRE_RESU (assuming its already in a proper format (UNV)) or  directly create a field with the help of CREA_CHAMP and probably some python to create/insert the right value per element
2. convert the element data field to a nodal field with CREA_CHAMP/DISC (you will need this and I guess for that many elements the error you introduce is negligable)
3. convert the field to a temperature field TEMP_NOEU (again with crea_champ).
4. As material use a fake thermomechanical material with E being a function (with ELAS_FO), namely E=T, use ZERO as thermal expansion coefficient.
5. In AFFE_MATERIAU use AFFE_VARC to define the initial field of your Youngs Modulus as temperature field
6. Run your normal mechanical study

I never tried this, so I am not sure if it works. You probably should validate the method first on a simple example where you know the analytical solution.

Let me know how it goes!

Best,
Richard

Richard Szoeke-Schuller
Product Management
www.simscale.com
We are hiring! https://simscale-jobs.personio.de/?language=en#all

Offline

## #3 2016-12-01 14:12:53

Abel_Jül
Member
Registered: 2016-11-30
Posts: 3

### Re: Mapping of material properties

Thanks for your interesting idea Richard,

I started to try things out and will report back once I figure out more.

Offline

## #4 2017-01-09 11:37:21

Abel_Jül
Member
Registered: 2016-11-30
Posts: 3

### Re: Mapping of material properties

Update: In the end I tried to "brute force" the issue and just wrote a python script which created my mesh with a single group for every element. Another script to write the corresponding .comm file.

In the end I got the following error:
!------------------------------------------------------------------------------------------------!
! <EXCEPTION> <CALCULEL6_11>                                                                     !
!                                                                                                !
!   Erreur d'utilisation :                                                                       !
!     Vous avez dépassé une des limites de la programmation concernant les champs de matériaux : !
!     On ne pas utiliser plus de 9999 matériaux différents                                       !
!------------------------------------------------------------------------------------------------!

This seems to be a rather random restriction? Is there anything I could try to get around this? Perhabs the fake thermomechanical analysis RichardS suggested is the way to go after all? I didn't get very far with that way in the beginning due to the wrong format of my material data.

Best regards,
Alexander

Attachments:

Offline

## #5 2017-01-09 11:43:38

RichardS
Member
From: Munich, Germany
Registered: 2010-09-28
Posts: 550
Website

### Re: Mapping of material properties

Hi Alexander,
I think there is no way around the 9999 materials limit (probably an internal memory allocation only allows 4 digits here, and you don't want to mess around with that...).

It's not really a fake thermomechanical analysis, rather using a feature that was initially implemented for those kind of analyses. It's actually easier as it probably sounded by my explanation. This solution is also presented with the last example in this document: http://code-aster.org/doc/default/en/ma … .43.03.pdf

Best,
Richard

Richard Szoeke-Schuller
Product Management
www.simscale.com
We are hiring! https://simscale-jobs.personio.de/?language=en#all

Offline

## #6 2019-11-22 12:17:03

GPSalachs
Member
Registered: 2018-03-10
Posts: 146

### Re: Mapping of material properties

Hello,

from the date of this thread seems a little old but due to the fact that the arguments implementation interests me and don't want to recreate a thread i post here. Have you had any kind of advancement regarding the material properties mapping procedure?

Thank you!

Offline