Nodal Coordinate
Moderators: silvia, selimgunay, Moderators
-
- Posts: 7
- Joined: Fri Dec 04, 2009 6:21 pm
- Location: UCI
- Contact:
Nodal Coordinate
Hi all,
Can I have an output file (made by recorder) from opensees that contains only nodal information as follows:
Node number- X,Y and Z coordinate of nodes
Thanks
Peyman
Can I have an output file (made by recorder) from opensees that contains only nodal information as follows:
Node number- X,Y and Z coordinate of nodes
Thanks
Peyman
here is what frank has about the print command:
Print Command
From OpenSeesWiki
Jump to: navigation, search
This command is used to print output.
To print all objects of the domain:
print <$fileName>
To print node information:
print <$fileName> -node <-flag $flag> <$node1 $node2 ...>
To print element information:
print <$fileName> -ele <-flag $flag> <$ele1 $ele2 ...>
--------------------------------------------------------------------------------
$fileName (optional) name of file to which data will be sent. overwrites existing file. default is to print to stderr)
$flag integer flag to be sent to the print() method, depending on the node and element type (optional)
$node1 $node2 .. (optional) integer tags of nodes to be printed. default is to print all.
$ele1 $ele2 .. (optional) integer tags of elements to be printed. default is to print all.
EXAMPLE:
print -ele; # print all elemenmts
print -node 1 2 3; # print data for nodes 1,2 & 3
Print Command
From OpenSeesWiki
Jump to: navigation, search
This command is used to print output.
To print all objects of the domain:
print <$fileName>
To print node information:
print <$fileName> -node <-flag $flag> <$node1 $node2 ...>
To print element information:
print <$fileName> -ele <-flag $flag> <$ele1 $ele2 ...>
--------------------------------------------------------------------------------
$fileName (optional) name of file to which data will be sent. overwrites existing file. default is to print to stderr)
$flag integer flag to be sent to the print() method, depending on the node and element type (optional)
$node1 $node2 .. (optional) integer tags of nodes to be printed. default is to print all.
$ele1 $ele2 .. (optional) integer tags of elements to be printed. default is to print all.
EXAMPLE:
print -ele; # print all elemenmts
print -node 1 2 3; # print data for nodes 1,2 & 3
Silvia Mazzoni, PhD
Structural Consultant
Degenkolb Engineers
235 Montgomery Street, Suite 500
San Francisco, CA. 94104
Structural Consultant
Degenkolb Engineers
235 Montgomery Street, Suite 500
San Francisco, CA. 94104
-
- Posts: 7
- Joined: Fri Dec 04, 2009 6:21 pm
- Location: UCI
- Contact:
-
- Posts: 71
- Joined: Fri Nov 06, 2009 6:40 am
- Location: Universidad del Norte, Colombia
-
- Posts: 71
- Joined: Fri Nov 06, 2009 6:40 am
- Location: Universidad del Norte, Colombia
I'm glad to hear that, Silvia.
Hi Peyman... If you have an unix-based system, then you can use the following script-line at the end of your model file.
exec bash -c { while read line; do if [[ $(echo $line | awk '{print $1}') == node ]]; then echo $line >> nodesFile.out; fi done < modelFile.tcl }
Instructions:
1. Replace the word modelFile.tcl by the path of your model file.
2. Replace the word nodesFile.out by the path of your 'nodes file' (this is the output file).
For example,
- Path of your model file: /Users/hresquivelo/modelFile.tcl.
- Path of your 'nodes file': /Users/hresquivelo/nodesFile.out.
Assumptions:
1. There's not spaces before the definition of command node. I mean,
(incorrect)
.... node 1 0.00 0.00 (suppose that dots are spaces)
(correct)
node 1 0.00 0.00
2. If command node is defined inside a logical-loop statement, then it will not work as expected.
The best way is to make a c++ code.
>> Let me know if that works for you. <<
Regards,
Hi Peyman... If you have an unix-based system, then you can use the following script-line at the end of your model file.
exec bash -c { while read line; do if [[ $(echo $line | awk '{print $1}') == node ]]; then echo $line >> nodesFile.out; fi done < modelFile.tcl }
Instructions:
1. Replace the word modelFile.tcl by the path of your model file.
2. Replace the word nodesFile.out by the path of your 'nodes file' (this is the output file).
For example,
- Path of your model file: /Users/hresquivelo/modelFile.tcl.
- Path of your 'nodes file': /Users/hresquivelo/nodesFile.out.
Assumptions:
1. There's not spaces before the definition of command node. I mean,
(incorrect)
.... node 1 0.00 0.00 (suppose that dots are spaces)
(correct)
node 1 0.00 0.00
2. If command node is defined inside a logical-loop statement, then it will not work as expected.
The best way is to make a c++ code.
>> Let me know if that works for you. <<
Regards,
-
- Posts: 7
- Joined: Fri Dec 04, 2009 6:21 pm
- Location: UCI
- Contact: