OpenSees Example 3. Cantilever Column with units: Difference between revisions

From OpenSeesWiki
Jump to navigation Jump to search
(Created page with '__NOTOC__ ==Introduction== The principal features of this example is the introduction of units and the separation of the model-building and the analysis portions of the input fil…')
 
No edit summary
Line 14: Line 14:
|-
|-
| style="color:#000;" | <div>
| style="color:#000;" | <div>
[[File:Example2c_Push.GIF|link=OpenSees Example 2c. 2D Elastic Cantilever Column]]
[[File:Example3_Push.GIF|link=OpenSees Example 3. 2D Elastic Cantilever Column]]
----
----
<strong>Files</strong>
<strong>Files</strong>
*[[Media:Ex2c.Canti2D.InelasticFiberSection.Push.tcl|Ex2c.Canti2D.InelasticFiberSection.Push.tcl]]
*[[Media:Ex3.Canti2D.InelasticFiberSection.Push.tcl|Ex3.Canti2D.InelasticFiberSection.Push.tcl]]
</div>
</div>
|}
|}
Line 27: Line 27:
|-
|-
| style="color:#000;" | <div>
| style="color:#000;" | <div>
[[File:Example2c_EQ.GIF|link=OpenSees Example 2c. 2D Elastic Cantilever Column]]
[[File:Example3_EQ.GIF|link=OpenSees Example 3. 2D Elastic Cantilever Column]]
----
----
<strong>Files</strong>
<strong>Files</strong>
*[[Media:Ex2c.Canti2D.InelasticFiberSection.EQ.tcl|Ex2c.Canti2D.InelasticFiberSection.EQ.tcl]]
*[[Media:Ex3.Canti2D.InelasticFiberSection.EQ.tcl|Ex3.Canti2D.InelasticFiberSection.EQ.tcl]]
*[[Media:BM68elc.acc|BM68elc.acc]] (ground-motion file)
*[[Media:BM68elc.acc|BM68elc.acc]] (ground-motion file)
</div>
</div>
Line 39: Line 39:
==Run==
==Run==
*To run Static Pushover analysis:
*To run Static Pushover analysis:
:<strong>source Ex2c.Canti2D.InelasticFiberSection.Push.tcl</strong>
:<strong>source Ex3.Canti2D.InelasticFiberSection.Push.tcl</strong>


*To run EQ ground-motion analysis (BM68elc.acc needs to be downloaded into the same directory):
*To run EQ ground-motion analysis (BM68elc.acc needs to be downloaded into the same directory):


:<strong>source Ex2c.Canti2D.InelasticFiberSection.EQ.tcl</strong>
:<strong>source Ex3.Canti2D.InelasticFiberSection.EQ.tcl</strong>


==Notes==
==Notes==
Line 58: Line 58:
For example, with the following commands used in setting some of the units:
For example, with the following commands used in setting some of the units:


<blockquote><source lang="Tcl>
<blockquote><source lang="Tcl">
set in 1.; # define basic units -- output units
set in 1.; # define basic units -- output units
set kip 1.; # define basic units -- output units
set kip 1.; # define basic units -- output units
Line 69: Line 69:
When the user says:
When the user says:


<blockquote><source lang="Tcl>
<blockquote><source lang="Tcl">
set HCol [expr 3*$in];
set HCol [expr 3*$in];
set LCol [expr 30*$ft];
set LCol [expr 30*$ft];

Revision as of 17:38, 11 November 2009

Introduction

The principal features of this example is the introduction of units and the separation of the model-building and the analysis portions of the input file. For demonstration purposes, this example visits the 2D cantilever column, again.

Input

Static Pushover


Dynamic EQ Ground Motion


Run

  • To run Static Pushover analysis:
source Ex3.Canti2D.InelasticFiberSection.Push.tcl
  • To run EQ ground-motion analysis (BM68elc.acc needs to be downloaded into the same directory):
source Ex3.Canti2D.InelasticFiberSection.EQ.tcl

Notes

  • This example is the first to follow most of the recommended techniques in building an input file:
  • Model and analysis parameters are defined as variables
  • The basic units, used to define Force, Length and Time need to be independent.
  • Units need to be used consistently throughout the input file, otherwise some arguments will not scale properly
  • The model-building files and the analysis files are separated. The same analysis file can be used on different model-building files (elastic or inelastic elements).
  • This example does not, however, take advantage of previously-defined Tcl procedures and scripts, as will Example 4.
  • In OpenSees/Tcl, units are simply defined as variables that become scaling factors. This technique allows the user to input variables with different types of units, not just the ones chosen for output. For example, section widths can be defined in inches, while element length can be defined in feet.

For example, with the following commands used in setting some of the units:

set in 1.; # define basic units -- output units
set kip 1.; # define basic units -- output units
set sec 1.; # define basic units -- output units
# -------
set ft [expr 12.*$in]; # define engineering units
set ksi [expr $kip/pow($in,2)];
</blockquote>

When the user says:

set HCol [expr 3*$in];
set LCol [expr 30*$ft];
</blockquote>

Tcl multiplies 30 by 12 to give the column length in inches. By scaling the input, all input processed by OpenSees is in the basic units, as is the output.





Return to OpenSees Examples Manual

Return to OpenSees User