pytabs.case_static_nonlinear_staged

  1# pyTABS - ETABS .NET API python wrapper
  2# CaseStaticNonlinearStaged - cCaseStaticNonlinearStaged
  3__all__ = ['CaseStaticNonlinearStaged']
  4
  5# import ETABS namespace and pyTABS error handler
  6from pytabs.etabs_config import *
  7from pytabs.error_handle import *
  8
  9
 10# import custom enumerations
 11from pytabs.enumerations import (eGeometryNonlinearityType,
 12                                 eLoadApplicationControlType,
 13                                 eDisplacementControlType,
 14                                 eDisplacementMonitorType,
 15                                 eMonitoredDisplacementDoF,
 16                                 eStageOperationType,
 17                                 eStageObjectType,
 18                                 eStageMyType)
 19
 20
 21class CaseStaticNonlinearStaged:
 22    """CaseStaticNonlinearStaged interface"""
 23    def __init__(self, sap_model : etabs.cSapModel) -> None:
 24        # link of SapModel interface
 25        self.sap_model = sap_model
 26        # create interface for static nonlinear staged load cases
 27        self.static_nonlinear_staged = etabs.cCaseStaticNonlinearStaged(sap_model.LoadCases.StaticNonlinearStaged)
 28        
 29        # relate custom enumerations
 30        self.eGeometryNonlinearityTypes = eGeometryNonlinearityType
 31        self.eLoadApplicationControlType = eLoadApplicationControlType
 32        self.eDisplacementControlType = eDisplacementControlType
 33        self.eMonitoredDisplacementType = eDisplacementMonitorType
 34        self.eMonitoredDisplacementDoF = eMonitoredDisplacementDoF
 35        self.eStageOperationType = eStageOperationType
 36        self.eStageObjectType = eStageObjectType
 37        self.eStageMyType = eStageMyType
 38
 39
 40    # TODO - Get Methods
 41
 42
 43    def set_case(self, name : str) -> None:
 44        """Initializes a static nonlinear staged load case.
 45
 46        :param name: name of an existing or new load case
 47        :type name: str
 48        """
 49        handle(self.static_nonlinear_staged.SetCase(name))
 50
 51
 52    def set_geometric_nonlinearity(self, name : str, geometry_nonlinearity_type : eGeometryNonlinearityType) -> None:
 53        """Sets the geometric nonlinearity option for the specified load case.
 54
 55        :param name: name of an existing static nonlinear staged load case
 56        :type name: str
 57        :param geometry_nonlinearity_type: one of load case 
 58        :type geometry_nonlinearity_type: eGeometryNonlinearityTypes
 59        """
 60        handle(self.static_nonlinear_staged.SetGeometricNonlinearity(name, int(geometry_nonlinearity_type)))
 61
 62
 63    # TODO SetHingeUnloading - need to understand types
 64
 65
 66    def set_initial_case(self, name : str, initial_case_name : str) -> None:
 67        """Sets the nonlinear static load case to be considered to contain the initial conditions.
 68
 69        :param name: name of existing nonlinear static staged load case
 70        :type name: str
 71        :param initial_case_name: name of nonlinear static load case to be considered as the initial conditions
 72        :type initial_case_name: str
 73        """
 74        handle(self.static_nonlinear_staged.SetInitialCase(name, initial_case_name))
 75
 76
 77    def set_mass_source(self, name : str, mass_source : str) -> None:
 78        """Sets the mass source for the specified analysis case.
 79
 80        :param name: name of an existing static nonlinear staged load case
 81        :type name: str
 82        :param mass_source: name of an existing mass source
 83        :type mass_source: str
 84        """
 85        handle(self.static_nonlinear_staged.SetMassSource(name, mass_source))
 86
 87
 88    def set_material_nonlinearity(self, name : str, time_dependent_materials : bool = True) -> None:
 89        """Sets the status of time dependent material properties for the specified load case.
 90
 91        :param name: name of an existing static nonlinear staged load case
 92        :type name: str
 93        :param time_dependent_materials: `True` to enable time dependent materials, defaults to True
 94        :type time_dependent_materials: bool, optional
 95        """
 96        handle(self.static_nonlinear_staged.SetMaterialNonlinearity(name, time_dependent_materials))
 97
 98
 99    # TODO SetResultsSaved
