High-rise Modular Steel Building#

Note: This section is based on the work of Sanches et al. (2021). Please see References page for more information.

Layout of the building is defined in a dictionary. The dictionary is defined in a separate file and imported into the main script. The dictionary is defined as follows:

layout = {
    "1-32": {
        1: {
            "we-dir": 3.5,
            "sn-dir": 12,
            "location": "south-west",
            "brace": [
                {"side": "west", "range": "entire", "type": "Chevron"},
            ],
            "sw-coord": [0.0, 0.0],
        },
        2: {
            "we-dir": 3.5,
            "sn-dir": 10.4,
            "location": "north-1",
            "brace": [
                {"side": "west", "range": "entire", "type": "Chevron"},
            ],
            "sw-coord": [0.0, 12 + 0.35],
        },
        3: {
            "we-dir": 3.5,
            "sn-dir": 12,
            "location": "east-1",
            "brace": None,
            "sw-coord": [3.5 + 0.35, 0.0],
        },
        4: {
            "we-dir": 3.5,
            "sn-dir": 10.4,
            "location": "north-3",
            "brace": None,
        },
        5: {
            "we-dir": 3.5,
            "sn-dir": 12,
            "location": "east-3",
            "brace": [
                {"side": "east", "range": "start-6.65", "type": "Chevron"},
            ],
        },
        6: {
            "we-dir": 3.5,
            "sn-dir": 10.4,
            "location": "north-5",
            "brace": [
                {"side": "east", "range": "3.05-end", "type": "Chevron"},
            ],
        },
        7: {
            "we-dir": 8.8,
            "sn-dir": 3.15,
            "location": "east-5",
            "brace": [
                {"side": "south", "range": "entire", "type": "Chevron"},
            ],
        },
        8: {
            "we-dir": 8.8,
            "sn-dir": 3.15,
            "location": "north-7",
            "brace": [
                {"side": "north", "range": "entire", "type": "Chevron"},
            ],
        },
        9: {
            "we-dir": 8.8,
            "sn-dir": 2.9,
            "location": "north-8",
            "brace": [
                {"side": "south", "range": "entire", "type": "Chevron"},
                # {"side": "north", "range": "entire", "type": "X"},
            ],
        },
        10: {
            "we-dir": 8.8,
            "sn-dir": 2.1,
            "south-spacing": 0.0,
            "location": "north-9",
            "brace": [{"side": "north", "range": "entire", "type": "Chevron"}],
        },
        11: {
            "we-dir": 8.8,
            "sn-dir": 2.7,
            "location": "north-10",
            "brace": [
                {"side": "north", "range": "entire", "type": "Chevron"},
                {"side": "south", "range": "entire", "type": "Chevron"},
            ],
        },
        12: {
            "we-dir": 8.8,
            "sn-dir": 3.5,
            "location": "north-11",
            "brace": [{"side": "south", "range": "entire", "type": "Chevron"}],
        },
        13: {
            "we-dir": 8.8,
            "sn-dir": 3.5,
            "location": "north-12",
            "brace": [{"side": "north", "range": "entire", "type": "Chevron"}],
        },
        14: {
            "we-dir": 3.5,
            "sn-dir": 12,
            "location": "east-7",
            "brace": [
                {"side": "west", "range": "start-6.65", "type": "Chevron"},
            ],
        },
        15: {
            "we-dir": 3.5,
            "sn-dir": 10.4,
            "location": "north-14",
            "brace": [
                {"side": "west", "range": "3.05-end", "type": "Chevron"},
            ],
        },
        16: {
            "we-dir": 3.5,
            "sn-dir": 12,
            "location": "east-14",
            "brace": None,
        },
        17: {
            "we-dir": 3.5,
            "sn-dir": 10.4,
            "location": "north-16",
            "brace": None,
        },
        18: {
            "we-dir": 3.5,
            "sn-dir": 12,
            "location": "east-16",
            "brace": [
                {"side": "east", "range": "entire", "type": "Chevron"},
            ],
        },
        19: {
            "we-dir": 3.5,
            "sn-dir": 10.4,
            "location": "north-18",
            "brace": [
                {"side": "east", "range": "entire", "type": "Chevron"},
            ],
        },
    },
}

