eigen analysis in Adaptive Pushover

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

Moderators: silvia, selimgunay, Moderators

Post Reply
chriswu
Posts: 7
Joined: Sat May 30, 2009 3:46 am
Location: South China Univ. of Tech.

eigen analysis in Adaptive Pushover

Post by chriswu »

Dear Vesna, all
Here are some problems
1. I want to run modal adaptive pushover analysis of a simple structure, but in the loop the mode shapes did not change along the pushover process if i do not perform the [ eigen $numModes ] command; once perform the [ eigen $numModes ] command, analyze failed in the 2nd analysis step. Thanks for checking it and please correct the script. ^-^
2. the unit system is mm and N, so structure size is too big when using [recorder display] command to visualize the mode shape ,i do not know how to zoom it to a suitable zie. any advice?

here is the tcl model:

#Unit N/mm

wipe;

model basic -ndm 2 -ndf 3;


node 1 0 0
node 2 4000 0
node 3 8000 0
node 4 0 3000
node 5 4000 3000
node 6 8000 3000
node 7 0 6000
node 8 4000 6000
node 9 8000 6000
node 10 0 9000
node 11 4000 9000
node 12 8000 9000
node 13 0 12000
node 14 4000 12000
node 15 8000 12000

mass 4 17.5 17.5 0
mass 5 17.5 17.5 0
mass 6 17.5 17.5 0
mass 7 17.5 17.5 0
mass 8 17.5 17.5 0
mass 9 17.5 17.5 0
mass 10 17.5 17.5 0
mass 11 17.5 17.5 0
mass 12 17.5 17.5 0
mass 13 17.5 17.5 0
mass 14 17.5 17.5 0
mass 15 17.5 17.5 0

uniaxialMaterial Concrete01 1 -35 -0.003 -6 -0.008
uniaxialMaterial Steel01 2 350 215000 0.02


section Fiber 2 {
fiber -229.2 0 8333 1
fiber -187.5 0 8333 1
fiber -145.8 0 8333 1
fiber -104.2 0 8333 1
fiber -62.5 0 8333 1
fiber -20.83 0 8333 1
fiber 20.83 0 8333 1
fiber 62.5 0 8333 1
fiber 104.2 0 8333 1
fiber 145.8 0 8333 1
fiber 187.5 0 8333 1
fiber 229.2 0 8333 1
fiber -215 0 1024 2
fiber 215 0 1024 2
}
section Fiber 1 {
fiber -180 0 16000 1
fiber -140 0 16000 1
fiber -100 0 16000 1
fiber -60 0 16000 1
fiber -20 0 16000 1
fiber 20 0 16000 1
fiber 60 0 16000 1
fiber 100 0 16000 1
fiber 140 0 16000 1
fiber 180 0 16000 1
fiber 165 0 1024 2
fiber -165 0 1024 2
}

#constrain
fix 1 1 1 1
fix 2 1 1 1
fix 3 1 1 1

#local axes relations
geomTransf Linear 1


element nonlinearBeamColumn 1 1 4 4 1 1
element nonlinearBeamColumn 2 2 5 4 1 1
element nonlinearBeamColumn 3 3 6 4 1 1
element nonlinearBeamColumn 4 4 7 4 1 1
element nonlinearBeamColumn 5 5 8 4 1 1
element nonlinearBeamColumn 6 6 9 4 1 1
element nonlinearBeamColumn 7 7 10 4 1 1
element nonlinearBeamColumn 8 8 11 4 1 1
element nonlinearBeamColumn 9 9 12 4 1 1
element nonlinearBeamColumn 10 10 13 4 1 1
element nonlinearBeamColumn 11 11 14 4 1 1
element nonlinearBeamColumn 12 12 15 4 1 1
element nonlinearBeamColumn 13 4 5 4 2 1
element nonlinearBeamColumn 14 5 6 4 2 1
element nonlinearBeamColumn 15 7 8 4 2 1
element nonlinearBeamColumn 16 8 9 4 2 1
element nonlinearBeamColumn 17 10 11 4 2 1
element nonlinearBeamColumn 18 11 12 4 2 1
element nonlinearBeamColumn 19 13 14 4 2 1
element nonlinearBeamColumn 20 14 15 4 2 1



pattern Plain 1 Linear {
load 13 0 -700000 0
load 14 0 -700000 0
load 15 0 -700000 0
}

system UmfPack
constraints Plain
numberer Plain
test NormDispIncr 1.0e-1 1000
algorithm Newton
analysis Static
integrator LoadControl 0.1
analyze 10
loadConst -time 0


