[Kratos] Fwd: New proposed auxiliar file for constitutive laws

maireni en cimne.upc.edu maireni en cimne.upc.edu
Mie Jun 2 16:56:50 CEST 2010


 

Hello all, 

I attach the file where I propose
the modality for the
constitutive laws. 

It is not completed, we need to verify wich
constitutive laws WORKS. 

Regard 

Nelson 

 
------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: http://listas.cimne.upc.edu/pipermail/kratos/attachments/20100602/8937d54e/attachment.htm 
------------ próxima parte ------------
import os, sys

#importing the Kratos Library
from Kratos import *
from KratosStructuralApplication import *


class Materials:

  def __init__(self, properties):
	self.Properties = properties; 

  def AssignMaterial(self.Properties):

     # materiales con leyes elasticas. Faltaria Ortotrpic y anisotropic en 2D y 3D

     prop_id = 1;
     prop_1 = Properties(prop_id)
     prop_1.SetValue(DENSITY,       0.000);
     prop_1.SetValue(POISSON_RATIO, 0.000);
     prop_1.SetValue(YOUNG_MODULUS, 0.000); 
     prop_1.SetValue(THICKNESS,     0.000);   
     prop_1.SetValue(BODY_FORCE_X,  0.000);
     prop_1.SetValue(BODY_FORCE_Y,  0.000);
     prop_1.SetValue(BODY_FORCE_Z,  0.000);
     mat_1 = Isotropic2D();
    
     #******************************************************************************************************************* 
     #*******************************************************************************************************************     
   
     prop_id = 2;
     prop_2 = Properties(prop_id)
     prop_2.SetValue(DENSITY,       0.000);
     prop_2.SetValue(POISSON_RATIO, 0.000);
     prop_2.SetValue(YOUNG_MODULUS, 0.000);
     prop_1.SetValue(THICKNESS,     1.000);   
     prop_2.SetValue(BODY_FORCE_X,  0.000);
     prop_2.SetValue(BODY_FORCE_Y,  0.000);
     prop_2.SetValue(BODY_FORCE_Z,  0.000);
     mat_2 = PlaneStrain();
      
     #******************************************************************************************************************* 
     #*******************************************************************************************************************     
   
     prop_id = 3;
     prop_3 = Properties(prop_id)
     prop_3.SetValue(DENSITY,       0.000);
     prop_3.SetValue(POISSON_RATIO, 0.000);
     prop_3.SetValue(YOUNG_MODULUS, 0.000);
     prop_3.SetValue(BODY_FORCE_X,  0.000);
     prop_3.SetValue(BODY_FORCE_Y,  0.000);
     prop_.SetValue(BODY_FORCE_Z,  0.000);
     mat_3 = Isotropic3D();
     