Height of the building is defined in a separate file and imported into the main script. The height is defined as follows:

height = {
    "ground_level": -0.6,
    "1": {
        "module": 3.5 + 0.6,
        "vert_con": 0.6,
    },
    "2-32": {"module": 3.5 + 0.45, "vert_con": 0.45},
}

Sections of the columns and beams are defined in a separate file and imported into the main script. The sections are defined as follows:

sections = {
    "ceiling_beam": {
        "regular": [
            {"story": "all", "length": [0.0, 8.9], "section": "W200X26.6"},
            {
                "story": "all",
                "length": [8.9, 1e9],
                "section": "W310X38.7",
            },
        ],
        "braced": [
            {
                "story": [1, 3],
                "length": "all",
                "section": {"south-north": "W460X421", "west-east": "W460X421"},
            },
            {
                "story": [4, 9],
                "length": "all",
                "section": {"south-north": "W460X384", "west-east": "W460X384"},
            },
            {
                "story": [10, 13],
                "length": "all",
                "section": {"south-north": "W460X349", "west-east": "W460X315"},
            },
            {
                "story": [14, 18],
                "length": "all",
                "section": {"south-north": "W460X315", "west-east": "W460X315"},
            },
            {
                "story": [19, 26],
                "length": "all",
                "section": {"south-north": "W460X286", "west-east": "W460X260"},
            },
            {
                "story": [27, 28],
                "length": "all",
                "section": {"south-north": "W460X213", "west-east": "W460X193"},
            },
            {
                "story": [29, 29],
                "length": "all",
                "section": {"south-north": "W460X193", "west-east": "W460X158"},
            },
            {
                "story": [30, 34],
                "length": "all",
                "section": "W460X158",
            },
        ],
    },
    "floor_beam": {
        "regular": [
            {"story": "all", "length": [0.0, 3.6], "section": "W200X26.6"},
            {"story": "all", "length": [3.6, 8.9], "section": "W310X38.7"},
            {
                "story": "all",
                "length": [8.9, 1e9],
                "section": "W360X44",
            },
        ],
        "braced": [
            {"story": "all", "length": [0.0, 3.6], "section": "W200X26.6"},
            {"story": "all", "length": [3.6, 8.9], "section": "W360X44"},
            {
                "story": "all",
                "length": [8.9, 1e9],
                "section": "W460X52",
            },
        ],
    },
    "brace": [
        {"story": [1, 3], "length": "all", "section": "HSS127X127X12.7"},
        {"story": [4, 6], "length": "all", "section": "HSS127X127X12.7"},
        {"story": [7, 9], "length": "all", "section": "HSS127X127X12.7"},
        {
            "story": [10, 12],
            "length": "all",
            "section": {
                "south-north": "HSS127X127X9.5",
                "west-east": "HSS152.4X152.4X7.9",
            },
        },
        {
            "story": [13, 13],
            "length": "all",
            "section": {
                "south-north": "HSS127X127X9.5",
                "west-east": "HSS152.4X152.4X7.9",
            },
        },
        {"story": [14, 15], "length": "all", "section": "HSS127X127X9.5"},
        {
            "story": [16, 18],
            "length": "all",
            "section": {
                "south-north": "HSS114.3X114.3X9.5",
                "west-east": "HSS127X127X9.5",
            },
        },
        {
            "story": [19, 19],
            "length": "all",
            "section": {
                "south-north": "HSS114.3X114.3X9.5",
                "west-east": "HSS127X127X9.5",
            },
        },
        {
            "story": [20, 22],
            "length": "all",
            "section": {
                "south-north": "HSS127X127X7.9",
                "west-east": "HSS101.6X101.6X7.9",
            },
        },
        {
            "story": [23, 24],
            "length": "all",
            "section": {
                "south-north": "HSS101.6X101.6X7.9",
                "west-east": "HSS127X127X7.9",
            },
        },
        {
            "story": [25, 26],
            "length": "all",
            "section": {
                "south-north": "HSS101.6X101.6X7.9",
                "west-east": "HSS101.6X101.6X7.9",
            },
        },
        {
            "story": [27, 28],
            "length": "all",
            "section": {
                "south-north": "HSS88.9X88.9X6.4",
                "west-east": "HSS101.6X101.6X7.9",
            },
        },
        {
            "story": [29, 29],
            "length": "all",
            "section": {
                "south-north": "HSS88.9X88.9X6.4",
                "west-east": "HSS101.6X101.6X7.9",
            },
        },
        {
            "story": [30, 34],
            "length": "all",
            "section": {
                "south-north": "HSS76.2X76.2X6.4",
                "west-east": "HSS101.6X101.6X7.9",
            },
        },
    ],
    "column": [
        {
            "story": [1, 6],
            "section": "HSS304.8X304.8X15.9",
            "multi": {
                1: {"brace": {"west-start": 4, "west-end": 2}},
                2: {"brace": {"west-start": 2, "west-end": 4}},
                5: {"brace": {"east-start": 4, "east-end": 2}},
                6: {"brace": {"east-start": 2, "east-end": 4}},
                7: {"brace": {"south-start": 4, "south-end": 4}},
                8: {"brace": {"north-start": 4, "north-end": 4}},
                9: {"brace": {"south-start": 4, "south-end": 4}},
                10: {"brace": {"north-start": 4, "north-end": 4}},
                11: {
                    "brace": {
                        "south-start": 4,
                        "south-end": 4,
                        "north-start": 4,
                        "north-end": 4,
                    }
                },
                12: {"brace": {"south-start": 4, "south-end": 4}},
                13: {"brace": {"north-start": 4, "north-end": 4}},
                14: {"brace": {"west-start": 4, "west-end": 2}},
                15: {"brace": {"west-start": 2, "west-end": 4}},
                18: {"brace": {"east-start": 4, "east-end": 2}},
                19: {"brace": {"east-start": 2, "east-end": 4}},
            },
        },
        {
            "story": [7, 12],
            "section": "HSS304.8X304.8X12.7",
            "multi": {
                1: {"brace": {"west-start": 3, "west-end": 1}},
                2: {"brace": {"west-start": 1, "west-end": 3}},
                5: {"brace": {"east-start": 3, "east-end": 1}},
                6: {"brace": {"east-start": 1, "east-end": 3}},
                7: {"brace": {"south-start": 3, "south-end": 3}},
                8: {"brace": {"north-start": 3, "north-end": 3}},
                9: {"brace": {"south-start": 3, "south-end": 3}},
                10: {"brace": {"north-start": 3, "north-end": 3}},
                11: {
                    "brace": {
                        "south-start": 3,
                        "south-end": 3,
                        "north-start": 3,
                        "north-end": 3,
                    }
                },
                12: {"brace": {"south-start": 3, "south-end": 3}},
                13: {"brace": {"north-start": 3, "north-end": 3}},
                14: {"brace": {"west-start": 3, "west-end": 1}},
                15: {"brace": {"west-start": 1, "west-end": 3}},
                18: {"brace": {"east-start": 3, "east-end": 1}},
                19: {"brace": {"east-start": 1, "east-end": 3}},
            },
        },
        {
            "story": [13, 18],
            "section": "HSS254X254X12.7",
            "multi": {
                1: {"brace": {"west-start": 2, "west-end": 1}},
                2: {"brace": {"west-start": 1, "west-end": 2}},
                5: {"brace": {"east-start": 2, "east-end": 1}},
                6: {"brace": {"east-start": 1, "east-end": 2}},
                7: {"brace": {"south-start": 2, "south-end": 2}},
                8: {"brace": {"north-start": 2, "north-end": 2}},
                9: {"brace": {"south-start": 2, "south-end": 2}},
                10: {"brace": {"north-start": 2, "north-end": 2}},
                11: {
                    "brace": {
                        "south-start": 2,
                        "south-end": 2,
                        "north-start": 2,
                        "north-end": 2,
                    }
                },
                12: {"brace": {"south-start": 2, "south-end": 2}},
                13: {"brace": {"north-start": 2, "north-end": 2}},
                14: {"brace": {"west-start": 2, "west-end": 1}},
                15: {"brace": {"west-start": 1, "west-end": 2}},
                18: {"brace": {"east-start": 2, "east-end": 1}},
                19: {"brace": {"east-start": 1, "east-end": 2}},
            },
        },
        {
            "story": [19, 22],
            "section": "HSS254X254X12.7",
            "multi": None,
        },
        {
            "story": [23, 34],
            "section": "HSS203.2X203.2X12.7",
            "multi": None,
        },
    ],
}