puts "Model Build"
set nEigenI 1; # mode 1
set nEigenJ 2; # mode 3
set lambdaN [eigen [expr $nEigenJ]]; # eigenvalue analysis for nEigenJ modes
set lambdaI [lindex $lambdaN [expr $nEigenI-1]]; # eigenvalue mode i
set lambdaJ [lindex $lambdaN [expr $nEigenJ-1]]; # eigenvalue mode j
set omegaI [expr 6.28/pow($lambdaI,0.5)];
set omegaJ [expr 6.28/pow($lambdaJ,0.5)];
puts $omegaI
puts $omegaJ
set nEigenI 3; # mode 1
set nEigenJ 4; # mode 3
set lambdaN [eigen [expr $nEigenJ]]; # eigenvalue analysis for nEigenJ modes
set lambdaI [lindex $lambdaN [expr $nEigenI-1]]; # eigenvalue mode i
set lambdaJ [lindex $lambdaN [expr $nEigenJ-1]]; # eigenvalue mode j
set omegaI [expr 6.28/pow($lambdaI,0.5)];
set omegaJ [expr 6.28/pow($lambdaJ,0.5)];
puts $omegaI
puts $omegaJ



###########################################################################################################################

file mkdir modes;


# k——mode number,i——joint number,j——computation step, push(i)——lateral load on the i point

set nnode 15; #total nodes
set numModes 1; #Modes considered,
set numSteps 20 ; #analyze steps
set deltaD 0.5; #pushover displacement per step
set Nodefirst 1; #noderange
set Nodelast 15; #ndderange
set Nodemonitor 14; #monitor point


for {set j 1} {$j<=$numSteps} {incr j 1} {;
for { set k 1 } { $k <= $numModes } { incr k } {
recorder Node -file modes/Eigenvector$j$k.out -nodeRange $Nodefirst $Nodelast -dof 1 "eigen $k"
set lambda [eigen $numModes]; ## if this line is removed , the analysis can be done successfully, but mode shapes keep the same.

integrator LoadControl 0 1 0 0
test EnergyIncr 1.0e-10 100 0
algorithm Newton
numberer RCM
constraints Transformation
system ProfileSPD
analysis Static
analyze 1
remove recorders
}

puts "modal analysis done"
#######################################################################
for { set k 1 } { $k <= $numModes } { incr k } { # read mode shapes
if [catch {open modes/Eigenvector$j$k.out r} InfileID] {
puts "ERROR - cannot open Eigenvector$j$k.out"
}

set eigenVector [gets $InfileID]
# ------------------------------------------------pushover
for {set i 1} {$i<=$nnode} {incr i 1} {
set fi($k,$i) [lindex $eigenVector [expr $i-1]];
}
}
# parray fi
#get modal paritcipation factors
set sum1 0
set sum2 0
for { set k 1 } { $k <= $numModes } { incr k } {
for {set i 1} {$i<=$nnode} {incr i 1} {
set sum1 [expr $sum1+$fi($k,$i)]
set sum2 [expr $sum2+pow($fi($k,$i),2)]
}

set gama($k) [expr $sum1/$sum2]
for {set i 1} {$i<=$nnode} {incr i 1} {
set f($k,$i) [expr $gama($k)*$fi($k,$i)]
}
}
parray gama;
# parray f;
#####################################################################################
puts "gama computation done"
#####################################################################################
array set push ""; #SRSS composition to get lateral force pattern if multy modes considered
for {set i 1} {$i<=$nnode} {incr i 1} {
# puts "done1111"
# puts "done1111"
set push($i) 0
for { set k 1 } { $k <= $numModes } { incr k } {

set push($i) [expr $push($i)+pow($f($k,$i),2)]
}
set push($i) [expr pow($push($i),0.5)]
}
puts "lateral load pattern compute done"
#####################################################################################
recorder Node -file response/Node13Disp$j.out -time -node 13 -dof 1 disp
recorder Node -file response/Node1shear$j.out -time -node 1 -dof 1 reaction
remove loadPattern 200;
pattern Plain 200 Linear {; # define load pattern
for {set i 1} {$i<=$nnode} {incr i 1} {
load $i $push($i) 0.0 0.0
}
}

system UmfPack
constraints Plain
numberer Plain
test EnergyIncr 1.0e-4 1000 0
algorithm Newton
analysis Static
integrator DisplacementControl $Nodemonitor 1 $deltaD
analyze 1
puts "done$j"
puts "\n[nodeDisp $Nodemonitor 1]"
remove recorders
}
puts "done"
Freshman of Opensees
vesna
Posts: 3033
Joined: Tue May 23, 2006 11:23 am
Location: UC Berkeley

Re: eigen analysis in Adaptive Pushover

Post by vesna »

1. Your model is not doing what you are saying. Would you please try to describe me each line/part of your code and I will let you know where you are not doing what you think you are doing.

2. There is no too big structure to visualize the mode shapes. You can use recorder display for any size of the structure.
chriswu
Posts: 7
Joined: Sat May 30, 2009 3:46 am
Location: South China Univ. of Tech.

Re: eigen analysis in Adaptive Pushover

Post by chriswu »

vesna wrote:
> 1. Your model is not doing what you are saying. Would you please try to
> describe me each line/part of your code and I will let you know where you
> are not doing what you think you are doing.
>
> 2. There is no too big structure to visualize the mode shapes. You can use
> recorder display for any size of the structure.

Thanks for your reply. Here is the annotation of the model....Moreover,do you have any example on adaptive pushover? If posible, please share it with me .^-^
My email is chriswu1987@foxmail.com. thx!

#Unit N/mm

wipe;

model basic -ndm 2 -ndf 3;

#node
node 1 0 0
node 2 4000 0
node 3 8000 0
node 4 0 3000
node 5 4000 3000
node 6 8000 3000
node 7 0 6000
node 8 4000 6000
node 9 8000 6000
node 10 0 9000
node 11 4000 9000
node 12 8000 9000
node 13 0 12000
node 14 4000 12000
node 15 8000 12000

#mass
mass 4 17.5 17.5 0
mass 5 17.5 17.5 0
mass 6 17.5 17.5 0
mass 7 17.5 17.5 0
mass 8 17.5 17.5 0
mass 9 17.5 17.5 0
mass 10 17.5 17.5 0
mass 11 17.5 17.5 0
mass 12 17.5 17.5 0
mass 13 17.5 17.5 0
mass 14 17.5 17.5 0
mass 15 17.5 17.5 0

uniaxialMaterial Concrete01 1 -35 -0.003 -6 -0.008
uniaxialMaterial Steel01 2 350 215000 0.02
#2D fiber section
section Fiber 1 {
fiber -180 0 16000 1
fiber -140 0 16000 1
fiber -100 0 16000 1
fiber -60 0 16000 1
fiber -20 0 16000 1
fiber 20 0 16000 1
fiber 60 0 16000 1
fiber 100 0 16000 1
fiber 140 0 16000 1
fiber 180 0 16000 1
fiber 165 0 1024 2
fiber -165 0 1024 2
}

section Fiber 2 {
fiber -229.2 0 8333 1
fiber -187.5 0 8333 1
fiber -145.8 0 8333 1
fiber -104.2 0 8333 1
fiber -62.5 0 8333 1
fiber -20.83 0 8333 1
fiber 20.83 0 8333 1
fiber 62.5 0 8333 1
fiber 104.2 0 8333 1
fiber 145.8 0 8333 1
fiber 187.5 0 8333 1
fiber 229.2 0 8333 1
fiber -215 0 1024 2
fiber 215 0 1024 2
}


#constrain
fix 1 1 1 1
fix 2 1 1 1
fix 3 1 1 1

#local axes relations
geomTransf Linear 1


element nonlinearBeamColumn 1 1 4 4 1 1
element nonlinearBeamColumn 2 2 5 4 1 1
element nonlinearBeamColumn 3 3 6 4 1 1
element nonlinearBeamColumn 4 4 7 4 1 1
element nonlinearBeamColumn 5 5 8 4 1 1
element nonlinearBeamColumn 6 6 9 4 1 1
element nonlinearBeamColumn 7 7 10 4 1 1
element nonlinearBeamColumn 8 8 11 4 1 1
element nonlinearBeamColumn 9 9 12 4 1 1
element nonlinearBeamColumn 10 10 13 4 1 1
element nonlinearBeamColumn 11 11 14 4 1 1
element nonlinearBeamColumn 12 12 15 4 1 1
element nonlinearBeamColumn 13 4 5 4 2 1
element nonlinearBeamColumn 14 5 6 4 2 1
element nonlinearBeamColumn 15 7 8 4 2 1
element nonlinearBeamColumn 16 8 9 4 2 1
element nonlinearBeamColumn 17 10 11 4 2 1
element nonlinearBeamColumn 18 11 12 4 2 1
element nonlinearBeamColumn 19 13 14 4 2 1
element nonlinearBeamColumn 20 14 15 4 2 1


#apply gravity (simply applied at the roof nodes)
pattern Plain 1 Linear {
load 13 0 -700000 0
load 14 0 -700000 0
load 15 0 -700000 0
}

system UmfPack
constraints Plain
numberer Plain
test NormDispIncr 1.0e-1 1000
algorithm Newton
analysis Static
integrator LoadControl 0.1
analyze 10
loadConst -time 0

#check the period
puts "Model Build"
set nEigenI 1; # mode 1
set nEigenJ 2; # mode 3
set lambdaN [eigen [expr $nEigenJ]]; # eigenvalue analysis for nEigenJ modes
set lambdaI [lindex $lambdaN [expr $nEigenI-1]]; # eigenvalue mode i
set lambdaJ [lindex $lambdaN [expr $nEigenJ-1]]; # eigenvalue mode j
set omegaI [expr 6.28/pow($lambdaI,0.5)];
set omegaJ [expr 6.28/pow($lambdaJ,0.5)];
puts $omegaI
puts $omegaJ


#this model can successfully perform convetional pushover analysis

#################################################################################

file mkdir modes; #output folder

# perform modal adaptive pushover
# k——mode number,i——joint number,j——push step, push(i)——lateral load pattern on the i point

set nnode 15; #total number of nodes
set numModes 1; #Modes considered,
set numSteps 20 ; #analyze steps
set deltaD 0.5; #pushover displacement per step, so the final roof displacement is $numSteps*$deltaD
set Nodefirst 1; #noderange
set Nodelast 15; #ndderange
set Nodemonitor 14; #monitor point


for {set j 1} {$j<=$numSteps} {incr j 1} {; #the j-th push , at each push the lateral load pattern is renewed by the nonlinear response of the structure
for { set k 1 } { $k <= $numModes } { incr k } { #this loop gets the mode shapes of each mode considered at everystep along the pushover
recorder Node -file modes/Eigenvector$j$k.out -nodeRange $Nodefirst $Nodelast -dof 1 "eigen $k"
set lambda [eigen $numModes]; ## if this line is removed , the analysis can be done successfully, but mode shapes keep the same.

integrator LoadControl 0 1 0 0
test EnergyIncr 1.0e-10 100 0
algorithm Newton
numberer RCM
constraints Transformation
system ProfileSPD
analysis Static
analyze 1
remove recorders
}

puts "modal analysis done"
#######################################################################
for { set k 1 } { $k <= $numModes } { incr k } { # the loop reads the mode shapes
if [catch {open modes/Eigenvector$j$k.out r} InfileID] {
puts "ERROR - cannot open Eigenvector$j$k.out"
}

set eigenVector [gets $InfileID]
for {set i 1} {$i<=$nnode} {incr i 1} {
set fi($k,$i) [lindex $eigenVector [expr $i-1]];
}
}

set sum1 0
set sum2 0
for { set k 1 } { $k <= $numModes } { incr k } { #the loop gets modal paritcipation factors, mass is not considered because at each node mass is the same
for {set i 1} {$i<=$nnode} {incr i 1} {
set sum1 [expr $sum1+$fi($k,$i)]
set sum2 [expr $sum2+pow($fi($k,$i),2)]
}

set gama($k) [expr $sum1/$sum2]
for {set i 1} {$i<=$nnode} {incr i 1} {
set f($k,$i) [expr $gama($k)*$fi($k,$i)]
}
}
parray gama; #as the structure is pushed to the nonlinear range, gama should change respectively
puts "gama computation done"
#####################################################################################
array set push ""; #SRSS composition to get lateral force pattern if multy modes considered
for {set i 1} {$i<=$nnode} {incr i 1} {
# puts "done1111"
# puts "done1111"
set push($i) 0
for { set k 1 } { $k <= $numModes } { incr k } {

set push($i) [expr $push($i)+pow($f($k,$i),2)]
}
set push($i) [expr pow($push($i),0.5)]
}
puts "lateral load pattern compute done"
#####################################################################################
recorder Node -file response/Node13Disp$j.out -time -node 13 -dof 1 disp
recorder Node -file response/Node1shear$j.out -time -node 1 -dof 1 reaction

remove loadPattern 200;
pattern Plain 200 Linear {; # define load pattern and perform pushover analysis
for {set i 1} {$i<=$nnode} {incr i 1} {
load $i $push($i) 0.0 0.0
}
}

system UmfPack
constraints Plain
numberer Plain
test EnergyIncr 1.0e-4 1000 0
algorithm Newton
analysis Static
integrator DisplacementControl $Nodemonitor 1 $deltaD
analyze 1
puts "done$j"
puts "\n[nodeDisp $Nodemonitor 1]"
remove recorders
}
puts "done"
Freshman of Opensees
vesna
Posts: 3033
Joined: Tue May 23, 2006 11:23 am
Location: UC Berkeley

Re: eigen analysis in Adaptive Pushover

Post by vesna »

You are performing eigen anlysis before pushover. You have to place eigen analysis inside of pushover anlaysis. Please look at this post:
http://opensees.berkeley.edu/community/ ... =2&t=26855

Replicate what he is doing to your case.
Post Reply