List of nodes assigned to rigid Diaphragm
Moderators: silvia, selimgunay, Moderators
List of nodes assigned to rigid Diaphragm
Hello,
It is my first attempt to create a 3D model of a building and I have made lists of nodes according to floor level.
Then I tried setting rigid Diaphragm on each floor using the following command:
set perpDirn 2:
rigidDiaphragm $perpDirn [lindex $mn 0] [$dph1]
where $mn is a list containing the node Tags of all master nodes.
However, when I run it there is a warning saying: invalid command name "0 1 2 3 ...etc"
where "0 1 2 3 ...etc" are the node Tags included in the list $dph1
Is there a way to connect the node Tags of each list to its corresponding master node and thus to the corresponding diaphragm?
Thank you in advance!
It is my first attempt to create a 3D model of a building and I have made lists of nodes according to floor level.
Then I tried setting rigid Diaphragm on each floor using the following command:
set perpDirn 2:
rigidDiaphragm $perpDirn [lindex $mn 0] [$dph1]
where $mn is a list containing the node Tags of all master nodes.
However, when I run it there is a warning saying: invalid command name "0 1 2 3 ...etc"
where "0 1 2 3 ...etc" are the node Tags included in the list $dph1
Is there a way to connect the node Tags of each list to its corresponding master node and thus to the corresponding diaphragm?
Thank you in advance!
Re: List of nodes assigned to rigid Diaphragm
I am not familiar with the rigidDiaphragm command, but this looks like a tcl-scripting error. If I understand correctly, the programme tries to implement a command defined by string "0 1 2 ....". Since there's no such command, an error is encountered. You can either try to remove the brackets (write only $dph1) and see if the rigid diaphragm is correctly constructed, or use the lindex command, like you did with the $mn list.
Re: List of nodes assigned to rigid Diaphragm
When I remove the brackets and run the file there is a different warning saying:
WARNING rigidLink perpDirn rNode cNodes - could not read cNode
expected integer but got "0 1 2 3 ... etc"
Concerning the second option of using lindex command, I will practically use the same number of lindex commands as the numbers of the nodes inside the list. Therefore I will not take advantage of the list command which I created in order to avoid typing about 100 nodeTags.
Is there a way that I'm missing to use lindex command without having to type the command for each one individually (except the "foreach" command which I tried and didn't work)?
WARNING rigidLink perpDirn rNode cNodes - could not read cNode
expected integer but got "0 1 2 3 ... etc"
Concerning the second option of using lindex command, I will practically use the same number of lindex commands as the numbers of the nodes inside the list. Therefore I will not take advantage of the list command which I created in order to avoid typing about 100 nodeTags.
Is there a way that I'm missing to use lindex command without having to type the command for each one individually (except the "foreach" command which I tried and didn't work)?
Re: List of nodes assigned to rigid Diaphragm
By the sound of it, the slaveNodeTag argument accepts only variables and cannot discriminate the elements of a given list. The only solution that I can think of right now is to greadually construct the diaphragm, using multiple rigidDiaphragm commands. Put the command within a loop and use the lindex commnad for both master and slave nodes. The loop will go through all the elements of the dph list and you 'll have created the constraints individually for each node. Is this acceptable as a modelling principle?
Re: List of nodes assigned to rigid Diaphragm
you are passing a list and not a number of tags .. to make what you want work, puts the commmand inside an eval, i.e.:
eval "rigidDiaphragm $perpDirn [lindex $mn 0] $dph1"
eval "rigidDiaphragm $perpDirn [lindex $mn 0] $dph1"
Re: List of nodes assigned to rigid Diaphragm
Thank you so much for your time and your answers!
Problem solved with the eval command.
Have a nice day!
Problem solved with the eval command.
Have a nice day!