Loads are defined in a separate file and imported into the main script. The loads are defined as follows:

loads_and_factors = {
    "load": {
        "all": {
            "ceiling": {
                "dead": 0.083,
                "live": 0.0,
                "snow": 0.0,
                "superimposed_dead": 0.5 * 2,
            },
            "floor": {
                "dead": 2.4,
                "live": 1.9,
                "snow": 0.0,
                "superimposed_dead": 1.2 * 2,
            },
        },
        "modify": {
            "32": {
                "ceiling": {
                    "all": {
                        "dead": 0.083,
                        "live": 1.9,
                        "snow": 0.0,
                        "superimposed_dead": 0.5,
                    }
                },
            },
        },
        "surface_gravity": {
            "south": 5.0,
            "north": 5.0,
            "west": 5.0,
            "east": 5.0,
        },
    },
    "factor": {
        "dead": [1.4, 1.25, 0.9, 1.25, 0.9, 1.25, 0.9, 1.0],
        "live": [0.0, 1.5, 1.5, 1.0, 0.0, 0.5, 0.0, 0.5],
        "snow": [0.0, 1.0, 0.0, 1.5, 1.5, 0.0, 0.5, 0.25],
        "wind": [0.0, 0.0, 0.4, 0.0, 0.4, 1.4, 1.4, 0.0],
        "earthquake": [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0],
    },
}