100
101    # TODO SetSolControlParameters
102
103
104    def set_stage_data(self, name : str, stage : int, number_operations : int,
105                       operation_types : list[eStageOperationType],
106                       object_types : list[eStageObjectType],
107                       object_names : list[str],
108                       ages : list[float],
109                       my_types : list[eStageMyType],
110                       my_names : list[str],
111                       scaling_factors : list[float]) -> None:
112        """Sets stage data for the specified stage in the specified load case.
113
114        :param name: name of an existing static nonlinear staged load case
115        :type name: str
116        :param stage: stage in the specified load case for which data is to be set
117        :type stage: int
118        :param number_operations: number of operations to set for the specified stage 
119        :type number_operations: int
120        :param operation_types: operation type of each operation
121        :type operation_types: list[eStageOperationType]
122        :param object_types: object type associated with each operation
123        :type object_types: list[eStageObjectType]
124        :param object_names: name of the object associated with each operation
125        :type object_names: list[str]
126        :param ages: ages of the added structure at the time it is added, in days (only applies to .ADD operation types)
127        :type ages: list[float]
128        :param my_types: load type or object type for each operation, depending on operation type (refer CSI ETABS API Manual)
129        :type my_types: list[eStageMyType]
130        :param my_names: load assignment or object name for each operation, depending on operation type (refer CSI ETABS API Manual)
131        :type my_names: list[str]
132        :param scaling_factors:  scale factor for the load assigned to the operation (only applies to .LOAD_NEW and .LOAD_ALL operation types)
133        :type scaling_factors: list[float]
134        """
135        self.__verify_stage_operations(number_operations, operation_types, object_types,
136                                         object_names, ages, my_types, my_names, scaling_factors)
137        operation_types = [operation_type.value for operation_type in operation_types]
138        object_types = [object_type.value for object_type in object_types]
139        my_types = [my_type.value for my_type in my_types]
140        [ret, ret_operation_types, ret_object_types, ret_object_names,
141         ret_ages, ret_my_types, ret_my_names, ret_scaling_factors] = self.static_nonlinear_staged.SetStageData_2(name, stage, number_operations,
142                                                                                                                  operation_types, object_types,
143                                                                                                                  object_names, ages, my_types,
144                                                                                                                  my_names, scaling_factors)
145        handle(ret)
146
147
148    def set_stage_definitions(self, name : str, number_stages : int,
149                              durations : list[float],
150                              output_statuses : list[bool],
151                              output_names : list[str],
152                              comments : list[str]) -> None:
153        """Sets the stage definition data for the specified load case.
154
155        :param name: name of an existing static nonlinear staged load case
156        :type name: str
157        :param number_stages: number of stages to be defined for the specified load case
158        :type number_stages: int
159        :param durations: duration in days for each stage
160        :type durations: list[float]
161        :param output_statuses: `True` or `False`, indicating if analysis output is to be saved for each stage 
162        :type output_statuses: list[bool]
163        :param output_names: user-specified output name for each stage
164        :type output_names: list[str]
165        :param comments: user comment for each stage, may be a blank string
166        :type comments: list[str]
167        """
168        self.__verify_stage_definitions(number_stages, durations, output_statuses, output_names, comments)
169        [ret, ret_durations, ret_output_statuses, 
170         ret_output_names, ret_comments] = self.static_nonlinear_staged.SetStageDefinitions_2(name, number_stages, durations,
171                                                                                              output_statuses, output_names, comments)
172        handle(ret)
173
174
175    def __verify_stage_operations(self, number_operations : int, operation_types : list[eStageOperationType],
176                                  object_types : list[eStageObjectType], object_names : list[str],
177                                  ages : list[float], my_types : list[eStageMyType], my_names : list[str],
178                                  scaling_factors : list[float]) -> None:
179        """Private method for verifying staging details used by method `.set_stage_data`
180        """
181        input_lists = [operation_types, object_types, object_names, ages, my_types, my_names, scaling_factors]
182        if any(len(input_list) != number_operations for input_list in input_lists):
183            raise ValueError('length of all input lists must must be equal to input number_operations')
184        for _o, operation in enumerate(operation_types):
185            # verify object type assignment for operation
186            object_type = object_types[_o]
187            if operation in [eStageOperationType.CHANGE_PROPERTY, eStageOperationType.CHANGE_PROPERTY_MODIFIERS, eStageOperationType.CHANGE_PROPERTY_AGE]:
188                if object_type is eStageObjectType.POINT:
189                    raise ValueError(f'a change property operation can not be applied to a point object - check operation at index {_o+1}')
190                elif (operation is eStageOperationType.CHANGE_PROPERTY_MODIFIERS) and (object_type not in [eStageObjectType.GROUP, eStageObjectType.FRAME,
191                                                                                                           eStageObjectType.CABLE, eStageObjectType.AREA]):
192                    raise ValueError(f'the change property modifiers operation can only be used with group, frame, cable and area objects - check operation at index {_o+1}')
193            elif (operation is eStageOperationType.CHANGE_RELEASES) and (object_type not in [eStageObjectType.GROUP, eStageObjectType.FRAME]):
194                raise ValueError(f'the change releases operation can only be used with group and frame objects - check operation at index {_o+1}')
195            # verify my_type assignments for operation
196            my_type = my_types[_o]
197            my_name = my_names[_o]
198            if operation in [eStageOperationType.LOAD_NEW, eStageOperationType.LOAD_ALL]:
199                if my_type not in [eStageMyType.LOAD, eStageMyType.ACCELERATION]:
200                    raise ValueError(f'my_type must be load or acceleration for the a load operation (new and all) - check operation at index {_o+1}')
201                elif (my_type is eStageMyType.ACCELERATION) and (my_name not in ['UX', 'UY', 'UZ', 'RX', 'RY', 'RZ']):
202                    raise ValueError(f'where load type is acceleration, my name must be UX, UY, UZ, RX, RY or RZ, indicating the direction - check operation at index {_o+1}')
203            elif operation not in [eStageOperationType.ADD_STRUCTURE, eStageOperationType.REMOVE_STRUCTURE]:
204                if object_type is eStageObjectType.GROUP:
205                    if (operation in [eStageOperationType.CHANGE_PROPERTY, eStageOperationType.CHANGE_PROPERTY_AGE]) and (my_type in [eStageMyType.LOAD, eStageMyType.ACCELERATION]):
206                        raise ValueError(f'my_type must be frame, cable, tendon, area, solid or link for a change section property operation (w/wo age) applied to a group - check operation at index {_o+1}')
207                    elif (operation is eStageOperationType.CHANGE_PROPERTY_MODIFIERS) and (my_type not in [eStageMyType.FRAME, eStageMyType.CABLE, eStageMyType.AREA]):
208                        raise ValueError(f'my_type must be frame, cable, or area for a change section property modifiers operation applied to a group - check operation at index {_o+1}')
209                    elif (operation is eStageOperationType.CHANGE_RELEASES) and (my_type is not eStageMyType.FRAME):
210                        raise ValueError(f'my_type must be frame for a change releases operation applied to a group - check operation at index {_o+1}')
211
212
213    def __verify_stage_definitions(self, number_stages : int, durations : list[float], output_statuses : list[bool],
214                                   output_names : list[str], comments : list[str]) -> None:
215        """Private method for verifying stage definitions used by method `.set_stage_definitions`
216        """
217        input_lists = [durations, output_statuses, output_names, comments]
218        if any(len(input_list) != number_stages for input_list in input_lists):
219            raise ValueError('length of all input lists must must be equal to input number_stages')
class CaseStaticNonlinearStaged:
 22class CaseStaticNonlinearStaged:
 23    """CaseStaticNonlinearStaged interface"""
 24    def __init__(self, sap_model : etabs.cSapModel) -> None:
 25        # link of SapModel interface
 26        self.sap_model = sap_model
 27        # create interface for static nonlinear staged load cases
 28        self.static_nonlinear_staged = etabs.cCaseStaticNonlinearStaged(sap_model.LoadCases.StaticNonlinearStaged)
 29        
 30        # relate custom enumerations
 31        self.eGeometryNonlinearityTypes = eGeometryNonlinearityType
 32        self.eLoadApplicationControlType = eLoadApplicationControlType
 33        self.eDisplacementControlType = eDisplacementControlType
 34        self.eMonitoredDisplacementType = eDisplacementMonitorType
 35        self.eMonitoredDisplacementDoF = eMonitoredDisplacementDoF
 36        self.eStageOperationType = eStageOperationType
 37        self.eStageObjectType = eStageObjectType
 38        self.eStageMyType = eStageMyType
 39
 40
 41    # TODO - Get Methods
 42
 43
 44    def set_case(self, name : str) -> None:
 45        """Initializes a static nonlinear staged load case.
 46
 47        :param name: name of an existing or new load case
 48        :type name: str
 49        """
 50        handle(self.static_nonlinear_staged.SetCase(name))
 51
 52
 53    def set_geometric_nonlinearity(self, name : str, geometry_nonlinearity_type : eGeometryNonlinearityType) -> None:
 54        """Sets the geometric nonlinearity option for the specified load case.
 55
 56        :param name: name of an existing static nonlinear staged load case
 57        :type name: str
 58        :param geometry_nonlinearity_type: one of load case 
 59        :type geometry_nonlinearity_type: eGeometryNonlinearityTypes
 60        """
 61        handle(self.static_nonlinear_staged.SetGeometricNonlinearity(name, int(geometry_nonlinearity_type)))
 62
 63
 64    # TODO SetHingeUnloading - need to understand types
 65
 66
 67    def set_initial_case(self, name : str, initial_case_name : str) -> None:
 68        """Sets the nonlinear static load case to be considered to contain the initial conditions.
 69
 70        :param name: name of existing nonlinear static staged load case
 71        :type name: str
 72        :param initial_case_name: name of nonlinear static load case to be considered as the initial conditions
 73        :type initial_case_name: str
 74        """
 75        handle(self.static_nonlinear_staged.SetInitialCase(name, initial_case_name))
 76
 77
 78    def set_mass_source(self, name : str, mass_source : str) -> None:
 79        """Sets the mass source for the specified analysis case.
 80
 81        :param name: name of an existing static nonlinear staged load case
 82        :type name: str
 83        :param mass_source: name of an existing mass source
 84        :type mass_source: str
 85        """
 86        handle(self.static_nonlinear_staged.SetMassSource(name, mass_source))
 87
 88
 89    def set_material_nonlinearity(self, name : str, time_dependent_materials : bool = True) -> None:
 90        """Sets the status of time dependent material properties for the specified load case.
 91
 92        :param name: name of an existing static nonlinear staged load case
 93        :type name: str
 94        :param time_dependent_materials: `True` to enable time dependent materials, defaults to True
 95        :type time_dependent_materials: bool, optional
 96        """
 97        handle(self.static_nonlinear_staged.SetMaterialNonlinearity(name, time_dependent_materials))
 98
 99
