Commit cd81d3bb authored by mozul's avatar mozul
Browse files

Squashed 'examples/' changes from da1441e..e5f8682

e5f8682 removing duplicate mur example
801823d Merge branch 'rc2015' of git-xen.lmgc.univ-montp2.fr:lmgc90/lmgc90_user_examples into rc2015
75681d7 update examples of Pre/prepro_grains for 2015 release
783cdf7 maj modele therm 3D
6c4b9fe maj modele elec
0de267e ajout mots cles manquant
d80b3dd Merge branch 'rc2015' of git-xen.lmgc.univ-montp2.fr:lmgc90/lmgc90_user_examples into rc2015
e5b8227 update display commands in rigid multi physics example for workshop
b9110d0 first update of Ateliers examples
acf58dc mise a jour des fct Ptr
b4b1e8f mise a jour des fct Ptr
580a96b first update of poro and therMAILx example
03ceb24 update mecaMAILx_RIGID_3D examples for 2015 release and add missing update of mecaMAILx_RIGID_2D
13255ca update mecaMAILx_RIGID_2D examples for 2015 release
d2b231c remove duplicate example script
b1c2a99 rename cubes_H8_explicit example in cubes_H8
50fb915 update mecaMAILx examples for 2015 release and remove cubes_H8 duplicate example
2ee408d update mecaMAILx_2D examples for 2015 release
2994047 update RIGID_3D examples for rev 2015 ddm and thermal not working yet
ea93075 update RIGID_2D example for new version

