コード例 #1
0
 def optimize_member_for_drift(self):
     """
     This method is used to decrease the member size such that the design is most economic.
     :return: update self.member_size
     """
     # Find the story which has the smallest drift
     target_story = np.where(self.elastic_response['story drift'] ==
                             np.min(self.elastic_response['story drift']))[0][0]
     # Update the interior column size in target story
     self.member_size['interior column'][target_story] = \
         decrease_member_size(self.element_candidate['interior column']['story %s' % (target_story + 1)],
                              self.member_size['interior column'][target_story])
     # Compute the section property of the interior column size
     reference_property = search_section_property(self.member_size['interior column'][target_story],
                                                  SECTION_DATABASE)
     # Determine the beam size based on beam-to-column section modulus ratio
     beam_size = search_member_size('Zx', reference_property['Zx'] * BEAM_TO_COLUMN_RATIO,
                                    self.element_candidate['beam']['floor level %s' % (target_story + 2)],
                                    SECTION_DATABASE)
     # "Push" the updated beam size back to the class dictionary
     self.member_size['beam'][target_story] = beam_size
     # Determine the exterior column size based on exterior/interior column moment of inertia ratio
     exterior_size = search_member_size('Ix', reference_property['Ix'] * EXTERIOR_INTERIOR_COLUMN_RATIO,
                                        self.element_candidate['exterior column']['story %s' % (target_story + 1)],
                                        SECTION_DATABASE)
     self.member_size['exterior column'][target_story] = exterior_size
コード例 #2
0
 def initialize_member(self):
     """
     This method is used to initialize the member size
     :return: a dictionary which includes the initial size for interior columns, exterior columns, and beams
     """
     # Define initial sizes for columns and beams
     interior_column = []
     exterior_column = []
     beam = []
     for story in range(0, self.geometry['number of story']):
         # The initial column is selected as the greatest sizes in the candidate pool
         initial_interior = self.element_candidate['interior column']['story %s' % (story + 1)][0]
         initial_exterior = self.element_candidate['exterior column']['story %s' % (story + 1)][0]
         # Merge initial size of each story together
         interior_column.append(initial_interior)
         exterior_column.append(initial_exterior)
         # Compute the section property of the interior column size
         reference_property = search_section_property(initial_interior, SECTION_DATABASE)
         # Determine the beam size based on beam-to-column section modulus ratio
         beam_size = search_member_size('Zx', reference_property['Zx'] * BEAM_TO_COLUMN_RATIO,
                                        self.element_candidate['beam']['floor level %s' % (story + 2)],
                                        SECTION_DATABASE)
         # Merge initial beam size of each story together
         beam.append(beam_size)
     # Store all initial member sizes into the dictionary (which will be updated using optimization algorithm later)
     self.member_size = {'interior column': interior_column,
                         'exterior column': exterior_column,
                         'beam': beam}
コード例 #3
0
ファイル: beam_component.py プロジェクト: adane12/ada
    def __init__(self, section_size, length, shear_demand, moment_demand_left,
                 moment_demand_right, steel):
        """
        This function initializes the attributes of the beam class.
        :param section_size: a string specifying the section size for the beam.
        :param length: a float number denoting the beam length.
        :param shear_demand: a float number denoting the shear demand.
        :param moment_demand_left: a float number denoting the moment demand at right end.
        :param moment_demand_right: a float number denoting the moment demand at left end.
        """
        # Assign the necessary information for column class
        self.section = search_section_property(section_size, SECTION_DATABASE)
        self.demand = {
            'shear': shear_demand,
            'moment left': moment_demand_left,
            'moment right': moment_demand_right
        }
        self.length = length

        # Initialize the following variables
        self.RBS_dimension = {
        }  # a dictionary used to store the dimensions for reduced beam section
        self.spacing = None  # a scalar indicating the spacing between two lateral supports
        self.strength = {
        }  # a dictionary used to store the strength of beam component
        self.demand_capacity_ratio = {
        }  # a dictionary to store the demand to capacity ratio
        self.is_feasible = {
        }  # a dictionary used to store the failure mode of beam (if any)
        # Define a boolean flag which denotes the overall check results
        self.flag = None

        # Define a hinge dictionary to store all modeling parameters
        self.plastic_hinge = {}

        # Using the following methods to compute strength and check whether strength is sufficient
        self.initialize_reduced_beam_section()
        self.check_flange(steel)
        self.check_web(steel)
        self.determine_spacing_between_lateral_support(steel)
        self.check_shear_strength(steel)
        self.check_flexural_strength(steel)
        self.compute_demand_capacity_ratio()
        self.calculate_hinge_parameters(steel)
コード例 #4
0
    def __init__(self, section_size, axial_demand, shear_demand,
                 moment_demand_bot, moment_demand_top, Lx, Ly, steel):
        """
        This function initializes the attributes of class of column.
        :param section_size: a string which specifies the size for column.
        :param axial_demand: a float number which describes axial demand.
        :param shear_demand: a float number which describes shear demand.
        :param moment_demand_bot: a float number which describes moment demand at bottom of column.
        :param moment_demand_top: a float number which describes moment demand at top of column.
        :param Lx: unbraced length in x direction.
        :param Ly: unbraced length in y direction.
        """
        # Assign the necessary information for column class
        self.section = search_section_property(section_size, SECTION_DATABASE)
        self.demand = {
            'axial': axial_demand,
            'shear': shear_demand,
            'moment bottom': moment_demand_bot,
            'moment top': moment_demand_top
        }
        self.unbraced_length = {'x': Lx, 'y': Ly}

        # Initialize the strength dictionary with an empty dictionary
        self.strength = {}
        # Initialize the dictionary to denote the possible failure mode (if any) of column
        self.is_feasible = {}
        # Initialize the dictionary to indicate the demand to capacity ratios
        self.demand_capacity_ratio = {}
        # Define a boolean flag to indicate the overall check results.
        self.flag = None

        # Define a hinge dictionary to store each parameters of OpenSees bilinear property
        self.plastic_hinge = {}

        # Using the following method to compute the strength and check whether strength is sufficient
        self.check_flange(steel)
        self.check_web(steel)
        self.check_axial_strength(steel)
        self.check_shear_strength(steel)
        self.check_flexural_strength(steel)
        self.check_combined_loads()
        self.compute_demand_capacity_ratio()
        self.calculate_hinge_parameters(steel)