100    # TODO SetResultsSaved
101
102    # TODO SetSolControlParameters
103
104
105    def set_stage_data(self, name : str, stage : int, number_operations : int,
106                       operation_types : list[eStageOperationType],
107                       object_types : list[eStageObjectType],
108                       object_names : list[str],
109                       ages : list[float],
110                       my_types : list[eStageMyType],
111                       my_names : list[str],
112                       scaling_factors : list[float]) -> None:
113        """Sets stage data for the specified stage in the specified load case.
114
115        :param name: name of an existing static nonlinear staged load case
116        :type name: str
117        :param stage: stage in the specified load case for which data is to be set
118        :type stage: int
119        :param number_operations: number of operations to set for the specified stage 
120        :type number_operations: int
121        :param operation_types: operation type of each operation
122        :type operation_types: list[eStageOperationType]
123        :param object_types: object type associated with each operation
124        :type object_types: list[eStageObjectType]
125        :param object_names: name of the object associated with each operation
126        :type object_names: list[str]
127        :param ages: ages of the added structure at the time it is added, in days (only applies to .ADD operation types)
128        :type ages: list[float]
129        :param my_types: load type or object type for each operation, depending on operation type (refer CSI ETABS API Manual)
130        :type my_types: list[eStageMyType]
131        :param my_names: load assignment or object name for each operation, depending on operation type (refer CSI ETABS API Manual)
132        :type my_names: list[str]
133        :param scaling_factors:  scale factor for the load assigned to the operation (only applies to .LOAD_NEW and .LOAD_ALL operation types)
134        :type scaling_factors: list[float]
135        """
136        self.__verify_stage_operations(number_operations, operation_types, object_types,
137                                         object_names, ages, my_types, my_names, scaling_factors)
138        operation_types = [operation_type.value for operation_type in operation_types]
139        object_types = [object_type.value for object_type in object_types]
140        my_types = [my_type.value for my_type in my_types]
141        [ret, ret_operation_types, ret_object_types, ret_object_names,
142         ret_ages, ret_my_types, ret_my_names, ret_scaling_factors] = self.static_nonlinear_staged.SetStageData_2(name, stage, number_operations,
143                                                                                                                  operation_types, object_types,
144                                                                                                                  object_names, ages, my_types,
145                                                                                                                  my_names, scaling_factors)
146        handle(ret)
147
148
149    def set_stage_definitions(self, name : str, number_stages : int,
150                              durations : list[float],
151                              output_statuses : list[bool],
152                              output_names : list[str],
153                              comments : list[str]) -> None:
154        """Sets the stage definition data for the specified load case.
155
156        :param name: name of an existing static nonlinear staged load case
157        :type name: str
158        :param number_stages: number of stages to be defined for the specified load case
159        :type number_stages: int
160        :param durations: duration in days for each stage
161        :type durations: list[float]
162        :param output_statuses: `True` or `False`, indicating if analysis output is to be saved for each stage 
163        :type output_statuses: list[bool]
164        :param output_names: user-specified output name for each stage
165        :type output_names: list[str]
166        :param comments: user comment for each stage, may be a blank string
167        :type comments: list[str]
168        """
169        self.__verify_stage_definitions(number_stages, durations, output_statuses, output_names, comments)
170        [ret, ret_durations, ret_output_statuses, 
171         ret_output_names, ret_comments] = self.static_nonlinear_staged.SetStageDefinitions_2(name, number_stages, durations,
172                                                                                              output_statuses, output_names, comments)
173        handle(ret)
174
175
176    def __verify_stage_operations(self, number_operations : int, operation_types : list[eStageOperationType],
177                                  object_types : list[eStageObjectType], object_names : list[str],
178                                  ages : list[float], my_types : list[eStageMyType], my_names : list[str],
179                                  scaling_factors : list[float]) -> None:
180        """Private method for verifying staging details used by method `.set_stage_data`
181        """
182        input_lists = [operation_types, object_types, object_names, ages, my_types, my_names, scaling_factors]
183        if any(len(input_list) != number_operations for input_list in input_lists):
184            raise ValueError('length of all input lists must must be equal to input number_operations')
185        for _o, operation in enumerate(operation_types):
186            # verify object type assignment for operation
187            object_type = object_types[_o]
188            if operation in [eStageOperationType.CHANGE_PROPERTY, eStageOperationType.CHANGE_PROPERTY_MODIFIERS, eStageOperationType.CHANGE_PROPERTY_AGE]:
189                if object_type is eStageObjectType.POINT:
190                    raise ValueError(f'a change property operation can not be applied to a point object - check operation at index {_o+1}')
191                elif (operation is eStageOperationType.CHANGE_PROPERTY_MODIFIERS) and (object_type not in [eStageObjectType.GROUP, eStageObjectType.FRAME,
192                                                                                                           eStageObjectType.CABLE, eStageObjectType.AREA]):
193                    raise ValueError(f'the change property modifiers operation can only be used with group, frame, cable and area objects - check operation at index {_o+1}')
194            elif (operation is eStageOperationType.CHANGE_RELEASES) and (object_type not in [eStageObjectType.GROUP, eStageObjectType.FRAME]):
195                raise ValueError(f'the change releases operation can only be used with group and frame objects - check operation at index {_o+1}')
196            # verify my_type assignments for operation
197            my_type = my_types[_o]
198            my_name = my_names[_o]
199            if operation in [eStageOperationType.LOAD_NEW, eStageOperationType.LOAD_ALL]:
200                if my_type not in [eStageMyType.LOAD, eStageMyType.ACCELERATION]:
201                    raise ValueError(f'my_type must be load or acceleration for the a load operation (new and all) - check operation at index {_o+1}')
202                elif (my_type is eStageMyType.ACCELERATION) and (my_name not in ['UX', 'UY', 'UZ', 'RX', 'RY', 'RZ']):
203                    raise ValueError(f'where load type is acceleration, my name must be UX, UY, UZ, RX, RY or RZ, indicating the direction - check operation at index {_o+1}')
204            elif operation not in [eStageOperationType.ADD_STRUCTURE, eStageOperationType.REMOVE_STRUCTURE]:
205                if object_type is eStageObjectType.GROUP:
206                    if (operation in [eStageOperationType.CHANGE_PROPERTY, eStageOperationType.CHANGE_PROPERTY_AGE]) and (my_type in [eStageMyType.LOAD, eStageMyType.ACCELERATION]):
207                        raise ValueError(f'my_type must be frame, cable, tendon, area, solid or link for a change section property operation (w/wo age) applied to a group - check operation at index {_o+1}')
208                    elif (operation is eStageOperationType.CHANGE_PROPERTY_MODIFIERS) and (my_type not in [eStageMyType.FRAME, eStageMyType.CABLE, eStageMyType.AREA]):
209                        raise ValueError(f'my_type must be frame, cable, or area for a change section property modifiers operation applied to a group - check operation at index {_o+1}')
210                    elif (operation is eStageOperationType.CHANGE_RELEASES) and (my_type is not eStageMyType.FRAME):
211                        raise ValueError(f'my_type must be frame for a change releases operation applied to a group - check operation at index {_o+1}')
212
213
214    def __verify_stage_definitions(self, number_stages : int, durations : list[float], output_statuses : list[bool],
215                                   output_names : list[str], comments : list[str]) -> None:
216        """Private method for verifying stage definitions used by method `.set_stage_definitions`
217        """
218        input_lists = [durations, output_statuses, output_names, comments]
219        if any(len(input_list) != number_stages for input_list in input_lists):
220            raise ValueError('length of all input lists must must be equal to input number_stages')

