Skip to content

Instantly share code, notes, and snippets.

Created February 13, 2017 17:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/f3ad42a0824657714d818ac81cc20838 to your computer and use it in GitHub Desktop.
Save anonymous/f3ad42a0824657714d818ac81cc20838 to your computer and use it in GitHub Desktop.
! --------- Paramètres géométriques [m] ---------
eps = 1e-8 ! tolerance for node select
L1 = 250E-6
W1 = 250E-6
TBOSSE = 200E-6
TMEMBRANE = 2E-6
! Keypoint definition
K, 1, 0, 0, 0
K, 2, L1, 0, 0
K, 3, 0, W1, 0
K, 4, L1, W1, 0
K, 5, 0,0, TMEMBRANE
K, 6, L1,0, TMEMBRANE
K, 7, 0,W1, TMEMBRANE
K, 8, L1, W1, TMEMBRANE
K, 9, 0,0, TMEMBRANE + TBOSSE
K, 10, L1,0, TMEMBRANE + TBOSSE
K, 11, 0,W1, TMEMBRANE + TBOSSE
K, 12, L1, W1, TMEMBRANE + TBOSSE
! Volumes
V, 1, 2, 4, 3, 5, 6, 8, 7 ! vol #1
V, 5, 6, 8, 7, 9, 10, 12, 11 ! vol #2
/ANGLE,,-90,XM
!/VCONE,,10
/TRIAD,LTOP
/PLOPTS,TITLE,0
/PLOPTS,MINM,0
/VIEW,,-1.5,1.2,2
VPLOT
! Line
L1DIV = 10
W1DIV = 10
Z1DIV = 1
Z2DIV = 4
! X-axis
LESIZE,1,,,L1DIV,
LESIZE,6,,,L1DIV,
LESIZE,3,,,L1DIV,
LESIZE,10,,,L1DIV,
LESIZE,14,,,L1DIV,
LESIZE,18,,,L1DIV,
! Y-axis
LESIZE,4,,,W1DIV,
LESIZE,12,,,W1DIV,
LESIZE,2,,,W1DIV,
LESIZE,8,,,W1DIV,
LESIZE,16,,,W1DIV,
LESIZE,20,,,W1DIV,
! Z-axis
LESIZE,5,,,Z1DIV,
LESIZE,9,,,Z1DIV,
LESIZE,7,,,Z1DIV,
LESIZE,11,,,Z1DIV,
LESIZE,13,,,Z2DIV,
LESIZE,15,,,Z2DIV,
LESIZE,17,,,Z2DIV,
LESIZE,19,,,Z2DIV,
! ----------- Propriétés du silicium <110>-------
MP, EX, 1, 168.956E9
MP, EY, 1, 168.956E9
MP, EZ, 1, 130.024E9
MP, NUXY, 1, 0.0625
MP, NUYZ, 1, 0.2785
MP, NUXZ, 1, 0.2785
MP, GXY, 1, 50.85E9
MP, GYZ, 1, 79.51E9
MP, GXZ, 1, 79.51E9
!MP, DENS, 1, 2320 ! densité du silicium
! ----------- Propriétés du 2ieme matière-------
MP, EX, 2, 2.5E9
MP, EY, 2, 2.5E9
MP, EZ, 2, 2.5E9
MP, NUXY, 2, 0.34
MP, NUYZ, 2, 0.34
MP, NUXZ, 2, 0.34
MP, GXY, 2, 10E9
MP, GYZ, 2, 10E9
MP, GXZ, 2, 10E9
!MP, DENS, 2, 2320 ! densité du 2ieme matière
! -------- Définition de l'élément type ---------
ET, 1, 186 ! silicium
ET, 2, 186 ! matière inconnue
MAT,1 ! PROPERTIES OF MATERIAL #1
TYPE,1 ! Activates an element type number to be assigned to subsequently defined elements.
VMESH,2
MAT,2 ! PROPERTIES OF MATERIAL #2
TYPE,2 ! Activates an element type number to be assigned to subsequently defined elements.
VMESH,1
EPLOT
FINISH
/SOLU
ANTYPE, STATIC
NLGEOM,ON ! inclure grandes déformations
SSTIF,OFF ! inclure stress stiffness effects
NROPT,AUTO ! Newton-Raphson par défaut
! DEFINE SYMMETRY PLANES
DOFSEL, S, U ! select a set (S) of displacements (U) degrees of freedom
NSEL,S,LOC,Y,-eps,eps ! y = 0 +- epsilon
DSYM,SYMM,Y
NSEL, ALL ! reselect all nodes
NSEL,S,LOC,X,-eps,eps ! y = 0 +- epsilon
DSYM,SYMM,X
NSEL, ALL ! reselect all nodes
DOFSEL, ALL ! reselect all DOF
! clamping
! NSEL = Node Selection
! S = new set
! LOC = location (x,y,z)
NSEL,S,LOC,Z,-eps,+eps ! bottom side
D, ALL, ALL, 0 ! Defines degree-of-freedom constraints at nodes.
NSEL, ALL ! reselect all nodes of the meshing
!NSEL,S,LOC,Y,(W1+W2)-eps,(W1+W2)+eps ! top side
!D, ALL, ALL, 0 ! Defines degree-of-freedom constraints at nodes.
!NSEL, ALL ! reselect all nodes of the meshing
F, NODE(0,0,TMEMBRANE + TBOSSE), FZ, -0.00075
SOLVE
FINISH
! *************************************************************
/POST1 ! post-processing step
PLNSOL, U, Z ! plot nodal solution, displacement (U) along z axis
LPATH, NODE(0,0,TMEMBRANE), NODE(L1, 0, TMEMBRANE) ! define a path between 2 nodes
PDEF, Z_DISPLACEMENT, U, Z ! path definition : name = Z_DISPLACEMENT, U = displacement, Z = along z axis
PLPATH, Z_DISPLACEMENT ! plot path
/OUTPUT,Z_DISPLA,TXT ! redirect output to file. File name is limited to 8 char
PRPATH, Z_DISPLACEMENT ! print path
/OUTPUT ! redirect output to screen
FINISH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment