# -----ELEMENTS.tcl-------------------------------------------------------
# COLUMNS
set ColumnType "inelastic"; # options: "rigid" "elastic" "inelastic"
set np 5; # number of integration points
# source RCcircSection.tcl; # proc to define circular fiber section for flexural characteristics
RCcircSection $IDcolFlex $riCol $roCol $cover $IDcore $IDcover $IDsteel $NbCol $AbCol $nfCoreR $nfCoreT $nfCoverR $nfCoverT
uniaxialMaterial Elastic $IDcolTors $GJ; # Define torsional stiffness
section Aggregator $IDcolSec $IDcolTors T -section $IDcolFlex; # attach torsion and flexure
geomTransf Linear $IDcolTrans 0 0 1; # Linear: no second-order effects
if {$ColumnType == "rigid"} {
set $IyCol [expr $IyCol*$IyCol];
set $IzCol [expr $IzCol*$IzCol];
element elasticBeamColumn 1 1 3 $Acol $Ec $G $J $IyCol $IzCol $IDcolTrans
element elasticBeamColumn 2 2 4 $Acol $Ec $G $J $IyCol $IzCol $IDcolTrans
}
if {$ColumnType == "elastic"} {
element elasticBeamColumn 1 1 3 $Acol $Ec $G $J $IyCol $IzCol $IDcolTrans
element elasticBeamColumn 2 2 4 $Acol $Ec $G $J $IyCol $IzCol $IDcolTrans
}
if {$ColumnType == "inelastic"} {
element nonlinearBeamColumn 1 1 3 $np $IDcolSec $IDcolTrans
element nonlinearBeamColumn 2 2 4 $np $IDcolSec $IDcolTrans
}
# BEAM
geomTransf Linear $IDbeamTrans 0 0 1; # define orientation of beam local axes
element elasticBeamColumn 3 3 4 $Abeam $Ec $G $J $IyBeam $IzBeam $IDbeamTrans;