CaseStaticNonlinearStaged interface

CaseStaticNonlinearStaged(sap_model: ETABSv1.cSapModel)
24    def __init__(self, sap_model : etabs.cSapModel) -> None:
25        # link of SapModel interface
26        self.sap_model = sap_model
27        # create interface for static nonlinear staged load cases
28        self.static_nonlinear_staged = etabs.cCaseStaticNonlinearStaged(sap_model.LoadCases.StaticNonlinearStaged)
29        
30        # relate custom enumerations
31        self.eGeometryNonlinearityTypes = eGeometryNonlinearityType
32        self.eLoadApplicationControlType = eLoadApplicationControlType
33        self.eDisplacementControlType = eDisplacementControlType
34        self.eMonitoredDisplacementType = eDisplacementMonitorType
35        self.eMonitoredDisplacementDoF = eMonitoredDisplacementDoF
36        self.eStageOperationType = eStageOperationType
37        self.eStageObjectType = eStageObjectType
38        self.eStageMyType = eStageMyType
def set_case(self, name: str) -> None:
44    def set_case(self, name : str) -> None:
45        """Initializes a static nonlinear staged load case.
46
47        :param name: name of an existing or new load case
48        :type name: str
49        """
50        handle(self.static_nonlinear_staged.SetCase(name))