#******************************************************************************************************************* 
#*******************************************************************************************************************    
    
    # materiales no lineales Isotropos
    # Criterios de fluencia disponibles:
       # a) Von Mises------ VM  (VonMissesYieldFunction)
       # b) Druker Prager---DP  (DruckerPragerYieldFunction)
       # c) Rankine---------RN  (RankineYieldFunction )
       # d) Energia---------EN  (EnergyYieldFunction)
       # e) Morh-Colulomb---MC  (ModifiedMorhCoulombYieldFunction)
       
    # Ablandamiemtos Disponibles:
       # a) Linear------LN  (LinearSoftening)
       # b) Exponencial-EP  (ExponentialSoftening)
       

   # Estados Disponibles:
       # a) Plane_Stress----- PSS
       # b) Plane_Strain----- PSN
       # c) Tri_D------------ TRD
       # d) Axisimetrico----- AXI

   # Tipo de Fujo Disponibles:
       # a) Asociado AS
       # b) Asociado NS
       
   # Combinaciones disponibles en Kratos de criterios de fluencia
       # VM  (PSN,  AS)
       # VM  (TRD,  AS)
       #*********************
       # DP  (PSN)
       # DP  (TRD)
       #*********************
       # MC  (PSN, AS) 
       # MC  (PSN, NS)
       # MC  (TRD, AS)
       # MC  (TRD, NA)
       #*********************       
       #EN (PSS) 
       #EN (PSN) 
       #EN (TRD) 
       #********************* 
       #RN(PSS)
       #RN(PSN)
       #RN(TRD)
 
   # Ejemplos
   # Parametros de los criterios de fluencia
       #fluency_1  =  EnergyYieldFunction(myState.Plane_Stress);
       #fluency_1  =  VonMissesYieldFunction(myState.Plane_Stress, myPotencialPlastic.Associated);  
       #fluency_1  =  DruckerPragerYieldFunction(myState.Plane_Stress); 
       #fluency_1  =  ModifiedMorhCoulombYieldFunction(myState.Plane_Strain, myPotencialPlastic.Not_Associated)
       #fluency_1  =  RankineYieldFunction(myState.Tri_D)
       #fluency_1  =  DruckerPragerYieldFunction(myState.Plane_Stress)


   #Funcion de Ablandamiento a usar
       #behavior_1 = LinealSoftening() 
       #behavior_1 = ExponentialSoftening()  
       

    # Modelo de Daño Isotropo.

     prop_id = 4;
     prop_4 = Properties(prop_id)
     prop_4.SetValue(FRACTURE_ENERGY,0.000);
     prop_4.SetValue(CRUSHING_ENERGY,0.000);
     prop_4.SetValue(DENSITY,        0.000;
     prop_4.SetValue(POISSON_RATIO,  0.000);
     prop_4.SetValue(FC,             0.000);
     prop_4.SetValue(FT,             0.000);
     prop_4.SetValue(YOUNG_MODULUS,  0.000);
     prop_4.SetValue(THICKNESS,      0.000);
     prop_4.SetValue(BODY_FORCE_X,   0.000);
     prop_4.SetValue(BODY_FORCE_Y,   0.000);
     prop_4.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_4  =  EnergyYieldFunction(myState.Plane_Stress); 
     behavior_4 =  ExponentialSoftening() 
     mat_4      = Isotropic_Damage(fluency_4, behavior_4, prop_4) 
     

#******************************************************************************************************************* 
#******************************************************************************************************************* 

     prop_id = 5;
     prop_5 = Properties(prop_1d)
     prop_5.SetValue(FRACTURE_ENERGY,0.000);
     prop_5.SetValue(CRUSHING_ENERGY,0.000);
     prop_5.SetValue(DENSITY,        0.000;
     prop_5.SetValue(POISSON_RATIO,  0.000);
     prop_5.SetValue(FC,             0.000);
     prop_5.SetValue(FT,             0.000);
     prop_5.SetValue(YOUNG_MODULUS,  0.000);
     prop_5.SetValue(THICKNESS,      0.000);
     prop_5.SetValue(BODY_FORCE_X,   0.000);
     prop_5.SetValue(BODY_FORCE_Y,   0.000);
     prop_5.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_5  =  EnergyYieldFunction(myState.Tri_D); 
     behavior_5 =  ExponentialSoftening()   
     mat_5      =  Isotropic_Damage_3D(fluency_5, behavior_5, prop_5) 
     

#******************************************************************************************************************* 
#******************************************************************************************************************* 

     prop_id = 6;
     prop_6 = Properties(prop_1d)
     prop_6.SetValue(FRACTURE_ENERGY,0.000);
     prop_6.SetValue(CRUSHING_ENERGY,0.000);
     prop_6.SetValue(DENSITY,        0.000;
     prop_6.SetValue(POISSON_RATIO,  0.000);
     prop_6.SetValue(FC,             0.000);
     prop_6.SetValue(FT,             0.000);
     prop_6.SetValue(YOUNG_MODULUS,  0.000);
     prop_6.SetValue(THICKNESS,      0.000);
     prop_6.SetValue(BODY_FORCE_X,   0.000);
     prop_6.SetValue(BODY_FORCE_Y,   0.000);
     prop_6.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_6  =  EnergyYieldFunction(myState.Plane_Stress); 
     behavior_6 =  LinearSoftening() 
     mat_6      = Isotropic_Damage(fluency_6, behavior_6, prop_6) 
     

#******************************************************************************************************************* 
#******************************************************************************************************************* 

     prop_id = 7;
     prop_7 = Properties(prop_1d)
     prop_7.SetValue(FRACTURE_ENERGY,0.000);
     prop_7.SetValue(CRUSHING_ENERGY,0.000);
     prop_7.SetValue(DENSITY,        0.000;
     prop_7.SetValue(POISSON_RATIO,  0.000);
     prop_7.SetValue(FC,             0.000);
     prop_7.SetValue(FT,             0.000);
     prop_7.SetValue(YOUNG_MODULUS,  0.000);
     prop_7.SetValue(THICKNESS,      0.000);
     prop_7.SetValue(BODY_FORCE_X,   0.000);
     prop_7.SetValue(BODY_FORCE_Y,   0.000);
     prop_7.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_7  =  EnergyYieldFunction(myState.Tri_D); 
     behavior_7 =  LinearSoftening()   
     mat_7      =  Isotropic_Damage_3D(fluency_7, behavior_7, prop_7) 






#Definicion de las propiedades de los compuestos
#damage_prop_1 = Properties(2)
#damage_prop_1.SetValue(FRACTURE_ENERGY,0.001);
#damage_prop_1.SetValue(CRUSHING_ENERGY,26);
#damage_prop_1.SetValue(DENSITY,2.45E-6);
#damage_prop_1.SetValue(POISSON_RATIO, 0.2);
#damage_prop_1.SetValue(FC, 60);
#damage_prop_1.SetValue(FT, 20);
#damage_prop_1.SetValue(YOUNG_MODULUS, 3.5E5);
#damage_prop_1.SetValue(THICKNESS, 1.00);
#damage_prop_1.SetValue(MAX_FRICTION_INTERNAL_ANGLE,30);
#damage_prop_1.SetValue(MAX_DILATANCY_ANGLE, 30);


#prop_1 = Properties(1)
#prop_1.SetValue(DENSITY,2.45E-6);
#prop_1.SetValue(POISSON_RATIO, 0.2);
#prop_1.SetValue(YOUNG_MODULUS, 10E6);
#prop_1.SetValue(THICKNESS, 1.00);

##damage_prop_1.SetValue(CONCRETE_YOUNG_MODULUS_C, 3.5E5);
##damage_prop_1.SetValue(CONCRETE_YOUNG_MODULUS_T, 3.5E5);

##damage_prop_1.SetValue(COHESION, 57.735026918962);
##damage_prop_1.SetValue(FRICTION_INTERNAL_ANGLE, 30);


##damage_prop_1.SetValue(YIELD_STRESS, 5);
##damage_prop_1.SetValue(ISOTROPIC_HARDENING_MODULUS, 0.00);
##damage_prop_1.SetValue(KINEMATIC_HARDENING_MODULUS, 0.000);




##damage_prop_1.SetValue(BODY_FORCE_X, 0.00000);
##damage_prop_1.SetValue(BODY_FORCE_Y, 0.00000);
##damage_prop_1.SetValue(BODY_FORCE_Z, 0.00000);


## definicion de los materiales bases a usar
##Mat_1 = Isotropic_Damage(fluency_1,behavior_1,damage_prop_1) 
##Mat_1 = Plasticity2D(fluency_1,behavior_1,damage_prop_1) 
#Mat_2 = PlasticDamage3D(fluency_1, behavior_1, damage_prop_1)
#Mat_1 = Isotropic3D()
##Mat_1 = PlaneStressJ2()
##Mat_1 = Isotropic2D()
------------ próxima parte ------------
import os, sys

#importing the Kratos Library
from Kratos import *
from KratosStructuralApplication import *


class Materials:

  def __init__(self, properties):
	self.Properties = properties; 

  def AssignMaterial(self.Properties):

     # materiales con leyes elasticas. Faltaria Ortotrpic y anisotropic en 2D y 3D

     prop_id = 1;
     prop_1 = Properties(prop_id)
     prop_1.SetValue(DENSITY,       0.000);
     prop_1.SetValue(POISSON_RATIO, 0.000);
     prop_1.SetValue(YOUNG_MODULUS, 0.000); 
     prop_1.SetValue(THICKNESS,     0.000);   
     prop_1.SetValue(BODY_FORCE_X,  0.000);
     prop_1.SetValue(BODY_FORCE_Y,  0.000);
     prop_1.SetValue(BODY_FORCE_Z,  0.000);
     mat_1 = Isotropic2D();
    
     #******************************************************************************************************************* 
     #*******************************************************************************************************************     
   
     prop_id = 2;
     prop_2 = Properties(prop_id)
     prop_2.SetValue(DENSITY,       0.000);
     prop_2.SetValue(POISSON_RATIO, 0.000);
     prop_2.SetValue(YOUNG_MODULUS, 0.000);
     prop_1.SetValue(THICKNESS,     1.000);   
     prop_2.SetValue(BODY_FORCE_X,  0.000);
     prop_2.SetValue(BODY_FORCE_Y,  0.000);
     prop_2.SetValue(BODY_FORCE_Z,  0.000);
     mat_2 = PlaneStrain();
      
     #******************************************************************************************************************* 
     #*******************************************************************************************************************     
   
     prop_id = 3;
     prop_3 = Properties(prop_id)
     prop_3.SetValue(DENSITY,       0.000);
     prop_3.SetValue(POISSON_RATIO, 0.000);
     prop_3.SetValue(YOUNG_MODULUS, 0.000);
     prop_3.SetValue(BODY_FORCE_X,  0.000);
     prop_3.SetValue(BODY_FORCE_Y,  0.000);
     prop_.SetValue(BODY_FORCE_Z,  0.000);
     mat_3 = Isotropic3D();
     
#******************************************************************************************************************* 
#*******************************************************************************************************************    
    
    # materiales no lineales Isotropos
    # Criterios de fluencia disponibles:
       # a) Von Mises------ VM  (VonMissesYieldFunction)
       # b) Druker Prager---DP  (DruckerPragerYieldFunction)
       # c) Rankine---------RN  (RankineYieldFunction )
       # d) Energia---------EN  (EnergyYieldFunction)
       # e) Morh-Colulomb---MC  (ModifiedMorhCoulombYieldFunction)
       
    # Ablandamiemtos Disponibles:
       # a) Linear------LN  (LinearSoftening)
       # b) Exponencial-EP  (ExponentialSoftening)
       

   # Estados Disponibles:
       # a) Plane_Stress----- PSS
       # b) Plane_Strain----- PSN
       # c) Tri_D------------ TRD
       # d) Axisimetrico----- AXI

   # Tipo de Fujo Disponibles:
       # a) Asociado AS
       # b) Asociado NS
       
   # Combinaciones disponibles en Kratos de criterios de fluencia
       # VM  (PSN,  AS)
       # VM  (TRD,  AS)
       #*********************
       # DP  (PSN)
       # DP  (TRD)
       #*********************
       # MC  (PSN, AS) 
       # MC  (PSN, NS)
       # MC  (TRD, AS)
       # MC  (TRD, NA)
       #*********************       
       #EN (PSS) 
       #EN (PSN) 
       #EN (TRD) 
       #********************* 
       #RN(PSS)
       #RN(PSN)
       #RN(TRD)
 
   # Ejemplos
   # Parametros de los criterios de fluencia
       #fluency_1  =  EnergyYieldFunction(myState.Plane_Stress);
       #fluency_1  =  VonMissesYieldFunction(myState.Plane_Stress, myPotencialPlastic.Associated);  
       #fluency_1  =  DruckerPragerYieldFunction(myState.Plane_Stress); 
       #fluency_1  =  ModifiedMorhCoulombYieldFunction(myState.Plane_Strain, myPotencialPlastic.Not_Associated)
       #fluency_1  =  RankineYieldFunction(myState.Tri_D)
       #fluency_1  =  DruckerPragerYieldFunction(myState.Plane_Stress)


   #Funcion de Ablandamiento a usar
       #behavior_1 = LinealSoftening() 
       #behavior_1 = ExponentialSoftening()  
       

    # Modelo de Daño Isotropo.

     prop_id = 4;
     prop_4 = Properties(prop_id)
     prop_4.SetValue(FRACTURE_ENERGY,0.000);
     prop_4.SetValue(CRUSHING_ENERGY,0.000);
     prop_4.SetValue(DENSITY,        0.000;
     prop_4.SetValue(POISSON_RATIO,  0.000);
     prop_4.SetValue(FC,             0.000);
     prop_4.SetValue(FT,             0.000);
     prop_4.SetValue(YOUNG_MODULUS,  0.000);
     prop_4.SetValue(THICKNESS,      0.000);
     prop_4.SetValue(BODY_FORCE_X,   0.000);
     prop_4.SetValue(BODY_FORCE_Y,   0.000);
     prop_4.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_4  =  EnergyYieldFunction(myState.Plane_Stress); 
     behavior_4 =  ExponentialSoftening() 
     mat_4      = Isotropic_Damage(fluency_4, behavior_4, prop_4) 
     

#******************************************************************************************************************* 
#******************************************************************************************************************* 

     prop_id = 5;
     prop_5 = Properties(prop_1d)
     prop_5.SetValue(FRACTURE_ENERGY,0.000);
     prop_5.SetValue(CRUSHING_ENERGY,0.000);
     prop_5.SetValue(DENSITY,        0.000;
     prop_5.SetValue(POISSON_RATIO,  0.000);
     prop_5.SetValue(FC,             0.000);
     prop_5.SetValue(FT,             0.000);
     prop_5.SetValue(YOUNG_MODULUS,  0.000);
     prop_5.SetValue(THICKNESS,      0.000);
     prop_5.SetValue(BODY_FORCE_X,   0.000);
     prop_5.SetValue(BODY_FORCE_Y,   0.000);
     prop_5.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_5  =  EnergyYieldFunction(myState.Tri_D); 
     behavior_5 =  ExponentialSoftening()   
     mat_5      =  Isotropic_Damage_3D(fluency_5, behavior_5, prop_5) 
     

#******************************************************************************************************************* 
#******************************************************************************************************************* 

     prop_id = 6;
     prop_6 = Properties(prop_1d)
     prop_6.SetValue(FRACTURE_ENERGY,0.000);
     prop_6.SetValue(CRUSHING_ENERGY,0.000);
     prop_6.SetValue(DENSITY,        0.000;
     prop_6.SetValue(POISSON_RATIO,  0.000);
     prop_6.SetValue(FC,             0.000);
     prop_6.SetValue(FT,             0.000);
     prop_6.SetValue(YOUNG_MODULUS,  0.000);
     prop_6.SetValue(THICKNESS,      0.000);
     prop_6.SetValue(BODY_FORCE_X,   0.000);
     prop_6.SetValue(BODY_FORCE_Y,   0.000);
     prop_6.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_6  =  EnergyYieldFunction(myState.Plane_Stress); 
     behavior_6 =  LinearSoftening() 
     mat_6      = Isotropic_Damage(fluency_6, behavior_6, prop_6) 
     

#******************************************************************************************************************* 
#******************************************************************************************************************* 

     prop_id = 7;
     prop_7 = Properties(prop_1d)
     prop_7.SetValue(FRACTURE_ENERGY,0.000);
     prop_7.SetValue(CRUSHING_ENERGY,0.000);
     prop_7.SetValue(DENSITY,        0.000;
     prop_7.SetValue(POISSON_RATIO,  0.000);
     prop_7.SetValue(FC,             0.000);
     prop_7.SetValue(FT,             0.000);
     prop_7.SetValue(YOUNG_MODULUS,  0.000);
     prop_7.SetValue(THICKNESS,      0.000);
     prop_7.SetValue(BODY_FORCE_X,   0.000);
     prop_7.SetValue(BODY_FORCE_Y,   0.000);
     prop_7.SetValue(BODY_FORCE_Z,   0.000);  
     fluency_7  =  EnergyYieldFunction(myState.Tri_D); 
     behavior_7 =  LinearSoftening()   
     mat_7      =  Isotropic_Damage_3D(fluency_7, behavior_7, prop_7) 






#Definicion de las propiedades de los compuestos
#damage_prop_1 = Properties(2)
#damage_prop_1.SetValue(FRACTURE_ENERGY,0.001);
#damage_prop_1.SetValue(CRUSHING_ENERGY,26);
#damage_prop_1.SetValue(DENSITY,2.45E-6);
#damage_prop_1.SetValue(POISSON_RATIO, 0.2);
#damage_prop_1.SetValue(FC, 60);
#damage_prop_1.SetValue(FT, 20);
#damage_prop_1.SetValue(YOUNG_MODULUS, 3.5E5);
#damage_prop_1.SetValue(THICKNESS, 1.00);
#damage_prop_1.SetValue(MAX_FRICTION_INTERNAL_ANGLE,30);
#damage_prop_1.SetValue(MAX_DILATANCY_ANGLE, 30);


#prop_1 = Properties(1)
#prop_1.SetValue(DENSITY,2.45E-6);
#prop_1.SetValue(POISSON_RATIO, 0.2);
#prop_1.SetValue(YOUNG_MODULUS, 10E6);
#prop_1.SetValue(THICKNESS, 1.00);

##damage_prop_1.SetValue(CONCRETE_YOUNG_MODULUS_C, 3.5E5);
##damage_prop_1.SetValue(CONCRETE_YOUNG_MODULUS_T, 3.5E5);

##damage_prop_1.SetValue(COHESION, 57.735026918962);
##damage_prop_1.SetValue(FRICTION_INTERNAL_ANGLE, 30);


##damage_prop_1.SetValue(YIELD_STRESS, 5);
##damage_prop_1.SetValue(ISOTROPIC_HARDENING_MODULUS, 0.00);
##damage_prop_1.SetValue(KINEMATIC_HARDENING_MODULUS, 0.000);




##damage_prop_1.SetValue(BODY_FORCE_X, 0.00000);
##damage_prop_1.SetValue(BODY_FORCE_Y, 0.00000);
##damage_prop_1.SetValue(BODY_FORCE_Z, 0.00000);


## definicion de los materiales bases a usar
##Mat_1 = Isotropic_Damage(fluency_1,behavior_1,damage_prop_1) 
##Mat_1 = Plasticity2D(fluency_1,behavior_1,damage_prop_1) 
#Mat_2 = PlasticDamage3D(fluency_1, behavior_1, damage_prop_1)
#Mat_1 = Isotropic3D()
##Mat_1 = PlaneStressJ2()
##Mat_1 = Isotropic2D()


More information about the Kratos mailing list