OpenSees: An Open-Source Software for Structural Engineering Analysis and Design

Created By ChatGPT – Release Notes (Feb 13)

Free Stock photos by Vecteezy

OpenSees is an open-source software for structural engineering that has been developed by researchers at the Pacific Earthquake Engineering Research Center (PEER). It is used for the analysis and design of buildings, bridges, and other structures and has been widely adopted by engineers and researchers around the world. In this blog post, we will explore the features and benefits of using OpenSees for structural analysis and design.

Features of OpenSees

  1. Modelling Capabilities: OpenSees has a rich library of elements that can be used to model a wide range of structures, including beams, columns, shells, and cables. The software also supports the creation of user-defined elements, which allows users to extend the software’s capabilities to include their own specific requirements.
  2. Wide Range of Analysis Methods: OpenSees supports a variety of analysis methods, including linear and nonlinear static, dynamic, and pushover analysis. This makes it a versatile software that can be used for a wide range of applications.
  3. Flexibility: OpenSees has a flexible user interface that allows users to write their own scripts, create custom algorithms, and perform simulations using the data generated by other software. This makes it easy for users to integrate OpenSees with other software and tools.
  4. Robustness: OpenSees has been extensively tested and validated on a variety of structures, making it a robust software that can be relied upon for accurate results.

Benefits of using OpenSees

  1. Open-Source: OpenSees is open-source software, which means that it is free to use and is available for anyone to download and use. This makes it an attractive option for engineers and researchers who are working on a tight budget.
  2. Large User Community: OpenSees has a large and active user community that provides support and assistance to users. This makes it easy for users to get help and advice when they need it.
  3. Customization: As an open-source software, OpenSees can be easily customized to meet the specific needs of individual users. This makes it an ideal software for engineers who need to analyze structures with unique or unconventional requirements.
  4. Cost Effective: OpenSees is a cost-effective option for engineers who are looking for a powerful and flexible software for structural analysis and design.

Conclusion

OpenSees is a powerful and flexible software for structural engineering that is used by engineers and researchers around the world. With its rich library of elements, wide range of analysis methods, and flexible user interface, OpenSees is an ideal software for anyone who is looking for a cost-effective and customizable solution for their structural engineering needs.

Part 1: Excel VBA For Engineers

INTRODUCTION

What is VBA?

Visual Basic for Applications (VBA) is the standard programming language for Microsoft Office products including Excel. VBA allows the user to automate Excel tasks by writing macros, subroutines, and functions

Why use VBA?

  • Automate repetitive tasks
  • Simplify complex Excel equations with Basic language code
  • Reduce spreadsheet errors
  • Make spreadsheets more maintainable
  • Automate tasks in software programs such as SAP2000 or AutoCAD

Note: This post uses Excel 2013 but the concepts will apply to any recent version of Excel.

Do you use the built-in Excel LOOKUP functions? Do you use these functions to extract reinforcement data (area, diameter, weight, and etc.) from a range of cells? Yuck! I can never remember the syntax for the LOOKUP functions. Over the years I have made many errors with these convoluted functions. Not only are they error prone, but creating a range of reinforcement data is another possible source of errors.

Here are the functions that bridgeautomation uses to enter reinforcement data into Excel replacing the error prone LOOKUP functions.

Description

RebarArea, RebarDiameter, and RebarWeight returns the area, diameter, and weight in Imperial units respectively. The base units are inch and lb.

Syntax

=RebarArea(value)

=RebarDiameter(value)

=RebarWeight(value)

The RebarArea, RebarDiameter, and RebarWeight syntax has the following argument:

value – Rebar id. This is a string (i.e. #4, #5…….#18). This parameter must be enclosed in quotation marks (i.e. RebarArea(“#4”).

Start typing “Rebar” in a cell and a drop down box opens making it easy to remember the function name.

No LOOKUP tables or typing in reinforcement data into cells!

VBA Setup

Verify that the DEVELOPER menu item is visible.

If the DEVELOPER menu item is not visible navigate to the FILE / OPTIONS dialog box.

At the Options dialog box select Customize Ribbon and check the Developer checkbox and then press the OK button.

Hello World Example

Create a new Excel worksheet and save as an Excel Macro-Enabled Workbook (*.xlsm). From the main menu select the Developer menu item and then click on Visual Basic.

Select Insert and Module.

In the Project Tree in the left pane of the dialog box below click on Module 1. Enter the following code as shown below. You can either type the code in or copy and paste from code textbox below.

Source code for the HelloWorld function is below.

Public Function HelloWorld(flag As String)
     If flag = 0 Then
         MsgBox ("Hello World From Bridgeautomation")
         HelloWorld = "0 passed-Hello From Bridgeautomation"
     Else
         HelloWorld = flag + " passed-Hello World From Bridgeautomation"
     End If
 End Function

Description

HelloWorld is a simple example function that shows how to pass parameters, return values, and use message boxes.

  • A 0 value parameter opens a message box and returns a string message to the cell
  • Any other numeric value parameter just returns a string message to the cell
  • Non-numeric value parameter returns a #Value! error

Syntax

=HelloWorld(value)

The HelloWorld function syntax has the following argument:

value – Any numeric value.

The graphic below shows how to use the HelloWorld function. In the example below cell C3 is referenced for input. Entering the integer 100 as a parameter would have worked as well (=helloworld(100)).

The graphic below shows the final results in cell C5 for an input value of 3 in cell C3.

The Excel file can be found here: Example HelloWorld

References