Run and Post Processing issue

Posts: 37
Joined: Wed Jul 24, 2019 11:10 am

Re: Run and Post Processing issue

Post by MassimoPetracca » Thu Sep 19, 2019 4:18 pm

Dear Filip,

Don't worry to bother us, we're here to help you!

Those red lines that you see are just warnings. Basically in the version that you have, which is a Beta version, the eigenvalues are stored in the database but not shown to the user (thus the warning message). However you can still display the eigenvectors (modes of vibration) using the volume or surface plot (of course, assuming that you requested the output of modes of vibration in the definition of the MPCORecorder analysis step).

In the official version that will be online in October that issue is solved.
In the meantime, whenever you want to do a eigen analysis, insead of creating the "eigen" analysis step + the custom step for "record", you can just create one custom step with the following code, so that it will write the eigenvalues in an output file in the same folder of the *mpco file.

Code: Select all

# set the required number of eigenvalues here
set num_eigen 5

# run the eigen command and store the resulting eigenvalues
# in the "lambdas" list
set lambdas [eigen $num_eigen]

# manually call record if there is no other analysis after the eigen command.
# unfortunately in opensees the eigen command does not call automatically a record...
puts "record eigen"

# process all eigenvalues and obtain periods
# print them to screen and to a file
set out_file [open "eigenvalues.txt" w]
set format_string "%16s%16s%16s%16s"; # used to format the header of the table
set format_double "%16g%16g%16g%16g"; # used to format floating point values of the table
set pi [expr acos(-1.0)]
puts [format $format_string "lambda" "omega" "frequency" "period"]
puts $out_file [format $format_string "lambda" "omega" "frequency" "period"]
for {set i 0} {$i < $num_eigen} {incr i} {
	set lambda [lindex $lambdas $i]
	set omega [expr {sqrt($lambda)}]
	set frequency [expr $omega / 2.0 / $pi]
	set period [expr 1.0 / $frequency]
	puts [format $format_double $lambda $omega $frequency $period]
	puts $out_file [format $format_double $lambda $omega $frequency $period]
close $out_file

Posts: 8
Joined: Tue Sep 17, 2019 7:22 am

Re: Run and Post Processing issue

Post by Filip » Fri Sep 20, 2019 8:00 am

Thank you very much Massimo. I tried plotting with volume plot and it works very well. I will definitely go on exploring the possibilities of STKO, so far it is great.
Regards, Filip

Post Reply