problem with block3D command

A forum dedicated to users with questions regarding soil materials and elements.

forum currently locked

Moderator: Moderators

Locked
shankartayal
Posts: 7
Joined: Tue Feb 08, 2011 1:25 am
Location: Bhubaneswar, India
Contact:

problem with block3D command

Post by shankartayal » Mon Aug 01, 2011 1:34 am

Hello
i am working on soil pile interaction problem considering soil as a 3D continuum. I am trying to develop a generalized tcl code for modelling and analysis of a single pile surrounded by soil. I am taking the geometry of soil and pile as variables. The soil around the pile is divided in 4 blocks which are connected later on.
But the problem is coming in block3D command. This is not recognizing the coordinates of the bbarbrick element which are substituted as variables which are defined above in the code.
Here is my code :

#wipe;
model basic -ndm 3 -ndf 3
file mkdir output;
#input parameter
#length of pile
set l_pile 10
#embeddment lenght of pile
set embed_pile 8
#no. of nodes in the pile = l_pile + 1
#diameter of pile
set d_pile 0.3

#soil parameters
#soil block geometry
#length of soil block
set l_soil 30
#depth of soil block
set d_soil 30
#meshing details
set x_mesh 2
set y_mesh 6
set z_mesh 2

#material definition
set matTag 1
set E 200000
set v 0.25
#mass density input is optional. default value is 0.
nDMaterial ElasticIsotropic $matTag $E $v

#node numbering
#initial node number
set node_num 1
set ele_num 1
set const_1 [expr ($x_mesh+1)*($y_mesh+1)*($z_mesh+1)]
set const_2 [expr $x_mesh*$y_mesh*$z_mesh]
#soil block 1
block3D $x_mesh $y_mesh $z_mesh $node_num $ele_num bbarBrick "1" {
1 [expr $d_pile/2.0] 0 0
2 [expr $d_pile/2+l_soil] 0 0
3 [expr $d_pile/2+l_soil] -$d_soil 0
4 [expr $d_pile/2] -$d_soil 0
5 0 0 [expr $d_pile/2]
6 0 0 [expr $d_pile/2+l_soil]
7 0 -$d_soil [expr $d_pile/2+l_soil]
8 0 -$d_soil [expr $d_pile/2]
9 [expr $d_pile/2.82] 0 [expr $d_pile/2.82]
12 [expr $d_pile/2.82] -$d_soil [expr $d_pile/2.82]
}

Please help me. I shall be really thankful.
Shankar Tayal
Undergraduate Student
School of Infrastructure
Indian Institute of Technology, Bhubaneswar
INDIA

fmk
Site Admin
Posts: 5883
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: problem with block3D command

Post by fmk » Mon Aug 08, 2011 1:43 pm

try setting a variable equal to the block command .. then eval the variable ..

set a "block ....

..
..
}"

eval $a

note: if you have quotes you need now inside the block you need to put a \ before the "
also l_soil needs to be replaced by $l_soil inside the block command.

Locked