how to record result in a single file

Forum for OpenSees users to post questions, comments, etc. on the use of the OpenSees interpreter, OpenSees.exe

Moderators: silvia, selimgunay, Moderators

Post Reply
jndlsmt
Posts: 18
Joined: Thu Nov 25, 2010 2:37 am
Location: IIT Kanpur

how to record result in a single file

Post by jndlsmt »

hi friends,
i wrote a code for 6 input variables which has 100 values...
how to record a node displacement in a single file for 100 values of these variables.....

my code------
set phiR [open phi.txt "r"]
set Phi [gets $phiR]
close $phiR

set neuR [open neu.txt "r"]
set Neu [gets $neuR]
close $neuR

set gR [open G.txt "r+"]
set gG [gets $gR]
close $gR

set ReR [open Re.txt "r"]
set RE [gets $ReR]
close $ReR

set RkR [open Rk.txt "r"]
set RK [gets $RkR]
close $RkR

set leRatioR [open leRatio.txt "r"]
set LeRatio [gets $leRatioR]
close $leRatioR

set j 0
foreach phi $Phi neu $Neu G $gG Re $RE Rk $RK leRatio $LeRatio {

puts "phi: $phi,neu: $neu,G: $G,Re: $Re,Rk: $Rk,leRatio: $leRatio"

incr j 1
set dataDir [format "sample" $j ]
file mkdir $dataDir; # create data directory
------------

recorder Node -time -file [format "$dataDir/walldisp%i.dat" $j ] -node 1 2 -dof 1 2 3 disp; #records displacement
### if i am recording in this way ,as a result i am getting 100files but need all data in a single file
----
}
Sumit Jindal
IIT Kanpur (India)
sb1966
Posts: 151
Joined: Wed Jul 23, 2008 8:08 am
Location: NERIST, INDIA
Contact:

Re: how to record result in a single file

Post by sb1966 »

U may use node recorder as follows if u want displacement of all the nodes in dof 1 2 and 3:
recorder Node -file filename -time -node all -dof 1 2 3 disp
----------------------------------
With Regards,
sb1966
sb1966
Posts: 151
Joined: Wed Jul 23, 2008 8:08 am
Location: NERIST, INDIA
Contact:

Re: how to record result in a single file

Post by sb1966 »

I suggest u to visit the Online Command manual in the OpenSees User page
----------------------------------
With Regards,
sb1966
jndlsmt
Posts: 18
Joined: Thu Nov 25, 2010 2:37 am
Location: IIT Kanpur

Re: how to record result in a single file

Post by jndlsmt »

please read my question correctly
i am not asking to record dis in all nodes (that is i know how to do)
i am asking how to record disp in single file for each value of input variable
Sumit Jindal
IIT Kanpur (India)
jndlsmt
Posts: 18
Joined: Thu Nov 25, 2010 2:37 am
Location: IIT Kanpur

Re: how to record result in a single file

Post by jndlsmt »

dear sb1966
take time to read a question correctly
Sumit Jindal
IIT Kanpur (India)
sb1966
Posts: 151
Joined: Wed Jul 23, 2008 8:08 am
Location: NERIST, INDIA
Contact:

Re: how to record result in a single file

Post by sb1966 »

Thanks for ur advice. It is now clear that u know OpenSees a lot. I look forward for help in making me learn. Sorry for ur inconvenience
----------------------------------
With Regards,
sb1966
vesna
Posts: 3033
Joined: Tue May 23, 2006 11:23 am
Location: UC Berkeley

Re: how to record result in a single file

Post by vesna »

There is no command in OpenSees that will do it for you. You have to do it tcl manually.
jndlsmt
Posts: 18
Joined: Thu Nov 25, 2010 2:37 am
Location: IIT Kanpur

Re: how to record result in a single file

Post by jndlsmt »

dear sb1966
please don't take it otherwise.
Sumit Jindal
IIT Kanpur (India)
sb1966
Posts: 151
Joined: Wed Jul 23, 2008 8:08 am
Location: NERIST, INDIA
Contact:

Re: how to record result in a single file

Post by sb1966 »

Dear Sumit,
I took ur advice in a positive spirit only. Thanks. Hope we can benefit from each other's interaction.
----------------------------------
With Regards,
sb1966
Post Reply