Lastly, connection properties are defined in a separate file and imported into the main script. The connection properties are defined as follows:

connections = {
    "vertical": {
        "braced-frame": "Annan2009-Rigid",  # Default connection model
        "unbraced-frame": "Annan2009-Rigid",  # Default connection model
    },
    # Default connection model
    "horizontal": {
        "model": "Lawson2014",
        "type": "clip_angle",
        # "location": "corner",
        "location": "point",
        "position_braced": ["ceiling", "floor"],
        "position_unbraced": ["ceiling", "floor"],
    },
}

Once the layout, height, sections, loads, and connections are defined, the building can be created as follows:

import modularbuildingpy as mbpy

# Define the directory where the model will be created
project_path = os.environ["HOME"]
directory = f"{project_path}/tests/test_model"

# Create an instance of the class
# logging options = "debug", "info", "warning", "error", "critical", mode = "w" or "a"
model = mbpy.Model(
    name="CaseStudy32",
    directory=directory,
    analyze_kwargs={"nprocs": 1},
    logger_kwargs={"console": "info", "file": "debug", "mode": "w"},
)
generate = model.get_generate()

generate.layout(layouts=layout,horizontal_spacing=0.35)
generate.height(height=height)
generate.node(base_constraint="pinned")
generate.diaphragm(remove_ceiling=9, remove_floor=9)
generate.geo_transf()
generate.section_material()
generate.element(section=sections)
generate.connection(connection=connections)
generate.load(load_and_factor=loads_and_factors)
generate.partition()

This will create dataframes for nodes, elements, connections, loads, and partitions. These dataframes can be accessed as follows:

# define OpenSeesPy instance
ops = mbpy.OpenSeesPy()

# get the analyze instance from the model
analyze = model.get_analyze()

analyze.initialize_ops()
analyze.declare_global_var()
analyze.assign_section_material()
analyze.assign_geo_transf()
analyze.assign_node()
analyze.assign_diaphragm()
analyze.assign_element()
analyze.add_mass()
analyze.add_gravity()
analyze.run(
    analysis_name="Eigenvalue",
    analysis_type="eigenvalue",
    kwargs_eigenvalue={"num_values": 10},
    time_job=4 * 60,
)