Initializes a static nonlinear staged load case.

Parameters
  • name: name of an existing or new load case
def set_geometric_nonlinearity( self, name: str, geometry_nonlinearity_type: pytabs.enumerations.eGeometryNonlinearityType) -> None:
53    def set_geometric_nonlinearity(self, name : str, geometry_nonlinearity_type : eGeometryNonlinearityType) -> None:
54        """Sets the geometric nonlinearity option for the specified load case.
55
56        :param name: name of an existing static nonlinear staged load case
57        :type name: str
58        :param geometry_nonlinearity_type: one of load case 
59        :type geometry_nonlinearity_type: eGeometryNonlinearityTypes
60        """
61        handle(self.static_nonlinear_staged.SetGeometricNonlinearity(name, int(geometry_nonlinearity_type)))

Sets the geometric nonlinearity option for the specified load case.

Parameters
  • name: name of an existing static nonlinear staged load case
  • geometry_nonlinearity_type: one of load case
def set_initial_case(self, name: str, initial_case_name: str) -> None:
67    def set_initial_case(self, name : str, initial_case_name : str) -> None:
68        """Sets the nonlinear static load case to be considered to contain the initial conditions.
69
70        :param name: name of existing nonlinear static staged load case
71        :type name: str
72        :param initial_case_name: name of nonlinear static load case to be considered as the initial conditions
73        :type initial_case_name: str
74        """
75        handle(self.static_nonlinear_staged.SetInitialCase(name, initial_case_name))

Sets the nonlinear static load case to be considered to contain the initial conditions.

Parameters
  • name: name of existing nonlinear static staged load case
  • initial_case_name: name of nonlinear static load case to be considered as the initial conditions
def set_mass_source(self, name: str, mass_source: str) -> None:
78    def set_mass_source(self, name : str, mass_source : str) -> None:
79        """Sets the mass source for the specified analysis case.
80
81        :param name: name of an existing static nonlinear staged load case
82        :type name: str
83        :param mass_source: name of an existing mass source
84        :type mass_source: str
85        """
86        handle(self.static_nonlinear_staged.SetMassSource(name, mass_source))

Sets the mass source for the specified analysis case.

Parameters
  • name: name of an existing static nonlinear staged load case
  • mass_source: name of an existing mass source
def set_material_nonlinearity(self, name: str, time_dependent_materials: bool = True) -> None:
89    def set_material_nonlinearity(self, name : str, time_dependent_materials : bool = True) -> None:
90        """Sets the status of time dependent material properties for the specified load case.
91
92        :param name: name of an existing static nonlinear staged load case
93        :type name: str
94        :param time_dependent_materials: `True` to enable time dependent materials, defaults to True
95        :type time_dependent_materials: bool, optional
96        """
97        handle(self.static_nonlinear_staged.SetMaterialNonlinearity(name, time_dependent_materials))

Sets the status of time dependent material properties for the specified load case.

Parameters
  • name: name of an existing static nonlinear staged load case
  • time_dependent_materials: True to enable time dependent materials, defaults to True
def set_stage_data( self, name: str, stage: int, number_operations: int, operation_types: list[pytabs.enumerations.eStageOperationType], object_types: list[pytabs.enumerations.eStageObjectType], object_names: list[str], ages: list[float], my_types: list[pytabs.enumerations.eStageMyType], my_names: list[str], scaling_factors: list[float]) -> None:
105    def set_stage_data(self, name : str, stage : int, number_operations : int,
106                       operation_types : list[eStageOperationType],
107                       object_types : list[eStageObjectType],
108                       object_names : list[str],
109                       ages : list[float],
110                       my_types : list[eStageMyType],
111                       my_names : list[str],
112                       scaling_factors : list[float]) -> None:
113        """Sets stage data for the specified stage in the specified load case.
114
115        :param name: name of an existing static nonlinear staged load case
116        :type name: str
117        :param stage: stage in the specified load case for which data is to be set
118        :type stage: int
119        :param number_operations: number of operations to set for the specified stage 
120        :type number_operations: int
121        :param operation_types: operation type of each operation
122        :type operation_types: list[eStageOperationType]
123        :param object_types: object type associated with each operation
124        :type object_types: list[eStageObjectType]
125        :param object_names: name of the object associated with each operation
126        :type object_names: list[str]
127        :param ages: ages of the added structure at the time it is added, in days (only applies to .ADD operation types)
128        :type ages: list[float]
129        :param my_types: load type or object type for each operation, depending on operation type (refer CSI ETABS API Manual)
130        :type my_types: list[eStageMyType]
131        :param my_names: load assignment or object name for each operation, depending on operation type (refer CSI ETABS API Manual)
132        :type my_names: list[str]
133        :param scaling_factors:  scale factor for the load assigned to the operation (only applies to .LOAD_NEW and .LOAD_ALL operation types)
134        :type scaling_factors: list[float]
135        """
136        self.__verify_stage_operations(number_operations, operation_types, object_types,
137                                         object_names, ages, my_types, my_names, scaling_factors)
138        operation_types = [operation_type.value for operation_type in operation_types]
139        object_types = [object_type.value for object_type in object_types]
140        my_types = [my_type.value for my_type in my_types]
141        [ret, ret_operation_types, ret_object_types, ret_object_names,
142         ret_ages, ret_my_types, ret_my_names, ret_scaling_factors] = self.static_nonlinear_staged.SetStageData_2(name, stage, number_operations,
143                                                                                                                  operation_types, object_types,
144                                                                                                                  object_names, ages, my_types,
145                                                                                                                  my_names, scaling_factors)
146        handle(ret)

Sets stage data for the specified stage in the specified load case.

Parameters
  • name: name of an existing static nonlinear staged load case
  • stage: stage in the specified load case for which data is to be set
  • number_operations: number of operations to set for the specified stage
  • operation_types: operation type of each operation
  • object_types: object type associated with each operation
  • object_names: name of the object associated with each operation
  • ages: ages of the added structure at the time it is added, in days (only applies to .ADD operation types)
  • my_types: load type or object type for each operation, depending on operation type (refer CSI ETABS API Manual)
  • my_names: load assignment or object name for each operation, depending on operation type (refer CSI ETABS API Manual)
  • scaling_factors: scale factor for the load assigned to the operation (only applies to .LOAD_NEW and .LOAD_ALL operation types)
def set_stage_definitions( self, name: str, number_stages: int, durations: list[float], output_statuses: list[bool], output_names: list[str], comments: list[str]) -> None:
149    def set_stage_definitions(self, name : str, number_stages : int,
150                              durations : list[float],
151                              output_statuses : list[bool],
152                              output_names : list[str],
153                              comments : list[str]) -> None:
154        """Sets the stage definition data for the specified load case.
155
156        :param name: name of an existing static nonlinear staged load case
157        :type name: str
158        :param number_stages: number of stages to be defined for the specified load case
159        :type number_stages: int
160        :param durations: duration in days for each stage
161        :type durations: list[float]
162        :param output_statuses: `True` or `False`, indicating if analysis output is to be saved for each stage 
163        :type output_statuses: list[bool]
164        :param output_names: user-specified output name for each stage
165        :type output_names: list[str]
166        :param comments: user comment for each stage, may be a blank string
167        :type comments: list[str]
168        """
169        self.__verify_stage_definitions(number_stages, durations, output_statuses, output_names, comments)
170        [ret, ret_durations, ret_output_statuses, 
171         ret_output_names, ret_comments] = self.static_nonlinear_staged.SetStageDefinitions_2(name, number_stages, durations,
172                                                                                              output_statuses, output_names, comments)
173        handle(ret)

Sets the stage definition data for the specified load case.

Parameters
  • name: name of an existing static nonlinear staged load case
  • number_stages: number of stages to be defined for the specified load case
  • durations: duration in days for each stage
  • output_statuses: True or False, indicating if analysis output is to be saved for each stage
  • output_names: user-specified output name for each stage
  • comments: user comment for each stage, may be a blank string