git-subtree-dir: examples
git-subtree-split: e5f8682eef4f74ebf9a107e233fb271cbdbf5035
parent bdefdcb1
......@@ -60,8 +60,6 @@ NewtonRaphson_SetBadIter(15)
NewtonRaphson_SetMaxIter(NR_nb_iter_max)
#
mecaMAILx_WithRenumbering()
### lecture du modele ###
utilities_logMes( 'READ BODIES')
MAILx_ReadBodies()
......
......@@ -32,8 +32,6 @@ overall_DIME(2, 1)
nlgs_SetWithQuickScramble()
mecaMAILx_WithRenumbering()
# Newton loop parameters:
NR_tol=1e-6
NewtonRaphson_SetFinalTime(t_final)
......
......@@ -87,12 +87,12 @@ mecaMAILx_ReadIniGPV()
TimeEvolution_ReadIniVlocRloc()
CLALp_ReadIniVlocRloc()
fim = startCollection('mecafe.pvd')
fii = startCollection('inters.pvd')
fim = startCollection(tmp+'DISPLAY/mecafe.pvd')
fii = startCollection(tmp+'DISPLAY/inters.pvd')
k=0
utilities_logMes('tact')
writeMecafeToVTK('./DISPLAY/mecafe'+'_'+str(k)+'.vtu',fim,2)
writeMecafeToVTK(tmp+'DISPLAY/mecafe'+'_'+str(k)+'.vtu',fim,2)
for k in xrange(min,max+1,1):
#
......@@ -109,13 +109,13 @@ for k in xrange(min,max+1,1):
mecaMAILx_ReadIniGPV()
utilities_logMes('tact')
writeMecafeToVTK('./DISPLAY/mecafe'+'_'+str(k)+'.vtu',fim,2)
writeMecafeToVTK(tmp+'DISPLAY/mecafe'+'_'+str(k)+'.vtu',fim,2)
TimeEvolution_ReadIniVlocRloc()
CLALp_ReadIniVlocRloc()
utilities_logMes('inter')
writeIntersToVTK('./DISPLAY/inters'+'_'+str(k)+'.vtp',fii,inters_dict,0.3e-1)
writeIntersToVTK(tmp+'DISPLAY/inters'+'_'+str(k)+'.vtp',fii,inters_dict,0.3e-1)
stopCollection(fim)
stopCollection(fii)
......
......@@ -48,8 +48,6 @@ TimeEvolution_SetTimeStep(dt)
Integrator_InitTheta(theta)
Integrator_SetContactDetectionConfiguration(1.-theta,0.)
mecaMAILx_WithRenumbering()
### lecture du modele ###
utilities_logMes('READ BODIES')
MAILx_ReadBodies()
......@@ -235,60 +233,10 @@ for k in xrange(1,nstep+1,1):
mecaMAILx_ComputeDof()
RBDY3_ComputeDof()
<<<<<<< .mine
#vector = mecaMAILx_GetBodyVector('Reac_', 1, 375)
#vector.shape=[125,3]
#coor = mecaMAILx_GetBodyVector('Coor_', 1, 375)
#coor.shape=[125,3]
#utilities_logMes('reaction nodale obtenue')
#i=1
#for fx,fy,fz in vector:
# if i > 25: break
# s=str(i)+' '+str(fx)+' '+str(fy)+' '+str(fz)+' '+str(coor[i-1,2])
# utilities_logMes(s)
# i+=1
## on initialise raux
#mecaMAILx_NullifyReac('Raux_',1)
#nb_CSPRx = CSPRx_GetNbCSPRx()
#utilities_logMes('nb CSPRx= '+str(nb_CSPRx))
#all = CSPRx_GetAll()
#for i in xrange(nb_CSPRx):
# info = CSPRx_GetInfo(i+1)
# icsxxx= int(info[2])
# #print icsxxx
# # r = fn n + ft t
# r = (all[i,3]*all[i,4:7]) + (all[i,7]*all[i,8:11])
#
# #print r
#
# #utilities_logMes(str(info[0])+' '+str(info[2]))
# #utilities_logMes('rn('+str(i)+')= '+str(all[i,3]))
#
# CSxxx_AddReac('Raux_',icsxxx,r)
#
#vector = mecaMAILx_GetBodyVector('Raux_', 1, 375)
#vector.shape=[125,3]
=======
vector = mecaMAILx_GetBodyVector('Reac_', 1)
vector.shape=[125,3]
>>>>>>> .r588
<<<<<<< .mine
#utilities_logMes('reaction auxiliaire obtenue avec re integration')
#i=1
#for fx,fy,fz in vector:
# if i > 25: break
# s=str(i)+' '+str(fx)+' '+str(fy)+' '+str(fz)
# utilities_logMes(s)
# i+=1
=======
coor = mecaMAILx_GetBodyVector('Coor_', 1)
coor.shape=[125,3]
>>>>>>> .r588
<<<<<<< .mine
=======
utilities_logMes('reaction nodale obtenue')
i=1
......@@ -331,7 +279,6 @@ for k in xrange(1,nstep+1,1):
utilities_logMes(s)
i+=1
>>>>>>> .r588
#
utilities_logMes('UPDATE DOF, FIELDS')
TimeEvolution_UpdateStep()
......
......@@ -44,8 +44,6 @@ TimeEvolution_SetTimeStep(dt)
Integrator_InitTheta(theta)
Integrator_SetContactDetectionConfiguration(1.-theta,0.)
mecaMAILx_WithRenumbering()
### lecture du modele ###
utilities_logMes('READ BODIES')
MAILx_ReadBodies()
......
......@@ -42,8 +42,7 @@ NewtonRaphson_SetMaxIter(NR_nb_iter_max)
# Initialize theta integrator
Integrator_InitTheta(theta)
mecaMAILx_WithRenumbering()
mecaMAILx_StdBandShape()
mecaMAILx_BandStorage()
### model reading ###
utilities_logMes('READ BODIES')
......
......@@ -28,8 +28,6 @@ utilities_logMes('INIT TIME STEPPING')
TimeEvolution_SetTimeStep(dt)
Integrator_InitTheta(theta)
mecaMAILx_WithRenumbering()
### lecture du modele ###
utilities_logMes('READ BODIES')
MAILx_ReadBodies()
......
......@@ -30,8 +30,6 @@ utilities_logMes('INIT TIME STEPPING')
TimeEvolution_SetTimeStep(dt)
Integrator_InitTheta(theta)
mecaMAILx_WithRenumbering()
### lecture du modele ###
utilities_logMes('READ BODIES')
MAILx_ReadBodies()
......
......@@ -16,8 +16,7 @@ dim=3
# modele
mod = model(name='TET__',type='MECAx',element='TE4xx',external_model='yes__',kinematic='small',
material='elas_',anisotropy='iso__',mass_storage='coher',
thermal_coupling='no___',dimension=dim)
material='elas_',anisotropy='iso__',mass_storage='coher', dimension=dim)
ms.addModel(mod)
# materiau
......
import os,sys
# chemin vers ChiPy
root_Pre='/Users/mrenouf/CODING/LMGC90/LMGC90v2_dev/ChiPy/lib/'
sys.path.append(root_Pre)
from pylmgc90.chipy import *
......@@ -21,6 +19,7 @@ echo = 0
# info generation fichier visu
freq_display = 50
ref_radius = 0.1e-2
# info contact
freq_detect = 1
......@@ -33,6 +32,8 @@ relax = 1.0
gs_it1 = 51
gs_it2 = 1001
SetDimension(2)
### definition des parametres du calcul ###
utilities_logMes('INIT TIME STEPPING')
TimeEvolution_SetTimeStep(dt)
......@@ -79,11 +80,7 @@ overall_WriteDrivenDof()
RBDY2_WriteDrivenDof()
### post2D ##
post2D_SetDisplayedField('CONTACT POINT ')
post2D_SetDisplayedField('TACTOR ')
post2D_SetDisplayedField('AVERAGE VELOCITY')
post2D_SetDisplayedField('STRESS ')
post2D_Init()
OpenDisplayFiles()
### postpro ###
postpro_PostproBeforeComputation()
......@@ -140,8 +137,7 @@ for k in xrange(1, nb_steps + 1, 1):
DKJCx_WriteLastVlocRloc()
#
### post2D ###
overall_WriteOutDisplayFile(freq_display)
post2D_WriteOutDisplayFile(0)
WriteDisplayFiles(freq_display,ref_radius)
### postpro ###
postpro_PostproDuringComputation()
......@@ -150,4 +146,5 @@ for k in xrange(1, nb_steps + 1, 1):
overall_CleanWriteOutFlags()
### postpro ###
CloseDisplayFiles()
postpro_ClosePostproFiles()
import os,sys
# chemin vers ChiPy
root_Pre='/Users/mrenouf/CODING/LMGC90/BUILDS/LMGC90v2_dev/lib/'
sys.path.append(root_Pre)
from pylmgc90.chipy import *
......@@ -96,8 +94,8 @@ InitTactorsToVTK(liste_tactors,tactors_dict)
inters_dict={}
InitIntersToVTK(liste_inters,inters_dict)
fit = startCollection('tacts.pvd')
fii = startCollection('inters.pvd')
fit = startCollection('DISPLAY/tacts.pvd')
fii = startCollection('DISPLAY/inters.pvd')
##################
......
import os,sys
sys.path.append('/Users/mrenouf/CODING/LMGC90/BUILDS/LMGC90v2_dev/lib')
from pylmgc90.chipy import *
checkDirectories()
......@@ -84,8 +82,8 @@ InitTactorsToVTK(liste_tactors,tactors_dict)
inters_dict={}
InitIntersToVTK(liste_inters,inters_dict)
fit = startCollection('tacts.pvd')
fii = startCollection('inters.pvd')
fit = startCollection('DISPLAY/tacts.pvd')
fii = startCollection('DISPLAY/inters.pvd')
##################
......
import os,sys
sys.path.append('/Users/mrenouf/CODING/LMGC90/BUILDS/LMGC90v2_dev/lib')
from pylmgc90.chipy import *
checkDirectories()
......@@ -85,8 +83,8 @@ InitTactorsToVTK(liste_tactors,tactors_dict)
inters_dict={}
InitIntersToVTK(liste_inters,inters_dict)
fit = startCollection('tacts.pvd')
fii = startCollection('inters.pvd')
fit = startCollection('DISPLAY/tacts.pvd')
fii = startCollection('DISPLAY/inters.pvd')
##################
......
......@@ -73,8 +73,8 @@ InitTactorsToVTK(['DISKx','JONCx'],tacts_dict)
inters_dict={}
InitIntersToVTK(['DKDKx','DKJCx'],inters_dict)
fit = startCollection('tacts.pvd')
fii = startCollection('inters.pvd')
fit = startCollection(tmp+'DISPLAY/tacts.pvd')
fii = startCollection(tmp+'DISPLAY/inters.pvd')
for k in xrange(min,max+1,1):
#
......@@ -93,9 +93,9 @@ for k in xrange(min,max+1,1):
DKDKx_ReadIniVlocRloc()
utilities_logMes('tact')
writeTactorsToVTK('./DISPLAY/tacts'+'_'+str(k)+'.vtp',fit,tacts_dict)
writeTactorsToVTK(tmp+'DISPLAY/tacts'+'_'+str(k)+'.vtp',fit,tacts_dict)
utilities_logMes('inter')
writeIntersToVTK('./DISPLAY/inters'+'_'+str(k)+'.vtp',fii,inters_dict,0.1)
writeIntersToVTK(tmp+'DISPLAY/inters'+'_'+str(k)+'.vtp',fii,inters_dict,0.1)
utilities_logMes('---')
stopCollection(fit)
......
......@@ -5,6 +5,9 @@ import math
from pylmgc90.pre_lmgc import *
if not os.path.isdir('./DATBOX'):
os.mkdir('./DATBOX')
# on se place en 2D
dim = 2
......
......@@ -17,6 +17,7 @@ echo = 0
# info generation fichier visu
freq_display = 50
ref_radius = 1.
# info contact
freq_detect = 1
......@@ -29,6 +30,7 @@ relax = 1.0
gs_it1 = 51
gs_it2 = 1001
SetDimension(2)
### definition des parametres du calcul ###
utilities_logMes('INIT TIME STEPPING')
TimeEvolution_SetTimeStep(dt)
......@@ -75,9 +77,7 @@ overall_WriteDrivenDof()
RBDY2_WriteDrivenDof()
### post2D ##
post2D_SetDisplayedField('CONTACT POINT')
post2D_SetDisplayedField('TACTOR')
post2D_Init()
OpenDisplayFiles()
utilities_logMes('COMPUTE MASS')
RBDY2_ComputeMass()
......@@ -130,7 +130,8 @@ for k in xrange(1, nb_steps + 1, 1):
DKJCx_WriteLastVlocRloc()
#
### post2D ###
overall_WriteOutDisplayFile(freq_display)
post2D_WriteOutDisplayFile(0)
WriteDisplayFiles(freq_display,ref_radius)
### wrtieout handling ###
overall_CleanWriteOutFlags()
CloseDisplayFiles()
......@@ -5,6 +5,9 @@ import math
from pylmgc90.pre_lmgc import *
if not os.path.isdir('./DATBOX'):
os.mkdir('./DATBOX')
# on se place en 2D
dim = 2
......
......@@ -8,7 +8,7 @@ checkDirectories()
utilities_DisableLogMes()
# a 3D example is considered
overall_DIME(3,0)
SetDimension(3)
### computation's parameters definition ###
utilities_logMes('INIT TIME STEPPING')
......@@ -24,6 +24,8 @@ nb_steps = 3000
freq_detect = 1
# * visualization frequency
freq_display = 50
ref_radius = 1.
# * frequence d'ecriture des fichier de sortie
freq_write = 50
# 123456789012345678901234567890
......@@ -83,22 +85,7 @@ RBDY3_WriteDrivenDof()
RBDY3_ComputeMass()
### post3D ##
# 1234567890123456
# definition of fields to be computed by the post3D module
post3D_SetDisplayedField('POSITION')
post3D_SetDisplayedField('AVERAGE VELOCITY')
post3D_SetDisplayedField('STRESS')
# initialization of the post3D module
post3D_Init()
# definition of another fields to be displayed by the display_3D module
display_3D_SetDisplayedField('TACTOR')
display_3D_SetDisplayedField('INTERACTION')
# initilization of the display_3D module
display_3D_Init(0)
# compute of a first visualization
#display_3D_WriteOutDisplayFile(0)
OpenDisplayFiles()
# time loop
for k in range(1, nb_steps + 1):
......@@ -143,10 +130,8 @@ for k in range(1, nb_steps + 1):
RBDY3_UpdateDof()
### post3D ###
post3D_Update()
WriteDisplayFiles(freq_display,ref_radius)
overall_WriteOutDisplayFile(freq_display)
display_3D_WriteOutDisplayFile(0)
TimeEvolution_WriteOutDof(freq_write)
RBDY3_WriteOutDof(-1,9999999)
......@@ -160,3 +145,5 @@ for k in range(1, nb_steps + 1):
TimeEvolution_WriteLastDof()
RBDY3_WriteLastDof()
CloseDisplayFiles()
......@@ -5,6 +5,9 @@ import math
from pylmgc90.pre_lmgc import *
if not os.path.isdir('./DATBOX'):
os.mkdir('./DATBOX')
# on se place en 3D
dim = 3
......
......@@ -17,6 +17,7 @@ echo = 0
# info generation fichier visu
freq_display = 50
ref_radius = 1.
# info contact
freq_detect = 1
......@@ -29,6 +30,7 @@ relax = 1.0
gs_it1 = 51
gs_it2 = 1001
SetDimension(2)
### definition des parametres du calcul ###
utilities_logMes('INIT TIME STEPPING')
TimeEvolution_SetTimeStep(dt)
......@@ -75,9 +77,7 @@ overall_WriteDrivenDof()
RBDY2_WriteDrivenDof()
### post2D ##
post2D_SetDisplayedField('CONTACT POINT ')
post2D_SetDisplayedField('TACTOR ')
post2D_Init()
OpenDisplayFiles()
utilities_logMes('COMPUTE MASS')
RBDY2_ComputeMass()
......@@ -130,7 +130,8 @@ for k in xrange(1, nb_steps + 1, 1):
DKJCx_WriteLastVlocRloc()
#
### post2D ###
overall_WriteOutDisplayFile(freq_display)
post2D_WriteOutDisplayFile(0)
WriteDisplayFiles(freq_display,ref_radius)
### wrtieout handling ###
overall_CleanWriteOutFlags()
CloseDisplayFiles()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment