diff --git a/Examples/Cantilever/Demo1.py b/Examples/Cantilever/Demo1.py index 2c052f10..591a3396 100644 --- a/Examples/Cantilever/Demo1.py +++ b/Examples/Cantilever/Demo1.py @@ -8,7 +8,6 @@ print('dirname: ', dirName) sys.path.append(dirName + r'/../..') -# Import der Bibliotheken from RFEM.enums import NodalSupportType, LoadDirectionType from RFEM.initModel import Model, Calculate_all from RFEM.BasicObjects.material import Material @@ -39,9 +38,9 @@ NodalSupport(1, '1', NodalSupportType.FIXED) - StaticAnalysisSettings.GeometricallyLinear(0, 1, "Linear") - StaticAnalysisSettings.SecondOrderPDelta(0, 2, "SecondOrder") - StaticAnalysisSettings.LargeDeformation(0, 3, "LargeDeformation") + StaticAnalysisSettings.GeometricallyLinear(1, "Linear") + StaticAnalysisSettings.SecondOrderPDelta(2, "SecondOrder") + StaticAnalysisSettings.LargeDeformation(3, "LargeDeformation") LoadCase(1, 'Self-Weight', [True, 0.0, 0.0, 1.0]) diff --git a/Examples/Hall/hall.py b/Examples/Hall/hall.py index 522a1620..60e71177 100644 --- a/Examples/Hall/hall.py +++ b/Examples/Hall/hall.py @@ -64,7 +64,7 @@ Member(4*n+i, j+2, j+7, 0.0, 2, 2) Member(4*n+i + n-1, j+4, j+9, 0.0, 2, 2) -# vertical bracing + # vertical bracing # add a question about repeating in every block, one yes one no, only beginning and end BracingV = input('Would you like to include vertical bracing? (Y/N)') @@ -91,13 +91,13 @@ k = n*4+(n-1)*2 for i in range(n): if i in (0, n-2): - Member.Tension(0, k+1+4*i, i*5+1, i*5+7, + Member.Tension(k+1+4*i, i*5+1, i*5+7, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) - Member.Tension(0, k+2+4*i, i*5+2, i*5+6, + Member.Tension(k+2+4*i, i*5+2, i*5+6, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) - Member.Tension(0, k+3+4*i, i*5+5, i*5+9, + Member.Tension(k+3+4*i, i*5+5, i*5+9, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) - Member.Tension(0, k+4+4*i, i*5+4, i*5+10, + Member.Tension(k+4+4*i, i*5+4, i*5+10, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) # MAKE IT MORE GENERAL! @@ -111,13 +111,13 @@ k = 4*n + 2*(n-1) for i in range(n): if i % 2 == 0: - Member.Tension(0, k+1+4*i, i*5+1, i*5+7, + Member.Tension(k+1+4*i, i*5+1, i*5+7, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) - Member.Tension(0, k+2+4*i, i*5+2, i*5+6, + Member.Tension(k+2+4*i, i*5+2, i*5+6, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) - Member.Tension(0, k+3+4*i, i*5+5, i*5+9, + Member.Tension(k+3+4*i, i*5+5, i*5+9, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) - Member.Tension(0, k+4+4*i, i*5+4, i*5+10, + Member.Tension(k+4+4*i, i*5+4, i*5+10, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 3) # horizontal bracing diff --git a/Examples/TrussGenerator_2D/TrussGenerator.py b/Examples/TrussGenerator_2D/TrussGenerator.py index d850fd9e..92614d2a 100644 --- a/Examples/TrussGenerator_2D/TrussGenerator.py +++ b/Examples/TrussGenerator_2D/TrussGenerator.py @@ -796,7 +796,7 @@ def click(self): i = 1 j = 1 while j QualityCriteriaConfigForSurfaces if key == 'QualityCriteriaConfigForSurfaces': for key_ in surfaceConfig['QualityCriteriaConfigForSurfaces']: if surfaceConfig['QualityCriteriaConfigForSurfaces'][key_]: @@ -139,7 +138,6 @@ def __init__(self, elif surfaceConfig[key]: clientObject['SurfacesMeshQualityConfig'][key] = surfaceConfig[key] for key in solidConfig: - # QualityCriteriaConfig -> QualityCriteriaConfigForSolids if key == 'QualityCriteriaConfigForSolids': for key_ in solidConfig['QualityCriteriaConfigForSolids']: if solidConfig['QualityCriteriaConfigForSolids'][key_]: @@ -154,7 +152,8 @@ def __init__(self, # Add Mesh Settings to client model Model.clientModel.service.set_mesh_settings(clientObject) - def set_mesh_settings(self, all_settings): + @staticmethod + def set_mesh_settings(all_settings): new_sett = {} for i in all_settings: diff --git a/RFEM/Calculate/optimizationSettings.py b/RFEM/Calculate/optimizationSettings.py index a3a028d9..8dd11761 100644 --- a/RFEM/Calculate/optimizationSettings.py +++ b/RFEM/Calculate/optimizationSettings.py @@ -30,8 +30,10 @@ def __init__(self, # Set Optimization settings to client model Model.clientModel.service.set_optimization_settings(opt_settings) - def get_optimization_settings(self): + @staticmethod + def get_optimization_settings(): return Model.clientModel.service.get_optimization_settings() - def set_optimization_settings(self, opt_settings): + @staticmethod + def set_optimization_settings(opt_settings): Model.clientModel.service.set_optimization_settings(opt_settings) \ No newline at end of file diff --git a/RFEM/ConcreteDesign/ConcreteServiceabilityConfigurations.py b/RFEM/ConcreteDesign/ConcreteServiceabilityConfigurations.py index 1c822113..44bf39ab 100644 --- a/RFEM/ConcreteDesign/ConcreteServiceabilityConfigurations.py +++ b/RFEM/ConcreteDesign/ConcreteServiceabilityConfigurations.py @@ -12,7 +12,7 @@ def __init__(self, surface_sets = '', nodes = '', comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Configuration Tag @@ -23,7 +23,7 @@ def __init__(self, surface_sets (str): Assigned Surface Sets nodes (str): Assigned Nodes comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Concrete Durabilities @@ -58,8 +58,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Global Parameter to client model Model.clientModel.service.set_sls_configuration(clientObject) \ No newline at end of file diff --git a/RFEM/ConcreteDesign/ConcreteUltimateConfigurations.py b/RFEM/ConcreteDesign/ConcreteUltimateConfigurations.py index 7896e7c9..d80a5b73 100644 --- a/RFEM/ConcreteDesign/ConcreteUltimateConfigurations.py +++ b/RFEM/ConcreteDesign/ConcreteUltimateConfigurations.py @@ -12,7 +12,7 @@ def __init__(self, surface_sets = '', nodes = '', comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Configuration Tag @@ -23,7 +23,7 @@ def __init__(self, surface_sets (str): Assigned Surface Sets nodes (str): Assigned Nodes comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Concrete Durabilities @@ -58,8 +58,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Global Parameter to client model Model.clientModel.service.set_uls_configuration(clientObject) \ No newline at end of file diff --git a/RFEM/Imperfections/imperfectionCase.py b/RFEM/Imperfections/imperfectionCase.py index 1366d131..38ff6257 100644 --- a/RFEM/Imperfections/imperfectionCase.py +++ b/RFEM/Imperfections/imperfectionCase.py @@ -5,13 +5,13 @@ def __init__(self, no: int = 1, assigned_to_load_cases: str = '1', comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: no (int): Imperfection Case Tag comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Imperfection Case @@ -30,8 +30,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Imperfection Case to client model Model.clientModel.service.set_imperfection_case(clientObject) diff --git a/RFEM/LoadCasesAndCombinations/designSituation.py b/RFEM/LoadCasesAndCombinations/designSituation.py index 626e0362..24638914 100644 --- a/RFEM/LoadCasesAndCombinations/designSituation.py +++ b/RFEM/LoadCasesAndCombinations/designSituation.py @@ -8,7 +8,7 @@ def __init__(self, active: bool = True, design_situation_type: int = 6122, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: @@ -47,7 +47,7 @@ def __init__(self, 6194 = SLS - Frequent, 6195 = SLS - Quasi-permanent. comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Design Situation @@ -76,8 +76,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Design Situation to client model Model.clientModel.service.set_design_situation(clientObject) diff --git a/RFEM/LoadCasesAndCombinations/loadCase.py b/RFEM/LoadCasesAndCombinations/loadCase.py index a11d02a3..66e28807 100644 --- a/RFEM/LoadCasesAndCombinations/loadCase.py +++ b/RFEM/LoadCasesAndCombinations/loadCase.py @@ -16,7 +16,7 @@ def __init__(self, name: str = 'Self-weight', self_weight: list = [True, 0.0, 0.0, 1.0], comment: str = 'Comment', - params: dict = {}): + params: dict = None): ''' Args: no (int): Load Case Tag @@ -24,7 +24,7 @@ def __init__(self, self_weight (list): Self-Weight Parameters self_weight = [self_weight_active, self_weight_factor_x, self_weight_factor_y, self_weight_factor_z] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Load Case @@ -67,13 +67,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Case to client model Model.clientModel.service.set_load_case(clientObject) - def StaticAnalysis(self, + @staticmethod + def StaticAnalysis( no: int = 1, name: str = 'Self-weight', to_solve: bool = True, @@ -81,7 +83,7 @@ def StaticAnalysis(self, action_category= DIN_Action_Category['1A'], self_weight = [True, 0.0, 0.0, 10.0], comment: str = 'Comment', - params: dict = {}): + params: dict = None): ''' Args: no (int): Load Case Tag @@ -117,7 +119,7 @@ def StaticAnalysis(self, for no self-weight considerations; self_weight = [False] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Load Case @@ -160,8 +162,9 @@ def StaticAnalysis(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Case to client model Model.clientModel.service.set_load_case(clientObject) diff --git a/RFEM/LoadCasesAndCombinations/loadCombination.py b/RFEM/LoadCasesAndCombinations/loadCombination.py index ab89d363..19a08cf3 100644 --- a/RFEM/LoadCasesAndCombinations/loadCombination.py +++ b/RFEM/LoadCasesAndCombinations/loadCombination.py @@ -14,7 +14,7 @@ def __init__(self, to_solve: bool = True, combination_items = [[1.5, 1, 0, False]], comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Load Combination clientObject = Model.clientModel.factory.create('ns0:load_combination') @@ -55,8 +55,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Items clientObject.items = Model.clientModel.factory.create('ns0:load_combination.items') diff --git a/RFEM/LoadCasesAndCombinations/modalAnalysisSettings.py b/RFEM/LoadCasesAndCombinations/modalAnalysisSettings.py index b3bbae34..2d90a469 100644 --- a/RFEM/LoadCasesAndCombinations/modalAnalysisSettings.py +++ b/RFEM/LoadCasesAndCombinations/modalAnalysisSettings.py @@ -12,7 +12,7 @@ def __init__(self, acting_masses = [], neglect_masses = ModalNeglectMasses.E_NEGLECT_MASSES_NO_NEGLECTION, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Setting Tag @@ -24,7 +24,7 @@ def __init__(self, acting_masses (list): Acting Masses Directions List neglect_masses (enum): Neglect Masses Enumeration comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface clientObject = Model.clientModel.factory.create('ns0:modal_analysis_settings') @@ -70,8 +70,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Static Analysis Settings to client model Model.clientModel.service.set_modal_analysis_settings(clientObject) diff --git a/RFEM/LoadCasesAndCombinations/resultCombination.py b/RFEM/LoadCasesAndCombinations/resultCombination.py index 4428fab8..3270be88 100644 --- a/RFEM/LoadCasesAndCombinations/resultCombination.py +++ b/RFEM/LoadCasesAndCombinations/resultCombination.py @@ -4,13 +4,13 @@ class ResultCombination(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: no (int): Result Combination Tag comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Result Combination @@ -26,8 +26,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Result Combination to client model Model.clientModel.service.set_result_combination(clientObject) diff --git a/RFEM/LoadCasesAndCombinations/spectralAnalysisSettings.py b/RFEM/LoadCasesAndCombinations/spectralAnalysisSettings.py index 77102190..34ba2637 100644 --- a/RFEM/LoadCasesAndCombinations/spectralAnalysisSettings.py +++ b/RFEM/LoadCasesAndCombinations/spectralAnalysisSettings.py @@ -14,7 +14,7 @@ def __init__(self, damping_for_cqc_rule = CqsDampingRule.CONSTANT_FOR_EACH_MODE, constant_d_for_each_mode: float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -29,7 +29,7 @@ def __init__(self, damping_for_cqc_rule (enum): Cqs Damping Rule Enumeration constant_d_for_each_mode (float): Constant d for Each Mode comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Surface @@ -76,7 +76,8 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Static Analysis Settings to client model Model.clientModel.service.set_spectral_analysis_settings(clientObject) diff --git a/RFEM/LoadCasesAndCombinations/stabilityAnalysisSettings.py b/RFEM/LoadCasesAndCombinations/stabilityAnalysisSettings.py index 529cedcb..8c0f61fc 100644 --- a/RFEM/LoadCasesAndCombinations/stabilityAnalysisSettings.py +++ b/RFEM/LoadCasesAndCombinations/stabilityAnalysisSettings.py @@ -8,13 +8,13 @@ def __init__(self, no: int = 1, name: str = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: no (int): Stability Analysis Setting Tag name (str): Stability Analysis Setting Name comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Stability Analysis Settings @@ -47,13 +47,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Stability Analysis Settings to client model Model.clientModel.service.set_stability_analysis_settings(clientObject) - def EigenvalueMethod(self, + @staticmethod + def EigenvalueMethod( no: int = 1, name: str = None, number_of_lowest_eigenvalues: int = 4, @@ -64,7 +66,7 @@ def EigenvalueMethod(self, eigenvalue_method = StabilityAnalysisSettingsEigenvalueMethod.EIGENVALUE_METHOD_LANCZOS, matrix_type = StabilityAnalysisSettingsMatrixType.MATRIX_TYPE_STANDARD, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: no (int): Stability Analysis Setting Tag @@ -140,13 +142,15 @@ def EigenvalueMethod(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Stability Analysis Settings to client model Model.clientModel.service.set_stability_analysis_settings(clientObject) - def IncrementalyMethodWithEigenvalue(self, + @staticmethod + def IncrementalyMethodWithEigenvalue( no: int = 1, name: str = None, number_of_lowest_eigenvalues: int = 4, @@ -160,7 +164,7 @@ def IncrementalyMethodWithEigenvalue(self, eigenvalue_method = StabilityAnalysisSettingsEigenvalueMethod.EIGENVALUE_METHOD_LANCZOS, matrix_type = StabilityAnalysisSettingsMatrixType.MATRIX_TYPE_STANDARD, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: no (int): Stability Analysis Setting Tag @@ -206,7 +210,7 @@ def IncrementalyMethodWithEigenvalue(self, eigenvalue_method (enum): Eigenvalue Method Enumeration matrix_type (enum): Matrix Type Enumeration comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Stability Analysis Settings clientObject = Model.clientModel.factory.create('ns0:stability_analysis_settings') @@ -280,13 +284,15 @@ def IncrementalyMethodWithEigenvalue(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Stability Analysis Settings to client model Model.clientModel.service.set_stability_analysis_settings(clientObject) - def IncrementalyMethodWithoutEigenvalue(self, + @staticmethod + def IncrementalyMethodWithoutEigenvalue( no: int = 1, name: str = None, minimum_initial_strain = 1e-05, @@ -295,7 +301,7 @@ def IncrementalyMethodWithoutEigenvalue(self, stopping_of_load_increasing = None, save_results_of_all_increments: bool = False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: no (int): Stability Analysis Setting Tag @@ -332,7 +338,7 @@ def IncrementalyMethodWithoutEigenvalue(self, stopping_of_load_increasing = [StabilityAnalysisSettingsStoppingOfLoadIncreasingResult.RESULT_TYPE_ROTATION_PHI_Z, limit_result_rotation, limit_node] save_results_of_all_increments (bool, optional): Save Results of All Increments comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Stability Analysis Settings clientObject = Model.clientModel.factory.create('ns0:stability_analysis_settings') @@ -389,8 +395,9 @@ def IncrementalyMethodWithoutEigenvalue(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Stability Analysis Settings to client model Model.clientModel.service.set_stability_analysis_settings(clientObject) diff --git a/RFEM/LoadCasesAndCombinations/staticAnalysisSettings.py b/RFEM/LoadCasesAndCombinations/staticAnalysisSettings.py index 768678bf..eb261370 100644 --- a/RFEM/LoadCasesAndCombinations/staticAnalysisSettings.py +++ b/RFEM/LoadCasesAndCombinations/staticAnalysisSettings.py @@ -9,7 +9,7 @@ def __init__(self, name: str = None, analysis_type=StaticAnalysisType.GEOMETRICALLY_LINEAR, comment: str = '', - params: dict = {}): + params: dict = []): """ Args: no (int): Static Analysis Setting Tag @@ -38,13 +38,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Static Analysis Settings to client model Model.clientModel.service.set_static_analysis_settings(clientObject) - def GeometricallyLinear(self, + @staticmethod + def GeometricallyLinear( no: int = 1, name: str = None, load_modification = [False, 1, False], @@ -54,7 +56,7 @@ def GeometricallyLinear(self, plate_bending_theory = StaticAnalysisSettingsPlateBendingTheory.PLATE_BENDING_THEORY_MINDLIN, mass_conversion = [False, 0, 0, 0], comment: str = '', - params: dict = {}): + params: dict = []): """ Args: @@ -122,13 +124,15 @@ def GeometricallyLinear(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Static Analysis Settings to client model Model.clientModel.service.set_static_analysis_settings(clientObject) - def LargeDeformation(self, + @staticmethod + def LargeDeformation( no: int = 1, name: str = None, iterative_method = StaticAnalysisSettingsIterativeMethodForNonlinearAnalysis.NEWTON_RAPHSON, @@ -165,7 +169,7 @@ def LargeDeformation(self, mass_conversion (list, optional): Mass Conversion Parameters mass_conversion = [mass_conversion_enabled, mass_conversion_factor_in_direction_x, mass_conversion_factor_in_direction_y, mass_conversion_factor_in_direction_z] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model @@ -243,13 +247,15 @@ def LargeDeformation(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Static Analysis Settings to client model Model.clientModel.service.set_static_analysis_settings(clientObject) - def SecondOrderPDelta(self, + @staticmethod + def SecondOrderPDelta( no: int = 1, name: str = None, iterative_method = StaticAnalysisSettingsIterativeMethodForNonlinearAnalysis.NEWTON_RAPHSON, @@ -264,7 +270,7 @@ def SecondOrderPDelta(self, plate_bending_theory = StaticAnalysisSettingsPlateBendingTheory.PLATE_BENDING_THEORY_MINDLIN, mass_conversion = [False, 0, 0, 1], comment: str = '', - params: dict = {}): + params: dict = []): """ Args: no (int): Static Analysis Setting Tag @@ -361,8 +367,9 @@ def SecondOrderPDelta(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Static Analysis Settings to client model Model.clientModel.service.set_static_analysis_settings(clientObject) diff --git a/RFEM/Loads/freeLoad.py b/RFEM/Loads/freeLoad.py index 3812f214..49fb7629 100644 --- a/RFEM/Loads/freeLoad.py +++ b/RFEM/Loads/freeLoad.py @@ -7,7 +7,8 @@ class FreeLoad(): - def ConcentratedLoad(self, + @staticmethod + def ConcentratedLoad( no: int = 1, load_case_no: int = 1, surfaces_no = '1', @@ -16,7 +17,7 @@ def ConcentratedLoad(self, load_direction = FreeConcentratedLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z, load_parameter = [1000, 0, 0], comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -34,7 +35,7 @@ def ConcentratedLoad(self, for load_projection == FreeLoadLoadProjection.LOAD_PROJECTION_XZ_OR_UW: load_parameter = [magnitude, X, Z] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Free Concentrated Load @@ -72,13 +73,15 @@ def ConcentratedLoad(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Free Concentrated Load to client model Model.clientModel.service.set_free_concentrated_load(load_case_no, clientObject) - def LineLoad(self, + @staticmethod + def LineLoad( no: int = 1, load_case_no: int = 1, surfaces_no = '1', @@ -87,7 +90,7 @@ def LineLoad(self, load_direction = FreeLineLoadLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -103,7 +106,7 @@ def LineLoad(self, for load_distribution == FreeLineLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR: load_parameter = [magnitude_first, magnitude_second, load_location_first_x, load_location_first_y, load_location_second_x, load_location_second_y] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Free Concentrated Load @@ -153,13 +156,15 @@ def LineLoad(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Free Concentrated Load to client model Model.clientModel.service.set_free_line_load(load_case_no, clientObject) - def RectangularLoad(self, + @staticmethod + def RectangularLoad( no: int = 1, load_case_no: int = 1, surfaces_no = '1', @@ -170,7 +175,7 @@ def RectangularLoad(self, load_location = FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CORNER_POINTS, load_location_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -206,7 +211,7 @@ def RectangularLoad(self, for load_distribution == FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z_AND_ALONG_PERIMETER: load_location_parameter = [load_location_center_x, load_location_center_y, load_location_center_side_a, load_location_center_side_b, [[distance, factor], ...], [axis_definition_p1_x, axis_definition_p1_y, axis_definition_p1_z], [axis_definition_p2_x, axis_definition_p2_y, axis_definition_p2_z], axis_start_angle,[[alpha, factor], ...] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Free Concentrated Load @@ -424,13 +429,15 @@ def RectangularLoad(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Free Concentrated Load to client model Model.clientModel.service.set_free_rectangular_load(load_case_no, clientObject) - def CircularLoad(self, + @staticmethod + def CircularLoad( no: int = 1, load_case_no: int = 1, surfaces_no = '1', @@ -439,7 +446,7 @@ def CircularLoad(self, load_direction = FreeCircularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -455,7 +462,7 @@ def CircularLoad(self, for load_distribution == FreeCircularLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR: load_parameter = [magnitude_center, magnitude_radius, load_location_x, load_location_y, load_location_radius] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Free Concentrated Load @@ -504,13 +511,15 @@ def CircularLoad(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Free Concentrated Load to client model Model.clientModel.service.set_free_circular_load(load_case_no, clientObject) - def PolygonLoad(self, + @staticmethod + def PolygonLoad( no: int = 1, load_case_no: int = 1, surfaces_no = '1', @@ -520,7 +529,7 @@ def PolygonLoad(self, load_location = [], load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -545,7 +554,7 @@ def PolygonLoad(self, load_location = [[first_coordinate, second_coordinate], ...] load_parameter = [magnitude_linear_1, magnitude_linear_2, magnitude_linear_location_1, magnitude_linear_location_2] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Free Concentrated Load @@ -609,8 +618,9 @@ def PolygonLoad(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Free Concentrated Load to client model Model.clientModel.service.set_free_polygon_load(load_case_no, clientObject) diff --git a/RFEM/Loads/imposedLineDeformation.py b/RFEM/Loads/imposedLineDeformation.py index f7ea8567..a9daf468 100644 --- a/RFEM/Loads/imposedLineDeformation.py +++ b/RFEM/Loads/imposedLineDeformation.py @@ -37,8 +37,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Nodal Support to client model Model.clientModel.service.set_imposed_line_deformation(load_case_no, clientObject) diff --git a/RFEM/Loads/imposedNodalDeformation.py b/RFEM/Loads/imposedNodalDeformation.py index da5d7679..12453f3a 100644 --- a/RFEM/Loads/imposedNodalDeformation.py +++ b/RFEM/Loads/imposedNodalDeformation.py @@ -8,7 +8,7 @@ def __init__(self, node_no: str = '1', load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' load_parameter: load_parameter = [imposed_displacement_x, imposed_displacement_y, imposed_displacement_z, imposed_rotation_x, imposed_rotation_y imposed_rotation_z] @@ -42,8 +42,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Imposed Nodal Deformation to client model Model.clientModel.service.set_imposed_nodal_deformation(load_case_no, clientObject) diff --git a/RFEM/Loads/lineLoad.py b/RFEM/Loads/lineLoad.py index 71e6e56c..90728a74 100644 --- a/RFEM/Loads/lineLoad.py +++ b/RFEM/Loads/lineLoad.py @@ -10,7 +10,7 @@ def __init__(self, load_direction = LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, magnitude: float = 0, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -20,7 +20,7 @@ def __init__(self, load_direction (enum): Load Direction Enumeration magnitude (float): Magnitude of Line Load comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Line Load @@ -56,13 +56,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Line Load to client model Model.clientModel.service.set_line_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int = 1, load_case_no: int = 1, lines_no: str = '1', @@ -71,7 +73,7 @@ def Force(self, load_parameter = None, list_reference: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -105,7 +107,7 @@ def Force(self, load_parameter = [[distance, delta_distance, magnitude], ...] list_reference (bool): List Reference Bool comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Line Load @@ -308,13 +310,15 @@ def Force(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Line Load to client model Model.clientModel.service.set_line_load(load_case_no, clientObject) - def Moment(self, + @staticmethod + def Moment( no: int = 1, load_case_no: int = 1, lines_no: str = '1', @@ -323,7 +327,7 @@ def Moment(self, load_parameter = None, list_reference: bool = False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -355,7 +359,7 @@ def Moment(self, load_parameter = [[distance, delta_distance, magnitude], ...] list_reference (bool): List Reference Bool comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Line Load @@ -558,20 +562,22 @@ def Moment(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Line Load to client model Model.clientModel.service.set_line_load(load_case_no, clientObject) - def Mass(self, + @staticmethod + def Mass( no: int = 1, load_case_no: int = 1, lines_no: str = '1', individual_mass_components: bool=True, mass_components = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: no (int): Load Tag @@ -584,7 +590,7 @@ def Mass(self, for individual_mass_components == True: mass_components = [mass_x, mass_y, mass_z] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Line Load @@ -631,8 +637,9 @@ def Mass(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Line Load to client model Model.clientModel.service.set_line_load(load_case_no, clientObject) diff --git a/RFEM/Loads/memberLoad.py b/RFEM/Loads/memberLoad.py index 7bfb62f0..e096d2e7 100644 --- a/RFEM/Loads/memberLoad.py +++ b/RFEM/Loads/memberLoad.py @@ -9,9 +9,9 @@ def __init__(self, load_case_no: int = 1, members_no: str = '1', load_direction = LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, - magnitude: float = 0, + magnitude: float = 2000, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -20,7 +20,7 @@ def __init__(self, load_direction (enum): Load Directin Enumeration magnitude (float): Load Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_load') @@ -55,13 +55,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -71,7 +73,7 @@ def Force(self, force_eccentricity: bool= False, list_reference: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -107,7 +109,7 @@ def Force(self, force_eccentricity (bool): Enable/Disable Force Eccentricity Option list_reference (bool): Enable/Disable List Reference Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for force_eccentricity == True: {'eccentricity_horizontal_alignment': MemberLoadEccentricityHorizontalAlignment.ALIGN_NONE, 'eccentricity_vertical_alignment': MemberLoadEccentricityVerticalAlignment.ALIGN_NONE, @@ -362,7 +364,8 @@ def Force(self, # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def Moment(self, + @staticmethod + def Moment( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -371,7 +374,7 @@ def Moment(self, load_parameter = [], list_reference: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -402,7 +405,7 @@ def Moment(self, load_parameter = [[distance, delta_distance, magnitude], ...] list_reference (bool): Enable/Disable List Reference Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_load') @@ -582,20 +585,22 @@ def Moment(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def Mass(self, + @staticmethod + def Mass( no: int = 1, load_case_no: int = 1, members_no: str = '1', individual_mass_components: bool=False, mass_components = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -608,7 +613,7 @@ def Mass(self, else: mass_components = [Mx, My, Mz, Ix, Iy, Iz] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_load') @@ -646,13 +651,15 @@ def Mass(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def Temperature(self, + @staticmethod + def Temperature( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -662,7 +669,7 @@ def Temperature(self, list_reference: bool= False, load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -688,7 +695,7 @@ def Temperature(self, list_reference (bool): List Reference Boolean load_over_total_length (bool): Enable/Disable Load Over Total Length Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -803,13 +810,15 @@ def Temperature(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def TemperatureChange(self, + @staticmethod + def TemperatureChange( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -819,7 +828,7 @@ def TemperatureChange(self, list_reference: bool= False, load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -845,7 +854,7 @@ def TemperatureChange(self, list_reference (bool): Enable/Disable List Reference Option load_over_total_length (bool): Enable/Disable Load Over Total Length Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -960,13 +969,15 @@ def TemperatureChange(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def AxialStrain(self, + @staticmethod + def AxialStrain( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -976,7 +987,7 @@ def AxialStrain(self, list_reference: bool= False, load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -999,7 +1010,7 @@ def AxialStrain(self, list_reference (bool): Enable/Disable List Reference Option load_over_total_length (bool): Enable/Disable Load Over Total Length Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1106,20 +1117,22 @@ def AxialStrain(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def AxialDisplacement(self, + @staticmethod + def AxialDisplacement( no: int = 1, load_case_no: int = 1, members_no: str = '1', load_direction = MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, magnitude : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1129,7 +1142,7 @@ def AxialDisplacement(self, load_direction (enum): Load Direction Enumeration magnitude (float): Load Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1164,13 +1177,15 @@ def AxialDisplacement(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def Precamber(self, + @staticmethod + def Precamber( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -1180,7 +1195,7 @@ def Precamber(self, list_reference: bool= False, load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1203,7 +1218,7 @@ def Precamber(self, list_reference (bool): Enable/Disable List Reference Option load_over_total_length (bool): Enable/Disable Load Over Total Length Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1310,20 +1325,22 @@ def Precamber(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def InitialPrestress(self, + @staticmethod + def InitialPrestress( no: int = 1, load_case_no: int = 1, members_no: str = '1', load_direction = MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, magnitude : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1333,7 +1350,7 @@ def InitialPrestress(self, load_direction (enum): Load Direction Enumeration magnitude (float): Load Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1368,13 +1385,15 @@ def InitialPrestress(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def Displacement(self, + @staticmethod + def Displacement( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -1384,7 +1403,7 @@ def Displacement(self, list_reference: bool= False, load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1417,7 +1436,7 @@ def Displacement(self, list_reference (bool): Enable/Disable List Reference Option load_over_total_length (bool): Enable/Disable Load Over Total Length Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1603,13 +1622,15 @@ def Displacement(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def Rotation(self, + @staticmethod + def Rotation( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -1619,7 +1640,7 @@ def Rotation(self, list_reference: bool= False, load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1652,7 +1673,7 @@ def Rotation(self, list_reference (bool): Enable/Disable List Reference Option load_over_total_length (bool): Enable/Disable Load Over Total Length Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1838,20 +1859,22 @@ def Rotation(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def PipeContentFull(self, + @staticmethod + def PipeContentFull( no: int = 1, load_case_no: int = 1, members_no: str = '1', load_direction_orientation = MemberLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, specific_weight : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1861,7 +1884,7 @@ def PipeContentFull(self, load_direction_orientation (enum): Load Direction Enumeration specific_weight (float): Specific Weight comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1899,13 +1922,15 @@ def PipeContentFull(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def PipeContentPartial(self, + @staticmethod + def PipeContentPartial( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -1913,7 +1938,7 @@ def PipeContentPartial(self, specific_weight : float = 0.0, filling_height : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1924,7 +1949,7 @@ def PipeContentPartial(self, specific_weight (float): Specific Weight filling_height (float): Filling Height comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -1965,19 +1990,21 @@ def PipeContentPartial(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def PipeInternalPressure(self, + @staticmethod + def PipeInternalPressure( no: int = 1, load_case_no: int = 1, members_no: str = '1', pressure : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -1986,7 +2013,7 @@ def PipeInternalPressure(self, members_no (str): Assigned Member(s) pressure (float): Pressure comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -2021,13 +2048,15 @@ def PipeInternalPressure(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) - def RotaryMotion(self, + @staticmethod + def RotaryMotion( no: int = 1, load_case_no: int = 1, members_no: str = '1', @@ -2039,7 +2068,7 @@ def RotaryMotion(self, axis_definition_p1 = [1,0,1], axis_definition_p2 = [0,1,0], comment: str = '', - params: dict = {}): + params: dict = None): ''' Args: @@ -2054,7 +2083,7 @@ def RotaryMotion(self, axis_definition_p1 (list): P1 List [X, Y, Z] axis_definition_p2 (list): P2 List [X, Y, Z] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary ''' # Client model | Member Load @@ -2107,8 +2136,9 @@ def RotaryMotion(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_load(load_case_no, clientObject) \ No newline at end of file diff --git a/RFEM/Loads/membersetload.py b/RFEM/Loads/membersetload.py index 1fc24163..326f99bb 100644 --- a/RFEM/Loads/membersetload.py +++ b/RFEM/Loads/membersetload.py @@ -12,7 +12,7 @@ def __init__(self, load_direction = LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, magnitude: float = 0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -21,7 +21,7 @@ def __init__(self, load_direction (enum): Load Case Enumeration magnitude (float): Load Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load @@ -57,13 +57,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -72,7 +74,7 @@ def Force(self, load_parameter = [], force_eccentricity: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -83,7 +85,7 @@ def Force(self, load_parameter (list): Load Parameter force_eccentricity (bool): Force Eccentricity Option comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for LOAD_DISTRIBUTION_UNIFORM: load_parameter = [magnitude] @@ -393,7 +395,8 @@ def Force(self, # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def Moment(self, + @staticmethod + def Moment( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -401,7 +404,7 @@ def Moment(self, load_direction= MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -411,7 +414,7 @@ def Moment(self, load_direction (enum): Load Direction Enumeration load_parameter (list): Load Parameters comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for LOAD_DISTRIBUTION_UNIFORM: load_parameter = magnitude @@ -643,20 +646,22 @@ def Moment(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def Mass(self, + @staticmethod + def Mass( no: int = 1, load_case_no: int = 1, member_sets: str = '1', individual_mass_components: bool=False, mass_components = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -665,7 +670,7 @@ def Mass(self, individual_mass_components (bool): Individiual Mass Components Option mass_components (list): Mass Components comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_set_load') @@ -705,13 +710,15 @@ def Mass(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def Temperature(self, + @staticmethod + def Temperature( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -720,7 +727,7 @@ def Temperature(self, load_parameter = [], load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -731,7 +738,7 @@ def Temperature(self, load_parameter (list): Load Parameters load_over_total_length (bool): Load Over Total Length Option comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution = MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [tt, tb] @@ -879,13 +886,15 @@ def Temperature(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def TemperatureChange(self, + @staticmethod + def TemperatureChange( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -894,7 +903,7 @@ def TemperatureChange(self, load_parameter = [], load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -905,7 +914,7 @@ def TemperatureChange(self, load_parameter (list): Load Parameters load_over_total_length (bool): Load Over Total Length Option comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution = MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [tc, delta_t] @@ -1047,13 +1056,15 @@ def TemperatureChange(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def AxialStrain(self, + @staticmethod + def AxialStrain( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -1062,7 +1073,7 @@ def AxialStrain(self, load_parameter = [], load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -1073,7 +1084,7 @@ def AxialStrain(self, load_parameter (list): Load Parameters load_over_total_length (bool): Load Over Total Length Option comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution = MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [epsilon] @@ -1204,20 +1215,22 @@ def AxialStrain(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def AxialDisplacement(self, + @staticmethod + def AxialDisplacement( no: int = 1, load_case_no: int = 1, member_sets: str = '1', load_direction = MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, magnitude : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -1226,7 +1239,7 @@ def AxialDisplacement(self, load_direction (enum): Load Direction Enumeration magnitude (float): Load Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_set_load') @@ -1260,13 +1273,15 @@ def AxialDisplacement(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def Precamber(self, + @staticmethod + def Precamber( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -1275,7 +1290,7 @@ def Precamber(self, load_parameter = [], load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -1286,7 +1301,7 @@ def Precamber(self, load_parameter (enum): Load Parameters load_over_total_length (bool): Load Over Total Lenth Option comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution = MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [magnitude] @@ -1418,20 +1433,22 @@ def Precamber(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def InitialPrestress(self, + @staticmethod + def InitialPrestress( no: int = 1, load_case_no: int = 1, member_sets: str = '1', load_direction = MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, magnitude : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -1440,7 +1457,7 @@ def InitialPrestress(self, load_direction (enum): Load Direction Enumeration magnitude (float): Load Magnitude comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_set_load') @@ -1474,13 +1491,15 @@ def InitialPrestress(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def Displacement(self, + @staticmethod + def Displacement( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -1489,7 +1508,7 @@ def Displacement(self, load_parameter = [], load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -1500,7 +1519,7 @@ def Displacement(self, load_parameter (list): Load Parameters load_over_total_length (bool): Load Over Total Length Option comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution = MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [magnitude] @@ -1738,13 +1757,15 @@ def Displacement(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def Rotation(self, + @staticmethod + def Rotation( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -1753,7 +1774,7 @@ def Rotation(self, load_parameter = [], load_over_total_length: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -1764,7 +1785,7 @@ def Rotation(self, load_parameter (list): Load Parameters load_over_total_length (bool): Load Over Total Length comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution = MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [magnitude] @@ -2002,20 +2023,22 @@ def Rotation(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def PipeContentFull(self, + @staticmethod + def PipeContentFull( no: int = 1, load_case_no: int = 1, member_sets: str = '1', load_direction_orientation = MemberSetLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, specific_weight : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -2024,7 +2047,7 @@ def PipeContentFull(self, load_direction_orientation (enum): Load Direction Orientation Enumeration specific_weight (float): Specific Weight comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_set_load') @@ -2061,13 +2084,15 @@ def PipeContentFull(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def PipeContentPartial(self, + @staticmethod + def PipeContentPartial( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -2075,7 +2100,7 @@ def PipeContentPartial(self, specific_weight : float = 0.0, filling_height : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -2085,7 +2110,7 @@ def PipeContentPartial(self, specific_weight (float): Specific Weight filling_height (float): Filling Height comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_set_load') @@ -2125,19 +2150,21 @@ def PipeContentPartial(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def PipeInternalPressure(self, + @staticmethod + def PipeInternalPressure( no: int = 1, load_case_no: int = 1, member_sets: str = '1', pressure : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -2145,7 +2172,7 @@ def PipeInternalPressure(self, member_sets (str): Assigned Member Sets pressure (float): Pressure comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_set_load') @@ -2179,13 +2206,15 @@ def PipeInternalPressure(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) - def RotaryMotion(self, + @staticmethod + def RotaryMotion( no: int = 1, load_case_no: int = 1, member_sets: str = '1', @@ -2197,7 +2226,7 @@ def RotaryMotion(self, axis_definition_p1 = [], axis_definition_p2 = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -2211,7 +2240,7 @@ def RotaryMotion(self, axis_definition_p1 (list):Axis Definition First Point axis_definition_p2 (list): Axis Definition Second Point comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Member Load clientObject = Model.clientModel.factory.create('ns0:member_set_load') @@ -2263,8 +2292,9 @@ def RotaryMotion(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Load Member Load to client model Model.clientModel.service.set_member_set_load(load_case_no, clientObject) diff --git a/RFEM/Loads/nodalLoad.py b/RFEM/Loads/nodalLoad.py index 9f2f2227..b9d52fe3 100644 --- a/RFEM/Loads/nodalLoad.py +++ b/RFEM/Loads/nodalLoad.py @@ -19,7 +19,7 @@ def __init__(self, load_direction (enum): Load Direction Enumeration magnitude (float): Force Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Nodal Force clientObject = Model.clientModel.factory.create('ns0:nodal_load') @@ -50,13 +50,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Nodal Force to client model Model.clientModel.service.set_nodal_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int= 1, load_case_no: int = 1, nodes_no: str= '1', @@ -199,7 +201,8 @@ def Force(self, # Add Nodal Force to client model Model.clientModel.service.set_nodal_load(load_case_no, clientObject) - def Moment(self, + @staticmethod + def Moment( no: int= 1, load_case_no: int= 1, nodes_no: str= '1', @@ -208,7 +211,7 @@ def Moment(self, specific_direction: bool= False, shifted_display: bool= False, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -319,7 +322,8 @@ def Moment(self, # Add Nodal Force to client model Model.clientModel.service.set_nodal_load(load_case_no, clientObject) - def Components(self, + @staticmethod + def Components( no: int= 1, load_case_no: int= 1, nodes_no: str= '1', @@ -455,14 +459,15 @@ def Components(self, # Add Nodal Force to client model Model.clientModel.service.set_nodal_load(load_case_no, clientObject) - def Mass(self, + @staticmethod + def Mass( no: int = 1, load_case_no: int = 1, nodes_no: str = '1', individual_mass_components : bool = False, mass = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -475,7 +480,7 @@ def Mass(self, elif individual_mass_components == True: mass = [Mx, My, Mz, Ix, Iy, Iz] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Nodal Force clientObject = Model.clientModel.factory.create('ns0:nodal_load') @@ -517,7 +522,7 @@ def Mass(self, clientObject.comment = comment # Adding optional parameters via dictionary - if 'individual_mass_components' not in params.keys(): + if params: for key in params: clientObject[key] = params[key] diff --git a/RFEM/Loads/solidLoad.py b/RFEM/Loads/solidLoad.py index 5749247c..3c8be1d5 100644 --- a/RFEM/Loads/solidLoad.py +++ b/RFEM/Loads/solidLoad.py @@ -12,7 +12,7 @@ def __init__(self, load_direction = SolidLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, magnitude: float = 0, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Solid Load clientObject = Model.clientModel.factory.create('ns0:solid_load') @@ -45,20 +45,22 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int =1, load_case_no: int = 1, solids_no: str= '1', load_direction = SolidLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, magnitude: float = 0, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Solid Load clientObject = Model.clientModel.factory.create('ns0:solid_load') @@ -91,20 +93,22 @@ def Force(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_load(load_case_no, clientObject) - def Temperature(self, + @staticmethod + def Temperature( no: int = 1, load_case_no: int = 1, solids_no: str= '1', load_distribution = SolidLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' load_parameter: LOAD_DISTRIBUTION_UNIFORM: load_parameter = magnitude @@ -147,20 +151,22 @@ def Temperature(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_load(load_case_no, clientObject) - def Strain(self, + @staticmethod + def Strain( no: int = 1, load_case_no: int = 1, solids_no: str= '1', load_distribution = SolidLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' load_parameter: LOAD_DISTRIBUTION_UNIFORM: load_parameter = [strain_uniform_magnitude_x, strain_uniform_magnitude_y, strain_uniform_magnitude_z] @@ -209,19 +215,21 @@ def Strain(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_load(load_case_no, clientObject) - def Motion(self, + @staticmethod + def Motion( no: int = 1, load_case_no: int = 1, solids_no: str= '1', load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' load_parameter: load_parameter = [angular_velocity, angular_acceleration, axis_definition_p1_x, axis_definition_p1_y, axis_definition_p1_z, axis_definition_p2_x, axis_definition_p2_y, axis_definition_p2_z] @@ -264,8 +272,9 @@ def Motion(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_load(load_case_no, clientObject) diff --git a/RFEM/Loads/solidSetLoad.py b/RFEM/Loads/solidSetLoad.py index 90faa5d3..99ea962c 100644 --- a/RFEM/Loads/solidSetLoad.py +++ b/RFEM/Loads/solidSetLoad.py @@ -12,7 +12,7 @@ def __init__(self, load_direction = SolidSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, magnitude: float = 0, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Solid Load clientObject = Model.clientModel.factory.create('ns0:solid_set_load') @@ -45,21 +45,23 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_set_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int =1, load_case_no: int = 1, solid_sets_no: str= '1', load_direction = SolidSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, magnitude: float = 0, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Solid Load clientObject = Model.clientModel.factory.create('ns0:solid_set_load') @@ -92,20 +94,22 @@ def Force(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_set_load(load_case_no, clientObject) - def Temperature(self, + @staticmethod + def Temperature( no: int = 1, load_case_no: int = 1, solid_sets_no: str= '1', load_distribution = SolidSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' load_parameter: LOAD_DISTRIBUTION_UNIFORM: load_parameter = magnitude @@ -148,20 +152,22 @@ def Temperature(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_set_load(load_case_no, clientObject) - def Strain(self, + @staticmethod + def Strain( no: int = 1, load_case_no: int = 1, solid_sets_no: str= '1', load_distribution = SolidSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' load_parameter: LOAD_DISTRIBUTION_UNIFORM: load_parameter = [strain_uniform_magnitude_x, strain_uniform_magnitude_y, strain_uniform_magnitude_z] @@ -210,19 +216,21 @@ def Strain(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_set_load(load_case_no, clientObject) - def Motion(self, + @staticmethod + def Motion( no: int = 1, load_case_no: int = 1, solid_sets_no: str= '1', load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' load_parameter: load_parameter = [angular_velocity, angular_acceleration, axis_definition_p1_x, axis_definition_p1_y, axis_definition_p1_z, axis_definition_p2_x, axis_definition_p2_y, axis_definition_p2_z] @@ -265,8 +273,9 @@ def Motion(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Load to client model Model.clientModel.service.set_solid_set_load(load_case_no, clientObject) diff --git a/RFEM/Loads/surfaceLoad.py b/RFEM/Loads/surfaceLoad.py index 04f67ec7..0deaf396 100644 --- a/RFEM/Loads/surfaceLoad.py +++ b/RFEM/Loads/surfaceLoad.py @@ -9,7 +9,7 @@ def __init__(self, surface_no: str = '1', magnitude: float = 1.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -17,7 +17,7 @@ def __init__(self, surface_no (str): Assigend Surfaces magnitude (float): Load Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_load') @@ -49,13 +49,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int = 1, load_case_no: int = 1, surface_no: str = '1', @@ -63,7 +65,7 @@ def Force(self, load_distribution = SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -90,7 +92,7 @@ def Force(self, load_parameter = [[distance_1, delta_distance_1, magnitude_1], [distance_2, delta_distance_2, magnitude_2]...] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_load') @@ -176,20 +178,22 @@ def Force(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_load(load_case_no, clientObject) - def Temperature(self, + @staticmethod + def Temperature( no: int = 1, load_case_no: int = 1, surface_no: str = '1', load_distribution = SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -213,7 +217,7 @@ def Temperature(self, load_parameter = [t_c_1, delta_t_1, t_c_2, delta_t_2, node_1, node_2, SurfaceLoadAxisDefinitionType, SurfaceLoadAxisDefinitionAxis, axis_definition_p1] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_load') @@ -286,20 +290,22 @@ def Temperature(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_load(load_case_no, clientObject) - def AxialStrain(self, + @staticmethod + def AxialStrain( no: int = 1, load_case_no: int = 1, surface_no: str = '1', load_distribution = SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -318,7 +324,7 @@ def AxialStrain(self, load_parameter = [magnitude_axial_strain_1x, magnitude_axial_strain_1y, magnitude_axial_strain_2x, magnitude_axial_strain_2y, node_1, node_2] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_load') @@ -371,19 +377,21 @@ def AxialStrain(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_load(load_case_no, clientObject) - def Precamber(self, + @staticmethod + def Precamber( no: int = 1, load_case_no: int = 1, surface_no: str = '1', uniform_magnitude : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -391,7 +399,7 @@ def Precamber(self, surface_no (str): Assigned Surfaces uniform_magnitude (float): Magnitude comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_load') @@ -423,19 +431,21 @@ def Precamber(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_load(load_case_no, clientObject) - def RotaryMotion(self, + @staticmethod + def RotaryMotion( no: int = 1, load_case_no: int = 1, surface_no: str = '1', load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -449,7 +459,7 @@ def RotaryMotion(self, load_parameter = [angular_velocity, angular_acceleration, SurfaceLoadAxisDefinitionType, SurfaceLoadAxisDefinitionAxis, SurfaceLoadAxisDirectionType; [x1, y1, z1]] comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_load') @@ -492,20 +502,22 @@ def RotaryMotion(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_load(load_case_no, clientObject) - def Mass(self, + @staticmethod + def Mass( no: int = 1, load_case_no: int = 1, surface_no: str = '1', individual_mass_components : bool = False, mass_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -560,8 +572,9 @@ def Mass(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_load(load_case_no, clientObject) diff --git a/RFEM/Loads/surfacesetload.py b/RFEM/Loads/surfacesetload.py index d58b2d2c..f84fdc97 100644 --- a/RFEM/Loads/surfacesetload.py +++ b/RFEM/Loads/surfacesetload.py @@ -9,7 +9,7 @@ def __init__(self, surface_sets: str = '1', magnitude: float = 1.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -17,7 +17,7 @@ def __init__(self, surface_sets (str): Assigned Surface Sets magnitude (float): Load Magnitude comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_set_load') @@ -49,13 +49,15 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_set_load(load_case_no, clientObject) - def Force(self, + @staticmethod + def Force( no: int = 1, load_case_no: int = 1, surface_sets: str = '1', @@ -63,7 +65,7 @@ def Force(self, load_distribution = SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -73,7 +75,7 @@ def Force(self, load_distribution (enum): Load Distribution Enumeration load_parameter (list): Load Parameters comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution == SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [magnitude] @@ -176,20 +178,22 @@ def Force(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_set_load(load_case_no, clientObject) - def Temperature(self, + @staticmethod + def Temperature( no: int = 1, load_case_no: int = 1, surface_sets: str = '1', load_distribution = SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = None, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -198,7 +202,7 @@ def Temperature(self, load_distribution (enum): Load Distribution Enumeration load_parameter (enum): Load Parameter Enumeration comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution == SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [t_c, delta_t] @@ -286,20 +290,22 @@ def Temperature(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_set_load(load_case_no, clientObject) - def AxialStrain(self, + @staticmethod + def AxialStrain( no: int = 1, load_case_no: int = 1, surface_sets: str = '1', load_distribution = SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -308,7 +314,7 @@ def AxialStrain(self, load_distribution (enum): Load Distribution Enumeration load_parameter (list): Load Parameter comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for load_distribution == SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM: load_parameter = [axial_strain_x, axial_strain_y] @@ -373,19 +379,21 @@ def AxialStrain(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_set_load(load_case_no, clientObject) - def Precamber(self, + @staticmethod + def Precamber( no: int = 1, load_case_no: int = 1, surface_sets: str = '1', uniform_magnitude : float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -393,7 +401,7 @@ def Precamber(self, surface_sets (str): Assigned Surface Sets uniform_magnitude (float): Load Magnitude comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Surface Load clientObject = Model.clientModel.factory.create('ns0:surface_set_load') @@ -425,19 +433,21 @@ def Precamber(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_set_load(load_case_no, clientObject) - def RotaryMotion(self, + @staticmethod + def RotaryMotion( no: int = 1, load_case_no: int = 1, surface_sets: str = '1', load_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -445,7 +455,7 @@ def RotaryMotion(self, surface_sets (str): Assigned Surface Sets load_parameter (list): Load Parameters comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for axis_definition_type = SurfaceSetLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS: load_parameter = [angular_velocity, angular_acceleration, SurfaceLoadAxisDefinitionType, [x1, y1, z1], [x2, y2, z2]] @@ -493,20 +503,22 @@ def RotaryMotion(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_set_load(load_case_no, clientObject) - def Mass(self, + @staticmethod + def Mass( no: int = 1, load_case_no: int = 1, surface_sets: str = '1', individual_mass_components : bool = False, mass_parameter = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Load Tag @@ -515,7 +527,7 @@ def Mass(self, individual_mass_components (bool): Individiual Mass Components Option mass_parameter (list): Mass Parameters comment (str, optional): Comment - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for individual_mass_components == True: mass_parameter = [mass_global] @@ -554,8 +566,9 @@ def Mass(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Load to client model Model.clientModel.service.set_surface_set_load(load_case_no, clientObject) diff --git a/RFEM/SpecialObjects/enlargedColumnHead.py b/RFEM/SpecialObjects/enlargedColumnHead.py index e12825ca..e559ebed 100644 --- a/RFEM/SpecialObjects/enlargedColumnHead.py +++ b/RFEM/SpecialObjects/enlargedColumnHead.py @@ -4,7 +4,7 @@ class EnlargedColumnHead(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Enlarged Column Head clientObject = Model.clientModel.factory.create('ns0:enlarged_column_head') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Enlarged Column Head to client model Model.clientModel.service.set_enlarged_column_head(clientObject) diff --git a/RFEM/SpecialObjects/intersection.py b/RFEM/SpecialObjects/intersection.py index a0ee9e8f..3e943f8e 100644 --- a/RFEM/SpecialObjects/intersection.py +++ b/RFEM/SpecialObjects/intersection.py @@ -6,7 +6,7 @@ def __init__(self, surface_1: int = 1, surface_2: int = 2, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Intersection clientObject = Model.clientModel.factory.create('ns0:intersection') @@ -25,8 +25,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Intersection to client model Model.clientModel.service.set_intersection(clientObject) diff --git a/RFEM/SpecialObjects/resultSection.py b/RFEM/SpecialObjects/resultSection.py index 80941e10..caa9e994 100644 --- a/RFEM/SpecialObjects/resultSection.py +++ b/RFEM/SpecialObjects/resultSection.py @@ -4,7 +4,7 @@ class ResultSection(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Result Section clientObject = Model.clientModel.factory.create('ns0:result_section') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Result Section to client model Model.clientModel.service.set_result_section(clientObject) diff --git a/RFEM/SpecialObjects/rigidLink.py b/RFEM/SpecialObjects/rigidLink.py index 0d76d93a..8c46a16e 100644 --- a/RFEM/SpecialObjects/rigidLink.py +++ b/RFEM/SpecialObjects/rigidLink.py @@ -8,7 +8,7 @@ def __init__(self, line_2: int = 2, ignore_relative_position: bool = True, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Rigid Link clientObject = Model.clientModel.factory.create('ns0:rigid_link') @@ -33,19 +33,21 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add rigid link to client model Model.clientModel.service.set_rigid_link(clientObject) - def LineToLine(self, + @staticmethod + def LineToLine( no: int = 1, line_1: int = 1, line_2: int = 2, ignore_relative_position: bool = True, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line To Line Rigid Link clientObject = Model.clientModel.factory.create('ns0:rigid_link') @@ -70,19 +72,21 @@ def LineToLine(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add rigid link to client model Model.clientModel.service.set_rigid_link(clientObject) - def LineToSurface(self, + @staticmethod + def LineToSurface( no: int = 1, line_1: int = 1, surface: int = 1, ignore_relative_position: bool = True, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line To Surface Rigid Link clientObject = Model.clientModel.factory.create('ns0:rigid_link') @@ -108,18 +112,20 @@ def LineToSurface(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add rigid link to client model Model.clientModel.service.set_rigid_link(clientObject) - def Diapragm(self, + @staticmethod + def Diapragm( no: int = 1, nodes: str = '3 4', lines: str = '6 7', comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Diapragm Rigid Link clientObject = Model.clientModel.factory.create('ns0:rigid_link') @@ -143,8 +149,9 @@ def Diapragm(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add rigid link to client model Model.clientModel.service.set_rigid_link(clientObject) diff --git a/RFEM/SpecialObjects/structureModification.py b/RFEM/SpecialObjects/structureModification.py index 3166e50f..d12b976f 100644 --- a/RFEM/SpecialObjects/structureModification.py +++ b/RFEM/SpecialObjects/structureModification.py @@ -4,7 +4,7 @@ class StructureModification(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Structure Modification clientObject = Model.clientModel.factory.create('ns0:structure_modification') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Structure Modification to client model Model.clientModel.service.set_structure_modification(clientObject) diff --git a/RFEM/SpecialObjects/surfaceContact.py b/RFEM/SpecialObjects/surfaceContact.py index 33ef394f..43d7fb82 100644 --- a/RFEM/SpecialObjects/surfaceContact.py +++ b/RFEM/SpecialObjects/surfaceContact.py @@ -4,7 +4,7 @@ class SurfaceContact(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Surfaces Contact clientObject = Model.clientModel.factory.create('ns0:surfaces_contact') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surfaces Contact to client model Model.clientModel.service.set_surfaces_contact(clientObject) diff --git a/RFEM/SpecialObjects/surfaceResultAdjustment.py b/RFEM/SpecialObjects/surfaceResultAdjustment.py index bc486ee8..4e1d2e17 100644 --- a/RFEM/SpecialObjects/surfaceResultAdjustment.py +++ b/RFEM/SpecialObjects/surfaceResultAdjustment.py @@ -4,7 +4,7 @@ class SurfaceResultsAdjustment(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Surface Result Adjustment clientObject = Model.clientModel.factory.create('ns0:surface_results_adjustment') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Result Adjustmentto client model Model.clientModel.service.set_surface_results_adjustment(clientObject) diff --git a/RFEM/Tools/ModelCheck.py b/RFEM/Tools/ModelCheck.py index d0726f60..82b4ba03 100644 --- a/RFEM/Tools/ModelCheck.py +++ b/RFEM/Tools/ModelCheck.py @@ -6,7 +6,8 @@ class ModelCheck(): def __init__(self): pass - def GetIdenticalNodes(self, tolerance): + @staticmethod + def GetIdenticalNodes(tolerance): """ Args: tolerance (float): Tolerance @@ -19,7 +20,8 @@ def GetIdenticalNodes(self, tolerance): return object_groups - def DeleteUnusedNodes(self, tolerance, object_groups): + @staticmethod + def DeleteUnusedNodes(tolerance, object_groups): """ Args: tolerance (float): Tolerance @@ -29,7 +31,8 @@ def DeleteUnusedNodes(self, tolerance, object_groups): process = ModelCheckProcessOptionType.DELETE_UNUSED_NODES.name Model.clientModel.service.model_check__process_object_groups_operation(process, tolerance, object_groups) - def UniteNodes(self, tolerance, object_groups): + @staticmethod + def UniteNodes(tolerance, object_groups): """ Args: tolerance (float): Tolerance @@ -39,7 +42,8 @@ def UniteNodes(self, tolerance, object_groups): process = ModelCheckProcessOptionType.UNITE_NODES_AND_DELETE_UNUSED_NODES.name Model.clientModel.service.model_check__process_object_groups_operation(process, tolerance, object_groups) - def GetNotConnectedLines(self, tolerance): + @staticmethod + def GetNotConnectedLines(tolerance): """ Args: tolerance (float): Tolerance @@ -52,7 +56,8 @@ def GetNotConnectedLines(self, tolerance): return line_groups - def CrossLines(self, tolerance, line_groups): + @staticmethod + def CrossLines(tolerance, line_groups): """ Args: tolerance (float): Tolerance @@ -62,7 +67,8 @@ def CrossLines(self, tolerance, line_groups): process = ModelCheckProcessOptionType.CROSS_LINES.name Model.clientModel.service.model_check__process_object_groups_operation(process, tolerance, line_groups) - def GetNotConnectedMembers(self, tolerance): + @staticmethod + def GetNotConnectedMembers(tolerance): """ Args: tolerance (float): Tolerance @@ -75,7 +81,8 @@ def GetNotConnectedMembers(self, tolerance): return member_groups - def CrossMembers(self, tolerance, member_groups): + @staticmethod + def CrossMembers(tolerance, member_groups): """ Args: tolerance (float): Tolerance @@ -85,7 +92,8 @@ def CrossMembers(self, tolerance, member_groups): process = ModelCheckProcessOptionType.CROSS_MEMBERS.name Model.clientModel.service.model_check__process_object_groups_operation(process, tolerance, member_groups) - def GetOverlappingLines(self): + @staticmethod + def GetOverlappingLines(): """ Returns: Overlapping Line Groups @@ -96,7 +104,8 @@ def GetOverlappingLines(self): return overlapping_lines - def GetOverlappingMembers(self): + @staticmethod + def GetOverlappingMembers(): """ Returns: Overlapping Member Groups diff --git a/RFEM/Tools/PlausibilityCheck.py b/RFEM/Tools/PlausibilityCheck.py index 701a7da3..f238e8f7 100644 --- a/RFEM/Tools/PlausibilityCheck.py +++ b/RFEM/Tools/PlausibilityCheck.py @@ -19,7 +19,7 @@ def __init__(self, def IsModelOK(self): - return self.checkresult == PlausibilityCheckResult.CHECK_IS_OK.name + return self.checkresult def GetErrorMessage(self): diff --git a/RFEM/Tools/centreOfGravityAndObjectInfo.py b/RFEM/Tools/centreOfGravityAndObjectInfo.py index 902f167c..9d2513ab 100644 --- a/RFEM/Tools/centreOfGravityAndObjectInfo.py +++ b/RFEM/Tools/centreOfGravityAndObjectInfo.py @@ -2,11 +2,10 @@ from RFEM.enums import ObjectTypes, SelectedObjectInformation class ObjectInformation(): - # missing def __init__( with definition of self and its variables - # object_type, no, parent_no, information, row_key and result. - def CentreOfGravity(self, - type = ObjectTypes.E_OBJECT_TYPE_MEMBER, + @staticmethod + def CentreOfGravity( + object_type = ObjectTypes.E_OBJECT_TYPE_MEMBER, parent_no = 0, no: int = 1, coord: str = 'X'): @@ -21,10 +20,7 @@ def CentreOfGravity(self, no (int): The Object Tag coord (str): Desired global basis vector component of the Centre of Gravity (i.e. X, Y or Z) ''' - self.object_type = type - self.no = no - self.parent_no = parent_no - result = ObjectInformation.__BuildResultsArray(self) + result = ObjectInformation.__BuildResultsArray(object_type, no, parent_no) if coord == 'X' or coord.lstrip().rstrip().upper() == 'X': return result['section'][0].rows[0][0].value elif coord == 'Y' or coord.lstrip().rstrip().upper() == 'Y': @@ -34,7 +30,8 @@ def CentreOfGravity(self, else: raise Exception ('WARNING: The desired Coordinate input not requested. Please provide either "X", "Y" or "Z"') - def MemberInformation(self, + @staticmethod + def MemberInformation( no: int = 1, information = SelectedObjectInformation.LENGTH): ''' @@ -45,15 +42,12 @@ def MemberInformation(self, ''' if information.name == 'AREA': raise Exception ('WARNING: Area information is only relevant for Surface and Volume Information.') - self.object_type = ObjectTypes.E_OBJECT_TYPE_MEMBER - self.no = no - self.parent_no = 0 - self.information = information - self.row_key = 2 - self.result = ObjectInformation.__BuildResultsArray(self) - return ObjectInformation.__AreaVolumeMassInformationLength(self) - def SurfaceInformation(self, + result = ObjectInformation.__BuildResultsArray(ObjectTypes.E_OBJECT_TYPE_MEMBER, no, 0) + return ObjectInformation.__AreaVolumeMassInformationLength(information, result, 2) + + @staticmethod + def SurfaceInformation( no: int = 1, information = SelectedObjectInformation.AREA): ''' @@ -64,15 +58,12 @@ def SurfaceInformation(self, ''' if information.name == 'LENGTH': raise Exception ('WARNING: Length information is only relevant for Member Information.') - self.object_type = ObjectTypes.E_OBJECT_TYPE_SURFACE - self.no = no - self.parent_no = 0 - self.information = information - self.row_key = 3 - self.result = ObjectInformation.__BuildResultsArray(self) - return ObjectInformation.__AreaVolumeMassInformationLength(self) - def SolidInformation(self, + result = ObjectInformation.__BuildResultsArray(ObjectTypes.E_OBJECT_TYPE_SURFACE, no, 0) + return ObjectInformation.__AreaVolumeMassInformationLength(information, result, 3) + + @staticmethod + def SolidInformation( no: int = 1, information = SelectedObjectInformation.AREA): ''' @@ -83,29 +74,25 @@ def SolidInformation(self, ''' if information.name == 'LENGTH': raise Exception ('WARNING: Length information is only relevant for Member Information.') - self.object_type = ObjectTypes.E_OBJECT_TYPE_SOLID - self.no = no - self.parent_no = 0 - self.information = information - self.row_key = 4 - self.result = ObjectInformation.__BuildResultsArray(self) - return ObjectInformation.__AreaVolumeMassInformationLength(self) - def __BuildResultsArray(self): + result = ObjectInformation.__BuildResultsArray(ObjectTypes.E_OBJECT_TYPE_SOLID, no, 0) + return ObjectInformation.__AreaVolumeMassInformationLength(information,result, 4) + + def __BuildResultsArray(object_type, no, parent_no): elements = Model.clientModel.factory.create('ns0:array_of_get_center_of_gravity_and_objects_info_elements_type') clientObject = Model.clientModel.factory.create('ns0:get_center_of_gravity_and_objects_info_element_type') - clientObject.parent_no = self.parent_no - clientObject.no = self.no - clientObject.type = self.object_type.name + clientObject.parent_no = parent_no + clientObject.no = no + clientObject.type = object_type.name elements.element.append(clientObject) result = Model.clientModel.service.get_center_of_gravity_and_objects_info(elements) result = Model.clientModel.dict(result) return result - def __AreaVolumeMassInformationLength(self): - if self.information.name == "LENGTH" or self.information.name == "AREA": - return self.result['section'][self.row_key].rows[0][0].value - elif self.information.name == "VOLUME": - return self.result['section'][self.row_key].rows[0][1].value - elif self.information.name == "MASS": - return self.result['section'][self.row_key].rows[0][2].value + def __AreaVolumeMassInformationLength(information, result, row_key): + if information.name == "LENGTH" or information.name == "AREA": + return result['section'][row_key].rows[0][0].value + elif information.name == "VOLUME": + return result['section'][row_key].rows[0][1].value + elif information.name == "MASS": + return result['section'][row_key].rows[0][2].value diff --git a/RFEM/TypesForLines/lineHinge.py b/RFEM/TypesForLines/lineHinge.py index dfa445c7..ea3149fb 100644 --- a/RFEM/TypesForLines/lineHinge.py +++ b/RFEM/TypesForLines/lineHinge.py @@ -14,7 +14,7 @@ def __init__(self, translational_release: list = [800, inf, inf], rotational_release_phi: int = inf, comment: str = '', - params: dict = {}): + params: dict = None): """ assigned_to doesn't work. Can't figure why. @@ -46,8 +46,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line Hinge to client model Model.clientModel.service.set_line_hinge(clientObject) diff --git a/RFEM/TypesForLines/lineMeshRefinements.py b/RFEM/TypesForLines/lineMeshRefinements.py index 3bad2d34..ea8305f7 100644 --- a/RFEM/TypesForLines/lineMeshRefinements.py +++ b/RFEM/TypesForLines/lineMeshRefinements.py @@ -11,7 +11,7 @@ def __init__(self, type = LineMeshRefinementsType.TYPE_LENGTH, number_of_layers: int = 2, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line Mesh Refinement clientObject = Model.clientModel.factory.create('ns0:line_mesh_refinement') @@ -35,19 +35,21 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line Mesh Refinement to client model Model.clientModel.service.set_line_mesh_refinement(clientObject) - def TargetFELength(self, + @staticmethod + def TargetFELength( no: int = 1, lines: str = '3 4 5', target_length: float = 0.1, number_of_layers: int = 2, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line Mesh Refinement clientObject = Model.clientModel.factory.create('ns0:line_mesh_refinement') @@ -74,19 +76,21 @@ def TargetFELength(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line Mesh Refinement to client model Model.clientModel.service.set_line_mesh_refinement(clientObject) - def NumberFiniteElements(self, + @staticmethod + def NumberFiniteElements( no: int = 1, lines: str = '3 4 5', elements_finite_elements: int = 10, number_of_layers: int = 2, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line Mesh Refinement clientObject = Model.clientModel.factory.create('ns0:line_mesh_refinement') @@ -113,19 +117,21 @@ def NumberFiniteElements(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line Mesh Refinement to client model Model.clientModel.service.set_line_mesh_refinement(clientObject) - def Gradually(self, + @staticmethod + def Gradually( no: int = 1, lines: str = '3 4 5', gradual_rows: int = 10, number_of_layers: int = 2, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line Mesh Refinement clientObject = Model.clientModel.factory.create('ns0:line_mesh_refinement') @@ -152,8 +158,9 @@ def Gradually(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line Mesh Refinement to client model Model.clientModel.service.set_line_mesh_refinement(clientObject) diff --git a/RFEM/TypesForLines/lineSupport.py b/RFEM/TypesForLines/lineSupport.py index 504824c6..598e3eb7 100644 --- a/RFEM/TypesForLines/lineSupport.py +++ b/RFEM/TypesForLines/lineSupport.py @@ -38,7 +38,7 @@ def __init__(self, lines_no: str = '1 2', support_type = LineSupportType.HINGED, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line Support clientObject = Model.clientModel.factory.create('ns0:line_support') @@ -85,8 +85,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line Support to client model Model.clientModel.service.set_line_support(clientObject) diff --git a/RFEM/TypesForLines/lineWeldedJoint.py b/RFEM/TypesForLines/lineWeldedJoint.py index 792ae196..0c6af073 100644 --- a/RFEM/TypesForLines/lineWeldedJoint.py +++ b/RFEM/TypesForLines/lineWeldedJoint.py @@ -11,7 +11,7 @@ def __init__(self, weld_size_a1: int = 0.005, longitudinal_arrangement = WeldLongitudalArrangement.CONTINUOUS, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Line Welded Joint clientObject = Model.clientModel.factory.create('ns0:line_welded_joint') @@ -38,8 +38,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line welded joint to client model Model.clientModel.service.set_line_welded_joint(clientObject) diff --git a/RFEM/TypesForMembers/memberDefinableStiffness.py b/RFEM/TypesForMembers/memberDefinableStiffness.py index 6f9d8fea..f158002a 100644 --- a/RFEM/TypesForMembers/memberDefinableStiffness.py +++ b/RFEM/TypesForMembers/memberDefinableStiffness.py @@ -4,7 +4,7 @@ class MemberDefinableStiffness(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Member Definable Stffness clientObject = Model.clientModel.factory.create('ns0:member_definable_stiffness') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Member Definable Stffness to client model Model.clientModel.service.set_member_definable_stiffness(clientObject) diff --git a/RFEM/TypesForMembers/memberEccentricity.py b/RFEM/TypesForMembers/memberEccentricity.py index 235d1bb5..8ac28672 100644 --- a/RFEM/TypesForMembers/memberEccentricity.py +++ b/RFEM/TypesForMembers/memberEccentricity.py @@ -4,7 +4,7 @@ class MemberEccentricity(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Member Eccentricity clientObject = Model.clientModel.factory.create('ns0:member_eccentricity') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Member Eccentricity to client model Model.clientModel.service.set_member_eccentricity(clientObject) diff --git a/RFEM/TypesForMembers/memberHinge.py b/RFEM/TypesForMembers/memberHinge.py index 34ff3e90..9629a5cb 100644 --- a/RFEM/TypesForMembers/memberHinge.py +++ b/RFEM/TypesForMembers/memberHinge.py @@ -12,7 +12,7 @@ def __init__(self, rotational_release_my: float = 0.0, rotational_release_mz: float = inf, comment: str = 'Rotational Release My', - params: dict = {}): + params: dict = None): # Client model | Member Hinge clientObject = Model.clientModel.factory.create('ns0:member_hinge') @@ -48,8 +48,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Line to client model Model.clientModel.service.set_member_hinge(clientObject) diff --git a/RFEM/TypesForMembers/memberNonlinearity.py b/RFEM/TypesForMembers/memberNonlinearity.py index 43065248..a1912dd7 100644 --- a/RFEM/TypesForMembers/memberNonlinearity.py +++ b/RFEM/TypesForMembers/memberNonlinearity.py @@ -4,7 +4,7 @@ class MemberNonlinearity(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Member Nonlinearity clientObject = Model.clientModel.factory.create('ns0:member_nonlinearity') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Member Nonlinearity to client model Model.clientModel.service.set_member_nonlinearity(clientObject) diff --git a/RFEM/TypesForMembers/memberResultIntermediatePoints.py b/RFEM/TypesForMembers/memberResultIntermediatePoints.py index 5e9c3159..3d64b1cd 100644 --- a/RFEM/TypesForMembers/memberResultIntermediatePoints.py +++ b/RFEM/TypesForMembers/memberResultIntermediatePoints.py @@ -4,7 +4,7 @@ class MemberResultIntermediatePoint(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Member Result Intermediate Point clientObject = Model.clientModel.factory.create('ns0:member_result_intermediate_point') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Member Result Intermediate Point to client model Model.clientModel.service.set_member_result_intermediate_point(clientObject) diff --git a/RFEM/TypesForMembers/memberStiffnessModification.py b/RFEM/TypesForMembers/memberStiffnessModification.py index e4e8f7c9..160d29f2 100644 --- a/RFEM/TypesForMembers/memberStiffnessModification.py +++ b/RFEM/TypesForMembers/memberStiffnessModification.py @@ -4,7 +4,7 @@ class MemberStiffnessModification(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Member Stiffness Modification clientObject = Model.clientModel.factory.create('ns0:smember_stiffness_modification') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Member Stiffness Modification to client model Model.clientModel.service.set_member_stiffness_modification(clientObject) diff --git a/RFEM/TypesForMembers/memberSupport.py b/RFEM/TypesForMembers/memberSupport.py index b05af708..ce85c74b 100644 --- a/RFEM/TypesForMembers/memberSupport.py +++ b/RFEM/TypesForMembers/memberSupport.py @@ -4,7 +4,7 @@ class MemberSupport(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Member Support clientObject = Model.clientModel.factory.create('ns0:member_support') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Member Support to client model Model.clientModel.service.set_member_support(clientObject) diff --git a/RFEM/TypesForNodes/nodalMeshRefinement.py b/RFEM/TypesForNodes/nodalMeshRefinement.py index 544fd8c8..e504bb9e 100644 --- a/RFEM/TypesForNodes/nodalMeshRefinement.py +++ b/RFEM/TypesForNodes/nodalMeshRefinement.py @@ -4,7 +4,7 @@ class NodalMeshRefinement(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Nodal Mesh Refinement clientObject = Model.clientModel.factory.create('ns0:nodal_mesh_refinement') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Nodal Mesh Refinement to client model Model.clientModel.service.set_nodal_mesh_refinement(clientObject) diff --git a/RFEM/TypesForNodes/nodalSupport.py b/RFEM/TypesForNodes/nodalSupport.py index aeab27f8..1b285a73 100644 --- a/RFEM/TypesForNodes/nodalSupport.py +++ b/RFEM/TypesForNodes/nodalSupport.py @@ -38,7 +38,7 @@ def __init__(self, nodes_no: str = '1 2', support_type = NodalSupportType.HINGED, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Nodal Support clientObject = Model.clientModel.factory.create('ns0:nodal_support') @@ -85,8 +85,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Nodal Support to client model Model.clientModel.service.set_nodal_support(clientObject) diff --git a/RFEM/TypesForSolids/solidContact.py b/RFEM/TypesForSolids/solidContact.py index c2fef676..92aed1d8 100644 --- a/RFEM/TypesForSolids/solidContact.py +++ b/RFEM/TypesForSolids/solidContact.py @@ -4,7 +4,7 @@ class SolidContact(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Solid Contact clientObject = Model.clientModel.factory.create('ns0:solid_contacts') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Contact to client model Model.clientModel.service.set_solid_contacts(clientObject) diff --git a/RFEM/TypesForSolids/solidGas.py b/RFEM/TypesForSolids/solidGas.py index 54d7e6bc..317c7f80 100644 --- a/RFEM/TypesForSolids/solidGas.py +++ b/RFEM/TypesForSolids/solidGas.py @@ -4,7 +4,7 @@ class SolidGas(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Solid Gas clientObject = Model.clientModel.factory.create('ns0:solid_gas') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Gas to client model Model.clientModel.service.set_solid_gas(clientObject) diff --git a/RFEM/TypesForSolids/solidMeshRefinement.py b/RFEM/TypesForSolids/solidMeshRefinement.py index 80ec791e..ac85ce00 100644 --- a/RFEM/TypesForSolids/solidMeshRefinement.py +++ b/RFEM/TypesForSolids/solidMeshRefinement.py @@ -4,7 +4,7 @@ class SolidMeshRefinement(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Solid Mesh Refinement clientObject = Model.clientModel.factory.create('ns0:solid_mesh_refinement') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Solid Mesh Refinement to client model Model.clientModel.service.set_solid_mesh_refinement(clientObject) diff --git a/RFEM/TypesForSpecialObjects/surfaceContactType.py b/RFEM/TypesForSpecialObjects/surfaceContactType.py index ad118929..ffcc74ef 100644 --- a/RFEM/TypesForSpecialObjects/surfaceContactType.py +++ b/RFEM/TypesForSpecialObjects/surfaceContactType.py @@ -4,7 +4,7 @@ class SurfaceContactType(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Surface Contact Type clientObject = Model.clientModel.factory.create('ns0:surfaces_contact_type') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Contact Type to client model Model.clientModel.service.set_surfaces_contact_type(clientObject) diff --git a/RFEM/TypesForSteelDesign/steelEffectiveLengths.py b/RFEM/TypesForSteelDesign/steelEffectiveLengths.py index 68e2c98c..ec588f8c 100644 --- a/RFEM/TypesForSteelDesign/steelEffectiveLengths.py +++ b/RFEM/TypesForSteelDesign/steelEffectiveLengths.py @@ -30,7 +30,7 @@ def __init__(self, import_from_stability_analysis_enabled: bool = False, determination_of_mcr = SteelEffectiveLengthsDeterminationMcrEurope.DETERMINATION_EUROPE_EIGENVALUE, comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Effective Length Tag @@ -189,8 +189,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Steel Effective Lengths to client model Model.clientModel.service.set_steel_effective_lengths(clientObject) diff --git a/RFEM/TypesForSurfaces/surfaceEccentricity.py b/RFEM/TypesForSurfaces/surfaceEccentricity.py index 9f7b68dc..e564b056 100644 --- a/RFEM/TypesForSurfaces/surfaceEccentricity.py +++ b/RFEM/TypesForSurfaces/surfaceEccentricity.py @@ -4,7 +4,7 @@ class SurfaceEccentricity(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Surface Eccentricity clientObject = Model.clientModel.factory.create('ns0:surface_eccentricity') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Eccentricity to client model Model.clientModel.service.set_surface_eccentricity(clientObject) diff --git a/RFEM/TypesForSurfaces/surfaceMeshRefinements.py b/RFEM/TypesForSurfaces/surfaceMeshRefinements.py index d1576d5a..c1d460f6 100644 --- a/RFEM/TypesForSurfaces/surfaceMeshRefinements.py +++ b/RFEM/TypesForSurfaces/surfaceMeshRefinements.py @@ -4,7 +4,7 @@ class SurfaceMeshRefinement(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Surface Mesh Refinement clientObject = Model.clientModel.factory.create('ns0:surface_mesh_refinement') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Mesh Refinement to client model Model.clientModel.service.set_surface_mesh_refinement(clientObject) diff --git a/RFEM/TypesForSurfaces/surfaceStiffnessModification.py b/RFEM/TypesForSurfaces/surfaceStiffnessModification.py index fd23d871..199a7b4d 100644 --- a/RFEM/TypesForSurfaces/surfaceStiffnessModification.py +++ b/RFEM/TypesForSurfaces/surfaceStiffnessModification.py @@ -4,7 +4,7 @@ class SurfaceStiffnessModification(): def __init__(self, no: int = 1, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Surface Stifness Modification clientObject = Model.clientModel.factory.create('ns0:surface_stiffness_modification') @@ -19,8 +19,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Stifness Modification to client model Model.clientModel.service.set_surface_stiffness_modification(clientObject) diff --git a/RFEM/TypesForSurfaces/surfaceSupport.py b/RFEM/TypesForSurfaces/surfaceSupport.py index d0ac308b..ab090d64 100644 --- a/RFEM/TypesForSurfaces/surfaceSupport.py +++ b/RFEM/TypesForSurfaces/surfaceSupport.py @@ -10,7 +10,7 @@ def __init__(self, c_2_x: float = 0.0, c_2_y: float = 0.0, comment: str = '', - params: dict = {}): + params: dict = None): # Client model | Surface Support clientObject = Model.clientModel.factory.create('ns0:surface_support') @@ -35,8 +35,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Surface Support to client model Model.clientModel.service.set_surface_support(clientObject) diff --git a/RFEM/TypesforConcreteDesign/ConcreteDurability.py b/RFEM/TypesforConcreteDesign/ConcreteDurability.py index 9b6037d5..63a3dec8 100644 --- a/RFEM/TypesforConcreteDesign/ConcreteDurability.py +++ b/RFEM/TypesforConcreteDesign/ConcreteDurability.py @@ -17,7 +17,7 @@ def __init__(self, additional_protection_reduction = [False], allowance_deviation = [DurabilityAllowanceDeviationType.STANDARD, False], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Concrete Durability Tag @@ -34,7 +34,7 @@ def __init__(self, additional_protection_reduction (list): Additional Protection Reduction allowance_deviation (list): Allowance Deviation Parameters comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Concrete Durabilities @@ -158,8 +158,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Global Parameter to client model Model.clientModel.service.set_concrete_durability(clientObject) diff --git a/RFEM/TypesforConcreteDesign/ConcreteEffectiveLength.py b/RFEM/TypesforConcreteDesign/ConcreteEffectiveLength.py index 70402855..6da38398 100644 --- a/RFEM/TypesforConcreteDesign/ConcreteEffectiveLength.py +++ b/RFEM/TypesforConcreteDesign/ConcreteEffectiveLength.py @@ -19,7 +19,7 @@ def __init__(self, RestraintTypeAboutZ.SUPPORT_STATUS_NO, RestraintTypeWarping.SUPPORT_STATUS_NO, "2"]], factors = [[1, 1]], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Effective Length Tag @@ -31,7 +31,7 @@ def __init__(self, nodal_supports (list): Nodal Support Table factors (list): Factors Table comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary nodal_supports = [[support_type, support_in_z, support_spring_in_y, eccentricity_type, eccentricity_ez, restraint_spring_about_x, @@ -109,8 +109,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Global Parameter to client model Model.clientModel.service.set_concrete_effective_lengths(clientObject) diff --git a/RFEM/TypesforConcreteDesign/ConcreteReinforcementDirections.py b/RFEM/TypesforConcreteDesign/ConcreteReinforcementDirections.py index ee59d1eb..8f0ad088 100644 --- a/RFEM/TypesforConcreteDesign/ConcreteReinforcementDirections.py +++ b/RFEM/TypesforConcreteDesign/ConcreteReinforcementDirections.py @@ -10,7 +10,7 @@ def __init__(self, reinforcement_direction_type = ReinforcementDirectionType.REINFORCEMENT_DIRECTION_TYPE_FIRST_REINFORCEMENT_IN_X, rotation_parameters = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Reinforcement Direction Tag @@ -19,7 +19,7 @@ def __init__(self, reinforcement_direction_type (enum): Reinforcement Direction Enumeration rotation_parameters (list): Rotation Parameters comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary """ # Client model | Concrete Durabilities @@ -49,8 +49,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Global Parameter to client model Model.clientModel.service.set_reinforcement_direction(clientObject) diff --git a/RFEM/TypesforConcreteDesign/ConcreteSurfaceReinforcements.py b/RFEM/TypesforConcreteDesign/ConcreteSurfaceReinforcements.py index 626f7eed..880b50a4 100644 --- a/RFEM/TypesforConcreteDesign/ConcreteSurfaceReinforcements.py +++ b/RFEM/TypesforConcreteDesign/ConcreteSurfaceReinforcements.py @@ -17,7 +17,7 @@ def __init__(self, reinforcement_location = [], reinforcement_acting_region = [], comment: str = '', - params: dict = {}): + params: dict = None): """ Args: no (int): Surface Reinforcement Tag @@ -33,7 +33,7 @@ def __init__(self, reinforcement_location (list): Reinforcement Location Parameters reinforcement_acting_region (list): Reinforcement Acting Region Parameters comment (str, optional): Comments - params (dict, optional): Parameters + params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary for reinforcement_type = SurfaceReinforcementType.REINFORCEMENT_TYPE_REBARS: reinforcement_type_parameters = [rebar_diameter, rebar_spacing, additional_transverse_reinforcement_enabled] @@ -165,8 +165,9 @@ def __init__(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Global Parameter to client model Model.clientModel.service.set_surface_reinforcement(clientObject) diff --git a/RFEM/enums.py b/RFEM/enums.py index 7c3e5883..cd2a4577 100644 --- a/RFEM/enums.py +++ b/RFEM/enums.py @@ -352,19 +352,6 @@ class SurfaceLoadAxisDefinitionType(Enum): ''' AXIS_DEFINITION_POINT_AND_AXIS, AXIS_DEFINITION_TWO_POINTS = range(2) -class SurfaceLoadDirection(Enum): - ''' - Surface Load Load Direction - ''' - LOAD_DIRECTION_GLOBAL_X_OR_USER_DEFINED_U_PROJECTED, LOAD_DIRECTION_GLOBAL_X_OR_USER_DEFINED_U_TRUE, LOAD_DIRECTION_GLOBAL_Y_OR_USER_DEFINED_V_PROJECTED, LOAD_DIRECTION_GLOBAL_Y_OR_USER_DEFINED_V_TRUE,\ - LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_PROJECTED, LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, LOAD_DIRECTION_LOCAL_X, LOAD_DIRECTION_LOCAL_Y, LOAD_DIRECTION_LOCAL_Z = range(9) - -class SurfaceLoadType(Enum): - ''' - Surface Load Type - ''' - LOAD_TYPE_AXIAL_STRAIN, LOAD_TYPE_FORCE, LOAD_TYPE_FORM_FINDING, LOAD_TYPE_MASS, LOAD_TYPE_PRECAMBER, LOAD_TYPE_ROTARY_MOTION, LOAD_TYPE_TEMPERATURE = range(7) - class NodeType(Enum): ''' Node Type | Enum diff --git a/RFEM/globalParameter.py b/RFEM/globalParameter.py index 6a12f26c..98ec3762 100644 --- a/RFEM/globalParameter.py +++ b/RFEM/globalParameter.py @@ -1,17 +1,18 @@ -from RFEM.initModel import Model, clearAtributes -from RFEM.enums import GlobalParameterUnitGroup, GlobalParameterDefinitionType +from RFEM.initModel import Model, clearAtributes, SetAddonStatus +from RFEM.enums import GlobalParameterUnitGroup, GlobalParameterDefinitionType, AddOn class GlobalParameter(): - def AddParameter(self, + @staticmethod + def AddParameter( no: int = 1, name: str = '', symbol: str = '', unit_group = GlobalParameterUnitGroup.LENGTH, definition_type = GlobalParameterDefinitionType.DEFINITION_TYPE_VALUE, - definition_parameter = [], + definition_parameter: list = None, comment: str = '', - params: dict = {}): + params: dict = None): ''' for definition_type = GlobalParameterDefinitionType.DEFINITION_TYPE_FORMULA: definition_parameter = [formula] @@ -56,6 +57,7 @@ def AddParameter(self, clientObject.formula = definition_parameter[0] elif definition_type.name == 'DEFINITION_TYPE_OPTIMIZATION' or definition_type.name == 'DEFINITION_TYPE_OPTIMIZATION_ASCENDING' or definition_type.name == 'DEFINITION_TYPE_OPTIMIZATION_DESCENDING': + SetAddonStatus(Model.clientModel, AddOn.cost_estimation_active) if len(definition_parameter) != 4: raise Exception('WARNING: The definition parameter needs to be of length 4. Kindly check list inputs for completeness and correctness.') clientObject.value = definition_parameter[0] @@ -72,8 +74,9 @@ def AddParameter(self, clientObject.comment = comment # Adding optional parameters via dictionary - for key in params: - clientObject[key] = params[key] + if params: + for key in params: + clientObject[key] = params[key] # Add Global Parameter to client model Model.clientModel.service.set_global_parameter(clientObject) diff --git a/UnitTests/Examples.py b/UnitTests/Examples.py index 7fe220fc..04ef6b64 100644 --- a/UnitTests/Examples.py +++ b/UnitTests/Examples.py @@ -15,9 +15,16 @@ def test_examples(): """ Run this function in order to execute all *.py files in Examples folder. This routine is exempt from standard pytest collection because it requires manual input. + + When executing in cmd always use verbose (-s) to run scripts without GUI. + Example: + pytest -s ./RFEM_Python_Client/UnitTests/Examples.py """ + print() # jump 1 line further + for path, subdirs, files in os.walk(root): for name in files: if fnmatch(name, pattern) and name != "__init__.py": example = os.path.join(path, name) - subprocess.call(example, shell=True) + process = subprocess.Popen(example, shell=True) # shell=True has to be there + process.wait() diff --git a/UnitTests/test_DesignSituations.py b/UnitTests/test_DesignSituations.py index 88d0691e..ed452614 100644 --- a/UnitTests/test_DesignSituations.py +++ b/UnitTests/test_DesignSituations.py @@ -8,8 +8,6 @@ ) sys.path.append(PROJECT_ROOT) -# Import der Bibliotheken -from RFEM.enums import * from RFEM.initModel import Model from RFEM.LoadCasesAndCombinations.staticAnalysisSettings import StaticAnalysisSettings from RFEM.LoadCasesAndCombinations.designSituation import DesignSituation diff --git a/UnitTests/test_Free_Load_Test.py b/UnitTests/test_Free_Load_Test.py index 64fd0be9..9c3b7d67 100644 --- a/UnitTests/test_Free_Load_Test.py +++ b/UnitTests/test_Free_Load_Test.py @@ -57,11 +57,11 @@ def test_free_load(): LoadCase(5 , 'Polygonlast') # Prüfung der freien Einzellasten - FreeLoad.ConcentratedLoad(FreeLoad, 1, 1, load_parameter= [5000, 4, 2]) - FreeLoad.ConcentratedLoad(FreeLoad, 2, 1, load_parameter= [50, 8, 8], load_type= FreeConcentratedLoadLoadType.LOAD_TYPE_MOMENT, load_direction= FreeConcentratedLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Y) + FreeLoad.ConcentratedLoad(1, 1, load_parameter= [5000, 4, 2]) + FreeLoad.ConcentratedLoad(2, 1, load_parameter= [50, 8, 8], load_type= FreeConcentratedLoadLoadType.LOAD_TYPE_MOMENT, load_direction= FreeConcentratedLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Y) # Prüfung der freien Linienlasten - FreeLoad.LineLoad(FreeLoad, 3, 1, '1', + FreeLoad.LineLoad(3, 1, '1', FreeLineLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeLineLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -70,7 +70,7 @@ def test_free_load(): # Prüfung der freien Rechtecklasten ## LOAD_LOCATION_RECTANGLE_CORNER_POINTS - FreeLoad.RectangularLoad(FreeLoad, 1, 2, '1', + FreeLoad.RectangularLoad(1, 2, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -78,7 +78,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CORNER_POINTS, [1, 8, 3, 10, 0]) - FreeLoad.RectangularLoad(FreeLoad, 2, 2, '1', + FreeLoad.RectangularLoad(2, 2, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR_FIRST, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -86,7 +86,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CORNER_POINTS, [4, 8, 6, 10, 0]) - FreeLoad.RectangularLoad(FreeLoad, 3, 2, '1', + FreeLoad.RectangularLoad(3, 2, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR_SECOND, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -94,7 +94,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CORNER_POINTS, [7, 8, 9, 10, 0]) - FreeLoad.RectangularLoad(FreeLoad, 4, 2, '1', + FreeLoad.RectangularLoad(4, 2, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -102,7 +102,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CORNER_POINTS, [1, 5, 3, 7, [[-3, 0.3], [-1, 0.4], [0, 1]]]) - FreeLoad.RectangularLoad(FreeLoad, 5, 2, '1', + FreeLoad.RectangularLoad(5, 2, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_VARYING_ALONG_PERIMETER, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -110,7 +110,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CORNER_POINTS, [4, 5, 6, 7, [5, 7, 0], [5, 9, 2], 0, [[0, 0.5], [90, 1.75], [180, 1.25], [270, 1], [360, 0.5]]]) - FreeLoad.RectangularLoad(FreeLoad, 6, 2, '1', + FreeLoad.RectangularLoad(6, 2, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z_AND_ALONG_PERIMETER, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -119,7 +119,7 @@ def test_free_load(): [7, 5, 9, 7, [[-3, 0.3], [-1, 0.4], [0, 1]], [5, 7, 0], [5, 9, 2], 0, [[0, 0.5], [90, 1.75], [180, 1.25], [270, 1], [360, 0.5]]]) ## LOAD_LOCATION_RECTANGLE_CENTER_AND_SIDES - FreeLoad.RectangularLoad(FreeLoad, 1, 3, '1', + FreeLoad.RectangularLoad(1, 3, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -127,7 +127,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CENTER_AND_SIDES, [2, 9, 2, 2, 0]) - FreeLoad.RectangularLoad(FreeLoad, 2, 3, '1', + FreeLoad.RectangularLoad(2, 3, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR_FIRST, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -135,7 +135,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CENTER_AND_SIDES, [5, 9, 2, 2, 0]) - FreeLoad.RectangularLoad(FreeLoad, 3, 3, '1', + FreeLoad.RectangularLoad(3, 3, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR_SECOND, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -143,7 +143,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CENTER_AND_SIDES, [8, 9, 2, 2, 0]) - FreeLoad.RectangularLoad(FreeLoad, 4, 3, '1', + FreeLoad.RectangularLoad(4, 3, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -151,7 +151,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CENTER_AND_SIDES, [2, 6, 2, 2, [[-3, 0.3], [-1, 0.4], [0, 1]]]) - FreeLoad.RectangularLoad(FreeLoad, 5, 3, '1', + FreeLoad.RectangularLoad(5, 3, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_VARYING_ALONG_PERIMETER, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -159,7 +159,7 @@ def test_free_load(): FreeRectangularLoadLoadLocationRectangle.LOAD_LOCATION_RECTANGLE_CENTER_AND_SIDES, [5, 6, 2, 2, [5, 7, 0], [5, 9, 2], 0, [[0, 0.5], [90, 1.75], [180, 1.25], [270, 1], [360, 0.5]]]) - FreeLoad.RectangularLoad(FreeLoad, 6, 3, '1', + FreeLoad.RectangularLoad(6, 3, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z_AND_ALONG_PERIMETER, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -168,41 +168,41 @@ def test_free_load(): [8, 6, 2, 2, [[-3, 0.3], [-1, 0.4], [0, 1]], [5, 7, 0], [5, 9, 2], 0, [[0, 0.5], [90, 1.75], [180, 1.25], [270, 1], [360, 0.5]]]) # Prüfung der freien Kreislasten - FreeLoad.CircularLoad(FreeLoad, 1, 4, '1', + FreeLoad.CircularLoad(1, 4, '1', FreeCircularLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeCircularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, [10000, 7.5, 5, 2]) - FreeLoad.CircularLoad(FreeLoad, 2, 4, '1', + FreeLoad.CircularLoad(2, 4, '1', FreeCircularLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeCircularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, [10000, 2500, 2.5, 5, 2]) # Prüfung der freien Polygonlasten - FreeLoad.PolygonLoad(FreeLoad, 1, 5, '1', + FreeLoad.PolygonLoad(1, 5, '1', FreePolygonLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreePolygonLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, [[1, 0], [0, 2], [2, 2]], [5000]) - FreeLoad.PolygonLoad(FreeLoad, 2, 5, '1', + FreeLoad.PolygonLoad(2, 5, '1', FreePolygonLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreePolygonLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, [[6, 0], [4, 2], [8, 2]], [5000, 2500, 1000, 1, 2, 3]) - FreeLoad.PolygonLoad(FreeLoad, 3, 5, '1', + FreeLoad.PolygonLoad(3, 5, '1', FreePolygonLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR_FIRST, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreePolygonLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, [[6, 4], [4, 6], [8, 6]], [5000, 2500, 1, 3]) - FreeLoad.PolygonLoad(FreeLoad, 4, 5, '1', + FreeLoad.PolygonLoad(4, 5, '1', FreePolygonLoadLoadDistribution.LOAD_DISTRIBUTION_LINEAR_SECOND, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreePolygonLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, diff --git a/UnitTests/test_GlobalParameters_Test.py b/UnitTests/test_GlobalParameters_Test.py index 2b1b2561..3de2d104 100644 --- a/UnitTests/test_GlobalParameters_Test.py +++ b/UnitTests/test_GlobalParameters_Test.py @@ -9,7 +9,6 @@ ) sys.path.append(PROJECT_ROOT) -# Importing the relevant libraries from RFEM.enums import GlobalParameterUnitGroup, GlobalParameterDefinitionType from RFEM.globalParameter import GlobalParameter from RFEM.initModel import Model @@ -22,7 +21,7 @@ def test_global_parameters(): Model.clientModel.service.delete_all() Model.clientModel.service.begin_modification() - GlobalParameter.AddParameter(GlobalParameter, + GlobalParameter.AddParameter( no= 1, name= 'Test_1', symbol= 'Test_1', @@ -30,35 +29,34 @@ def test_global_parameters(): definition_type= GlobalParameterDefinitionType.DEFINITION_TYPE_FORMULA, definition_parameter= ['1+1'], comment= 'Comment_1') - # TODO: issue with optimization type - # GlobalParameter.AddParameter(GlobalParameter, - # no= 2, - # name= 'Test_2', - # symbol= 'Test_2', - # unit_group= GlobalParameterUnitGroup.LOADS_DENSITY, - # definition_type= GlobalParameterDefinitionType.DEFINITION_TYPE_OPTIMIZATION, - # definition_parameter= [50, 0, 100, 4], - # comment= 'Comment_2') + GlobalParameter.AddParameter( + no= 2, + name= 'Test_2', + symbol= 'Test_2', + unit_group= GlobalParameterUnitGroup.LOADS_DENSITY, + definition_type= GlobalParameterDefinitionType.DEFINITION_TYPE_OPTIMIZATION, + definition_parameter= [50, 0, 100, 4], + comment= 'Comment_2') - # GlobalParameter.AddParameter(GlobalParameter, - # no= 3, - # name= 'Test_3', - # symbol= 'Test_3', - # unit_group= GlobalParameterUnitGroup.AREA, - # definition_type= GlobalParameterDefinitionType.DEFINITION_TYPE_OPTIMIZATION_ASCENDING, - # definition_parameter= [50, 0, 100, 4], - # comment= 'Comment_3') + GlobalParameter.AddParameter( + no= 3, + name= 'Test_3', + symbol= 'Test_3', + unit_group= GlobalParameterUnitGroup.AREA, + definition_type= GlobalParameterDefinitionType.DEFINITION_TYPE_OPTIMIZATION_ASCENDING, + definition_parameter= [50, 0, 100, 4], + comment= 'Comment_3') - # GlobalParameter.AddParameter(GlobalParameter, - # no= 4, - # name= 'Test_4', - # symbol= 'Test_4', - # unit_group= GlobalParameterUnitGroup.MATERIAL_QUANTITY_INTEGER, - # definition_type= GlobalParameterDefinitionType.DEFINITION_TYPE_OPTIMIZATION_ASCENDING, - # definition_parameter= [50, 0, 100, 4], - # comment= 'Comment_4') + GlobalParameter.AddParameter( + no= 4, + name= 'Test_4', + symbol= 'Test_4', + unit_group= GlobalParameterUnitGroup.MATERIAL_QUANTITY_INTEGER, + definition_type= GlobalParameterDefinitionType.DEFINITION_TYPE_OPTIMIZATION_ASCENDING, + definition_parameter= [50, 0, 100, 4], + comment= 'Comment_4') - GlobalParameter.AddParameter(GlobalParameter, + GlobalParameter.AddParameter( no= 5, name= 'Test_5', symbol= 'Test_5', diff --git a/UnitTests/test_LineLoads_Test.py b/UnitTests/test_LineLoads_Test.py index bea5d5d4..ae93688f 100644 --- a/UnitTests/test_LineLoads_Test.py +++ b/UnitTests/test_LineLoads_Test.py @@ -9,7 +9,7 @@ ) sys.path.append(PROJECT_ROOT) -# Import der Bibliotheken +import pytest from RFEM.Loads.lineLoad import LineLoad from RFEM.enums import LineLoadDistribution from RFEM.initModel import Model @@ -61,100 +61,95 @@ def test_line_loads(): LoadCase(2 , 'TYPE: Force') - LineLoad.Force(LineLoad, 1, 2, '1', + LineLoad.Force(1, 2, '1', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[1000]) - LineLoad.Force(LineLoad, 2, 2, '2', + LineLoad.Force(2, 2, '2', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, load_parameter=[False, 10000, 0.5]) - LineLoad.Force(LineLoad, 3, 2, '3', + LineLoad.Force(3, 2, '3', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, load_parameter=[True, True, 25000, 3, 0.25, 0.5]) - LineLoad.Force(LineLoad, 4, 2, '4', + LineLoad.Force(4, 2, '4', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, load_parameter=[True, True, True, 17000, 0.25, 0.5, 0.25]) - LineLoad.Force(LineLoad, 5, 2, '5', + LineLoad.Force(5, 2, '5', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, load_parameter=[True, True, 5000, 7500, 0.4, 0.5]) - LineLoad.Force(LineLoad, 6, 2, '6', + LineLoad.Force(6, 2, '6', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, load_parameter=[[0.2, 0.1, 200], [0.5, 0.2, 200]]) - # TODO. THESE OFFSET PARAMETERS AREN'T WORKING. THE ERROR IS APPARENTLY A BUG IN BACK-END AND HAS BEEN REPORTED. NOT SURE HOW TO PROCEED (?) - # LineLoad.Force(LineLoad, 7, 2, '7', - # load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, - # load_parameter=[True, True, 2000, 2000, 0.2, 0.5]) + LineLoad.Force(7, 2, '7', + load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, + load_parameter=[True, True, 2000, 2000, 0.2, 0.5]) - LineLoad.Force(LineLoad, 8, 2, '8', + LineLoad.Force(8, 2, '8', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, load_parameter=[750, 1000, 2500]) - # TODO. THESE OFFSET PARAMETERS AREN'T WORKING. THE ERROR IS APPARENTLY A BUG IN BACK-END AND HAS BEEN REPORTED. NOT SURE HOW TO PROCEED (?) - # LineLoad.Force(LineLoad, 9, 2, '9', - # load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_VARYING, - # load_parameter=[[1000, 500, 750], [250, 200, 600]]) + LineLoad.Force(9, 2, '9', + load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_VARYING, + load_parameter=[[1, 1, 75000], [2, 1, 60000]]) # Testing Moment Type Line Loads LoadCase(3 , 'TYPE: Moment') - LineLoad.Moment(LineLoad, 1, 3, '1', + LineLoad.Moment(1, 3, '1', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[1000]) - LineLoad.Moment(LineLoad, 2, 3, '2', + LineLoad.Moment(2, 3, '2', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, load_parameter=[False, 10000, 0.5]) - LineLoad.Moment(LineLoad, 3, 3, '3', + LineLoad.Moment(3, 3, '3', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, load_parameter=[True, True, 25000, 3, 0.25, 0.5]) - LineLoad.Moment(LineLoad, 4, 3, '4', + LineLoad.Moment(4, 3, '4', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, load_parameter=[True, True, True, 17000, 0.25, 0.5, 0.25]) - LineLoad.Moment(LineLoad, 5, 3, '5', + LineLoad.Moment(5, 3, '5', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, load_parameter=[True, True, 5000, 7500, 0.4, 0.5]) - LineLoad.Moment(LineLoad, 6, 3, '6', + LineLoad.Moment(6, 3, '6', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, load_parameter=[[0.2, 0.1, 200], [0.5, 0.2, 200]]) - # TODO. THESE OFFSET PARAMETERS AREN'T WORKING. THE ERROR IS APPARENTLY A BUG IN BACK-END AND HAS BEEN REPORTED. NOT SURE HOW TO PROCEED (?) - # LineLoad.Moment(LineLoad, 7, 3, '7', - # load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, - # load_parameter=[True, True, 2000, 2000, 0.2, 0.5]) + LineLoad.Moment(7, 3, '7', + load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, + load_parameter=[True, True, 2000, 2000, 0.2, 0.5]) - # TODO. THESE OFFSET PARAMETERS AREN'T WORKING. THE ERROR IS APPARENTLY A BUG IN BACK-END AND HAS BEEN REPORTED. NOT SURE HOW TO PROCEED (?) - # LineLoad.Moment(LineLoad, 8, 3, '8', - # load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_TAPERED, - # load_parameter=[True, True, 2000, 2000, 0.2, 0.5]) + LineLoad.Moment(8, 3, '8', + load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_TAPERED, + load_parameter=[True, True, 2000, 2000, 0.2, 0.5]) - LineLoad.Moment(LineLoad, 9, 3, '9', + LineLoad.Moment(9, 3, '9', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, load_parameter=[750, 1000, 2500]) - # TODO. THESE OFFSET PARAMETERS AREN'T WORKING. THE ERROR IS APPARENTLY A BUG IN BACK-END AND HAS BEEN REPORTED. NOT SURE HOW TO PROCEED (?) - # LineLoad.Moment(LineLoad, 10, 3, '10', - # load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_VARYING, - # load_parameter=[[1000, 500, 750], [250, 200, 600]]) + LineLoad.Moment(10, 3, '10', + load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_VARYING, + load_parameter=[[1, 1, 75000], [2, 1, 60000]]) # Testing Mass Type Line Loads LoadCase(4 , 'TYPE: Mass') - LineLoad.Mass(LineLoad, 1, 4, '1', + LineLoad.Mass(1, 4, '1', individual_mass_components= False, mass_components= [10]) - LineLoad.Mass(LineLoad, 2, 4, '2', + LineLoad.Mass(2, 4, '2', individual_mass_components=True, mass_components=[1000,1000,10000]) diff --git a/UnitTests/test_LoadCases_Test.py b/UnitTests/test_LoadCases_Test.py index 152996da..558c6035 100644 --- a/UnitTests/test_LoadCases_Test.py +++ b/UnitTests/test_LoadCases_Test.py @@ -6,9 +6,7 @@ ) sys.path.append(PROJECT_ROOT) -# Import der Bibliotheken import pytest -from RFEM.enums import * from RFEM.initModel import Model from RFEM.LoadCasesAndCombinations.staticAnalysisSettings import StaticAnalysisSettings from RFEM.LoadCasesAndCombinations.loadCase import LoadCase, DIN_Action_Category @@ -25,9 +23,9 @@ def test_load_case(): StaticAnalysisSettings() # TODO: DIN_Action_Category will only work with German localization # The action cat. is language dependent, which needs to be corrected. - LoadCase.StaticAnalysis(LoadCase, 1, 'SW', True, 1, DIN_Action_Category['1A'], [True, 0, 0, 1]) - LoadCase.StaticAnalysis(LoadCase, 2, 'SDL', True, 1, DIN_Action_Category['1C'], [True, 0.1, 0.1, 0]) - LoadCase.StaticAnalysis(LoadCase, 3, 'Snow', True, 1, DIN_Action_Category['4A'], [False]) - LoadCase.StaticAnalysis(LoadCase, 4, 'Wind', False, 1, DIN_Action_Category['5'], [False]) + LoadCase.StaticAnalysis(1, 'SW', True, 1, DIN_Action_Category['1A'], [True, 0, 0, 1]) + LoadCase.StaticAnalysis(2, 'SDL', True, 1, DIN_Action_Category['1C'], [True, 0.1, 0.1, 0]) + LoadCase.StaticAnalysis(3, 'Snow', True, 1, DIN_Action_Category['4A'], [False]) + LoadCase.StaticAnalysis(4, 'Wind', False, 1, DIN_Action_Category['5'], [False]) Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_LoadDistributionSurface_Test.py b/UnitTests/test_LoadDistributionSurface_Test.py index 1368c0ff..6cde470c 100644 --- a/UnitTests/test_LoadDistributionSurface_Test.py +++ b/UnitTests/test_LoadDistributionSurface_Test.py @@ -36,7 +36,7 @@ def test_load_distribution_surface(): # Standard Even Load Distribution Node(5, 0, -15, 0), Node(6, 10, -15, 0), Node(7, 10, -5, 0), Node(8, 0, -5, 0) Line(5, '5 6'), Line(6, '6 7'), Line(7, '7 8'), Line(8, '8 5') - Surface.LoadDistribution(Surface, 2, '5 6 7 8', SurfaceLoadDistributionDirection.LOAD_TRANSFER_DIRECTION_IN_BOTH, + Surface.LoadDistribution(2, '5 6 7 8', SurfaceLoadDistributionDirection.LOAD_TRANSFER_DIRECTION_IN_BOTH, True, 10, loaded_lines='6 7 8', excluded_lines='5') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_MemberLoad_test.py b/UnitTests/test_MemberLoad_test.py index 9e2e32a6..a55c5aec 100644 --- a/UnitTests/test_MemberLoad_test.py +++ b/UnitTests/test_MemberLoad_test.py @@ -57,207 +57,207 @@ def test_member_loads(): MemberLoad(1, 1, '1', LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, 5000) ## Force Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.Force(0, 2, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) + MemberLoad.Force(2, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) ## Force Type Member Load with LOAD_DISTRIBUTION_UNIFORM with Eccentricity ## - MemberLoad.Force(0, 3, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000], force_eccentricity=True, params={'eccentricity_y_at_start' : 0.01, 'eccentricity_z_at_start': 0.02}) + MemberLoad.Force(3, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000], force_eccentricity=True, params={'eccentricity_y_at_start' : 0.01, 'eccentricity_z_at_start': 0.02}) ## Force Type Member Load with LOAD_DISTRIBUTION_UNIFORM_TOTAL ## - MemberLoad.Force(0, 4, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM_TOTAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) + MemberLoad.Force(4, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM_TOTAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) ## Force Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberLoad.Force(0, 5, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) + MemberLoad.Force(5, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) ## Force Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberLoad.Force(0, 6, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) + MemberLoad.Force(6, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) ## Force Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberLoad.Force(0, 7, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) + MemberLoad.Force(7, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) ## Force Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2x ## - MemberLoad.Force(0, 8, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) + MemberLoad.Force(8, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) ## Force Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberLoad.Force(0, 9, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberLoad.Force(9, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Force Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.Force(0, 10, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberLoad.Force(10, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Force Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.Force(0, 11, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberLoad.Force(11, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Force Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.Force(0, 12, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) + MemberLoad.Force(12, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) ## Force Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.Force(0, 13, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberLoad.Force(13, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Force Type Member Load with LOAD_DISTRIBUTION_VARYING_IN_Z ## - MemberLoad.Force(0, 14, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberLoad.Force(14, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Moment Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.Moment(0, 15, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) + MemberLoad.Moment(15, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) ## Moment Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberLoad.Moment(0, 16, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) + MemberLoad.Moment(16, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) ## Moment Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberLoad.Moment(0, 17, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) + MemberLoad.Moment(17, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) ## Moment Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberLoad.Moment(0, 18, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) + MemberLoad.Moment(18, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) ## Moment Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2x ## - MemberLoad.Moment(0, 19, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) + MemberLoad.Moment(19, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) ## Moment Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberLoad.Moment(0, 20, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberLoad.Moment(20, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Moment Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.Moment(0, 21, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberLoad.Moment(21, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Moment Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.Moment(0, 22, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberLoad.Moment(22, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Moment Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.Moment(0, 23, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) + MemberLoad.Moment(23, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) ## Moment Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.Moment(0, 24, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberLoad.Moment(24, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Mass Type Member Load ## - MemberLoad.Mass(0, 25, 1, mass_components=[1000]) + MemberLoad.Mass(25, 1, mass_components=[1000]) ## Temperature Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.Temperature(0, 26, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) + MemberLoad.Temperature(26, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) ## Temperature Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.Temperature(0, 27, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberLoad.Temperature(27, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## Temperature Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.Temperature(0, 28, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberLoad.Temperature(28, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## Temperature Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.Temperature(0, 29, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) + MemberLoad.Temperature(29, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) ## Temperature Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.Temperature(0, 30, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) + MemberLoad.Temperature(30, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) ## TemperatureChange Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.TemperatureChange(0, 31, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) + MemberLoad.TemperatureChange(31, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) ## TemperatureChange Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.TemperatureChange(0, 32, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberLoad.TemperatureChange(32, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## TemperatureChange Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.TemperatureChange(0, 33, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberLoad.TemperatureChange(33, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## TemperatureChange Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.TemperatureChange(0, 34, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) + MemberLoad.TemperatureChange(34, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) ## TemperatureChange Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.TemperatureChange(0, 35, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) + MemberLoad.TemperatureChange(35, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) ## AxialStrain Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.AxialStrain(0, 36, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[0.005]) + MemberLoad.AxialStrain(36, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[0.005]) ## AxialStrain Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.AxialStrain(0, 37, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.AxialStrain(37, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) ## AxialStrain Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.AxialStrain(0, 38, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.AxialStrain(38, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) ## AxialStrain Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.AxialStrain(0, 39, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[1, 2, 3]) + MemberLoad.AxialStrain(39, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[1, 2, 3]) ## AxialStrain Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.AxialStrain(0, 40, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) + MemberLoad.AxialStrain(40, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) ## AxialDisplacement Type Member Load ## - MemberLoad.AxialDisplacement(0, 41, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 0.05) + MemberLoad.AxialDisplacement(41, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 0.05) ## Precamber Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.Precamber(0, 42, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[0.005]) + MemberLoad.Precamber(42, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[0.005]) ## Precamber Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.Precamber(0, 43, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.Precamber(43, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Precamber Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.Precamber(0, 44, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.Precamber(44, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Precamber Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.Precamber(0, 45, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) + MemberLoad.Precamber(45, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) ## Precamber Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.Precamber(0, 46, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) + MemberLoad.Precamber(46, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) ## InitialPrestress Type Member Load ## - MemberLoad.InitialPrestress(0, 47, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) + MemberLoad.InitialPrestress(47, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) ## Displacement Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.Displacement(0, 48, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) + MemberLoad.Displacement(48, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberLoad.Displacement(0, 49, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) + MemberLoad.Displacement(49, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberLoad.Displacement(0, 50, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) + MemberLoad.Displacement(50, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberLoad.Displacement(0, 51, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) + MemberLoad.Displacement(51, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2 ## - MemberLoad.Displacement(0, 52, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) + MemberLoad.Displacement(52, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberLoad.Displacement(0, 53, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[0.001, 1, 1], [0.002, 2, 1]]) + MemberLoad.Displacement(53, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[0.001, 1, 1], [0.002, 2, 1]]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.Displacement(0, 54, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.Displacement(54, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.Displacement(0, 55, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.Displacement(55, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.Displacement(0, 56, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) + MemberLoad.Displacement(56, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) ## Displacement Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.Displacement(0, 57, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) + MemberLoad.Displacement(57, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberLoad.Rotation(0, 58, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) + MemberLoad.Rotation(58, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberLoad.Rotation(0, 59, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) + MemberLoad.Rotation(59, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberLoad.Rotation(0, 60, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) + MemberLoad.Rotation(60, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberLoad.Rotation(0, 61, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) + MemberLoad.Rotation(61, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_2 ## - MemberLoad.Rotation(0, 62, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) + MemberLoad.Rotation(62, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberLoad.Rotation(0, 63, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[1, 1, 285], [2, 1, 293]]) + MemberLoad.Rotation(63, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[1, 1, 285], [2, 1, 293]]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberLoad.Rotation(0, 64, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.Rotation(64, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_TAPERED ## - MemberLoad.Rotation(0, 65, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberLoad.Rotation(65, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberLoad.Rotation(0, 66, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) + MemberLoad.Rotation(66, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) ## Rotation Type Member Load with LOAD_DISTRIBUTION_VARYING ## - MemberLoad.Rotation(0, 67, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) + MemberLoad.Rotation(67, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) ## PipeContentFull Type Member Load ## - MemberLoad.PipeContentFull(0, 68, 1, '2', MemberLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, 50) + MemberLoad.PipeContentFull(68, 1, '2', MemberLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, 50) - MemberLoad.RotaryMotion(0, 69, 1, '2', 2, 3, MemberLoadAxisDefinitionType.AXIS_DEFINITION_POINT_AND_AXIS, axis_definition_p1=[1,1,0]) + MemberLoad.RotaryMotion(69, 1, '2', 2, 3, MemberLoadAxisDefinitionType.AXIS_DEFINITION_POINT_AND_AXIS, axis_definition_p1=[1,1,0]) #Calculate_all() # Don't use in unit tests. See template for more info. diff --git a/UnitTests/test_MemberSetLoad_test.py b/UnitTests/test_MemberSetLoad_test.py index 368a8690..49bef1cc 100644 --- a/UnitTests/test_MemberSetLoad_test.py +++ b/UnitTests/test_MemberSetLoad_test.py @@ -64,214 +64,214 @@ def test_member_set_load(): MemberSetLoad(1, 1, '1', LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, 5000) ## Force Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.Force(0, 2, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) + MemberSetLoad.Force(2, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM with Eccentricity ## - MemberSetLoad.Force(0, 3, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000], force_eccentricity=True, params={'eccentricity_y_at_start' : 0.01, 'eccentricity_z_at_start': 0.02}) + MemberSetLoad.Force(3, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000], force_eccentricity=True, params={'eccentricity_y_at_start' : 0.01, 'eccentricity_z_at_start': 0.02}) ## Force Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM_TOTAL ## - MemberSetLoad.Force(0, 4, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM_TOTAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) + MemberSetLoad.Force(4, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM_TOTAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberSetLoad.Force(0, 5, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) + MemberSetLoad.Force(5, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberSetLoad.Force(0, 6, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) + MemberSetLoad.Force(6, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberSetLoad.Force(0, 7, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) + MemberSetLoad.Force(7, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2x ## - MemberSetLoad.Force(0, 8, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) + MemberSetLoad.Force(8, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberSetLoad.Force(0, 9, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberSetLoad.Force(9, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.Force(0, 10, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberSetLoad.Force(10, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.Force(0, 11, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberSetLoad.Force(11, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.Force(0, 12, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) + MemberSetLoad.Force(12, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.Force(0, 13, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberSetLoad.Force(13, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Force Type Member Set Load with LOAD_DISTRIBUTION_VARYING_IN_Z ## - MemberSetLoad.Force(0, 14, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberSetLoad.Force(14, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.Moment(0, 15, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) + MemberSetLoad.Moment(15, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[5000]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberSetLoad.Moment(0, 16, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) + MemberSetLoad.Moment(16, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, 5000, 1.2]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberSetLoad.Moment(0, 17, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) + MemberSetLoad.Moment(17, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 2, 1, 2]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberSetLoad.Moment(0, 18, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) + MemberSetLoad.Moment(18, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, False, 5000, 1, 2, 3]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2x ## - MemberSetLoad.Moment(0, 19, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) + MemberSetLoad.Moment(19, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 5000, 6000, 1, 2]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberSetLoad.Moment(0, 20, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberSetLoad.Moment(20, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.Moment(0, 21, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberSetLoad.Moment(21, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.Moment(0, 22, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) + MemberSetLoad.Moment(22, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[False, False, 4000, 8000, 1, 2]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.Moment(0, 23, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) + MemberSetLoad.Moment(23, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[4000, 8000, 12000]) ## Moment Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.Moment(0, 24, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) + MemberSetLoad.Moment(24, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 4000], [2, 1, 5000]]) ## Mass Type Member Set Load ## - MemberSetLoad.Mass(0, 25, 1, mass_components=[1000]) + MemberSetLoad.Mass(25, 1, mass_components=[1000]) ## Temperature Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.Temperature(0, 26, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) + MemberSetLoad.Temperature(26, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) ## Temperature Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.Temperature(0, 27, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberSetLoad.Temperature(27, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## Temperature Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.Temperature(0, 28, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberSetLoad.Temperature(28, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## Temperature Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.Temperature(0, 29, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) + MemberSetLoad.Temperature(29, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) ## Temperature Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.Temperature(0, 30, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) + MemberSetLoad.Temperature(30, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) ## TemperatureChange Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.TemperatureChange(0, 31, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) + MemberSetLoad.TemperatureChange(31, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[18, 2]) ## TemperatureChange Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.TemperatureChange(0, 32, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberSetLoad.TemperatureChange(32, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## TemperatureChange Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.TemperatureChange(0, 33, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) + MemberSetLoad.TemperatureChange(33, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, 18, 20, False, False, 1, 2]) ## TemperatureChange Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.TemperatureChange(0, 34, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) + MemberSetLoad.TemperatureChange(34, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3, 4, 5, 6]) ## TemperatureChange Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.TemperatureChange(0, 35, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) + MemberSetLoad.TemperatureChange(35, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) ## AxialStrain Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.AxialStrain(0, 36, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[0.005]) + MemberSetLoad.AxialStrain(36, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[0.005]) ## AxialStrain Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.AxialStrain(0, 37, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.AxialStrain(37, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) ## AxialStrain Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.AxialStrain(0, 38, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.AxialStrain(38, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[12, 16, False, False, 1, 2]) ## AxialStrain Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.AxialStrain(0, 39, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[1, 2, 3]) + MemberSetLoad.AxialStrain(39, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[1, 2, 3]) ## AxialStrain Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.AxialStrain(0, 40, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) + MemberSetLoad.AxialStrain(40, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, load_parameter=[[1, 1, 285, 289], [2, 1, 293, 297]]) ## AxialDisplacement Type Member Set Load ## - MemberSetLoad.AxialDisplacement(0, 41, 1, '1', MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, 0.05) + MemberSetLoad.AxialDisplacement(41, 1, '1', MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, 0.05) ## Precamber Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.Precamber(0, 42, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[0.005]) + MemberSetLoad.Precamber(42, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[0.005]) ## Precamber Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.Precamber(0, 43, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.Precamber(43, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Precamber Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.Precamber(0, 44, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.Precamber(44, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Precamber Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.Precamber(0, 45, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) + MemberSetLoad.Precamber(45, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) ## Precamber Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.Precamber(0, 46, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) + MemberSetLoad.Precamber(46, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) ## InitialPrestress Type Member Set Load ## - MemberSetLoad.InitialPrestress(0, 47, 1, '1', MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) + MemberSetLoad.InitialPrestress(47, 1, '1', MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.Displacement(0, 48, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) + MemberSetLoad.Displacement(48, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberSetLoad.Displacement(0, 49, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) + MemberSetLoad.Displacement(49, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberSetLoad.Displacement(0, 50, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) + MemberSetLoad.Displacement(50, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberSetLoad.Displacement(0, 51, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) + MemberSetLoad.Displacement(51, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2 ## - MemberSetLoad.Displacement(0, 52, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) + MemberSetLoad.Displacement(52, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberSetLoad.Displacement(0, 53, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[0.001, 1, 1], [0.002, 2, 1]]) + MemberSetLoad.Displacement(53, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[0.001, 1, 1], [0.002, 2, 1]]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.Displacement(0, 54, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.Displacement(54, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.Displacement(0, 55, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.Displacement(55, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.Displacement(0, 56, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) + MemberSetLoad.Displacement(56, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) ## Displacement Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.Displacement(0, 57, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) + MemberSetLoad.Displacement(57, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_UNIFORM ## - MemberSetLoad.Rotation(0, 58, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) + MemberSetLoad.Rotation(58, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_1 ## - MemberSetLoad.Rotation(0, 59, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) + MemberSetLoad.Rotation(59, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_1, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, 1]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_N ## - MemberSetLoad.Rotation(0, 60, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) + MemberSetLoad.Rotation(60, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_N, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, 1, 2]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2x2 ## - MemberSetLoad.Rotation(0, 61, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) + MemberSetLoad.Rotation(61, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2x2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, False, False, False, 1, 2, 3]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_2 ## - MemberSetLoad.Rotation(0, 62, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) + MemberSetLoad.Rotation(62, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_2, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6, False, False, 1, 2]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_CONCENTRATED_VARYING ## - MemberSetLoad.Rotation(0, 63, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[1, 1, 285], [2, 1, 293]]) + MemberSetLoad.Rotation(63, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_CONCENTRATED_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, [[1, 1, 285], [2, 1, 293]]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_TRAPEZOIDAL ## - MemberSetLoad.Rotation(0, 64, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.Rotation(64, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TRAPEZOIDAL, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_TAPERED ## - MemberSetLoad.Rotation(0, 65, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) + MemberSetLoad.Rotation(65, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_TAPERED, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[12, 16, False, False, 1, 2]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_PARABOLIC ## - MemberSetLoad.Rotation(0, 66, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) + MemberSetLoad.Rotation(66, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_PARABOLIC, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[1, 2, 3]) ## Rotation Type Member Set Load with LOAD_DISTRIBUTION_VARYING ## - MemberSetLoad.Rotation(0, 67, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) + MemberSetLoad.Rotation(67, 1, '1', MemberSetLoadDistribution.LOAD_DISTRIBUTION_VARYING, MemberSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, load_parameter=[[1, 1, 285], [2, 1, 293]]) ## Pipe Content Full Type Member Set Load ## - MemberSetLoad.PipeContentFull(0, 68, 1, '2', specific_weight=5000) + MemberSetLoad.PipeContentFull(68, 1, '2', specific_weight=5000) ## Pipe Content Partial Type Member Set Load ## - MemberSetLoad.PipeContentPartial(0, 69, 1, '2', specific_weight=2000, filling_height=0.1) + MemberSetLoad.PipeContentPartial(69, 1, '2', specific_weight=2000, filling_height=0.1) ## Pipe Internal Pressure Type Member Set Load ## - MemberSetLoad.PipeInternalPressure(0, 70, 1, '2', 2000) + MemberSetLoad.PipeInternalPressure(70, 1, '2', 2000) ## Pipe Rotary Motion Type Member Set Load ## - MemberSetLoad.RotaryMotion(0, 71, 1, '2', 3.5, 5, + MemberSetLoad.RotaryMotion(71, 1, '2', 3.5, 5, MemberSetLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, MemberLoadAxisDefinitionAxisOrientation.AXIS_NEGATIVE, MemberSetLoadAxisDefinition.AXIS_Y, [10,11,12], [0,5,6]) diff --git a/UnitTests/test_Member_test.py b/UnitTests/test_Member_test.py index 529112e3..3c72c912 100644 --- a/UnitTests/test_Member_test.py +++ b/UnitTests/test_Member_test.py @@ -46,93 +46,93 @@ def test_all_member_types(): Member(1, 1, 2, 0, 1, 1) # Beam Member with Angle Rotation - Member.Beam(0, 2, 3, 4, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [15], 1, 1) + Member.Beam(2, 3, 4, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [15], 1, 1) # Beam Member with Node Rotation - Member.Beam(0, 3, 5, 6, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_HELP_NODE, [5, MemberRotationPlaneType.ROTATION_PLANE_XY], 1, 1) + Member.Beam(3, 5, 6, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_HELP_NODE, [5, MemberRotationPlaneType.ROTATION_PLANE_XY], 1, 1) # Beam Member with Member Hinge MemberHinge(1, "Local", rotational_release_my= 0.0, rotational_release_mz=0.0) - Member.Beam(0, 4, 7, 8, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, params={'member_hinge_start': 1, 'member_hinge_end' : 1}) + Member.Beam(4, 7, 8, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, params={'member_hinge_start': 1, 'member_hinge_end' : 1}) # Beam Member with End Modifications - Member.Beam(0, 5, 9, 10, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, + Member.Beam(5, 9, 10, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, params={'end_modifications_member_start_extension': 1, 'end_modifications_member_start_slope_y': 0.03, 'end_modifications_member_start_slope_z': 0.05, 'end_modifications_member_end_extension': 4, 'end_modifications_member_end_slope_y': 0.08, 'end_modifications_member_end_slope_z': 0.1}) # Beam Member with Linear Distribution - Member.Beam(0, 6, 11, 12, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_LINEAR, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [MemberSectionAlignment.SECTION_ALIGNMENT_BOTTOM]) + Member.Beam(6, 11, 12, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_LINEAR, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [MemberSectionAlignment.SECTION_ALIGNMENT_BOTTOM]) # Beam Member with Tapered at Both Sides - Member.Beam(0, 7, 13, 14, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_TAPERED_AT_BOTH_SIDES, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 2, 2, [True, True, 0.25, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC, 1]) + Member.Beam(7, 13, 14, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_TAPERED_AT_BOTH_SIDES, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 2, 2, [True, True, 0.25, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC, 1]) # Beam Member with Tapered at the Start - Member.Beam(0, 8, 15, 16, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_TAPERED_AT_START_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 2, 1, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) + Member.Beam(8, 15, 16, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_TAPERED_AT_START_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 2, 1, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) # Beam Member with Tapered at the End - Member.Beam(0, 9, 17, 18, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_TAPERED_AT_END_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) + Member.Beam(9, 17, 18, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_TAPERED_AT_END_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) # Beam Member with Tapered at the End - Member.Beam(0, 10, 19, 20, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_SADDLE, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, [True, 0.5, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC, 2]) + Member.Beam(10, 19, 20, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_SADDLE, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, [True, 0.5, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC, 2]) # Beam Member with Offset at Both End - Member.Beam(0, 11, 21, 22, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_OFFSET_AT_BOTH_SIDES, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, [True, True, 0.25, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC, 2]) + Member.Beam(11, 21, 22, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_OFFSET_AT_BOTH_SIDES, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 1, [True, True, 0.25, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC, 2]) # Beam Member with Offset at Start - Member.Beam(0, 12, 23, 24, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_OFFSET_AT_START_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) + Member.Beam(12, 23, 24, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_OFFSET_AT_START_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) # Beam Member with Offset at End - Member.Beam(0, 13, 25, 26, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_OFFSET_AT_END_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) + Member.Beam(13, 25, 26, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_OFFSET_AT_END_OF_MEMBER, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1, 2, [True, 0.25, MemberSectionAlignment.SECTION_ALIGNMENT_CENTRIC]) # Rigid Member - Member.Rigid(0, 14, 27, 28, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) + Member.Rigid(14, 27, 28, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) # Rigid Member with Member Hinge - Member.Rigid(0, 15, 29, 30, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], params={'member_hinge_start' : 1, 'member_hinge_end': 1}) + Member.Rigid(15, 29, 30, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], params={'member_hinge_start' : 1, 'member_hinge_end': 1}) # Truss Member - Member.Truss(0, 16, 31, 32, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) + Member.Truss(16, 31, 32, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) # Truss Only N Member - Member.TrussOnlyN(0, 17, 33, 34, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) + Member.TrussOnlyN(17, 33, 34, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) # Tension Member - Member.Tension(0, 18, 35, 36, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) + Member.Tension(18, 35, 36, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) # Compression Member - Member.Compression(0, 19, 37, 38, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) + Member.Compression(19, 37, 38, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) # Buckling Member - Member.Buckling(0, 20, 39, 40, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) + Member.Buckling(20, 39, 40, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) # Cable Member - Member.Cable(0, 21, 41, 42, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) + Member.Cable(21, 41, 42, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0]) # Result Beam 1 - Member.ResultBeam(0, 22, 43, 44, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_WITHIN_CUBOID_QUADRATIC, [0], 1, 1, integration_parameters = [0.1]) + Member.ResultBeam(22, 43, 44, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_WITHIN_CUBOID_QUADRATIC, [0], 1, 1, integration_parameters = [0.1]) # Result Beam 2 - Member.ResultBeam(0, 23, 45, 46, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_WITHIN_CUBOID_GENERAL, [0], 1, 1, integration_parameters=[0.1, 0.2, 0.3, 0.4]) + Member.ResultBeam(23, 45, 46, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_WITHIN_CUBOID_GENERAL, [0], 1, 1, integration_parameters=[0.1, 0.2, 0.3, 0.4]) # Result Beam 3 - Member.ResultBeam(0, 24, 47, 48, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_WITHIN_CYLINDER, [0], 1, 1, integration_parameters=[0.5]) + Member.ResultBeam(24, 47, 48, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_WITHIN_CYLINDER, [0], 1, 1, integration_parameters=[0.5]) # Result Beam 4 - Member.ResultBeam(0, 25, 49, 50, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_FROM_LISTED_OBJECT, [0], 1, 1) + Member.ResultBeam(25, 49, 50, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_FROM_LISTED_OBJECT, [0], 1, 1) # Member Definable Stiffness MemberDefinableStiffness(1) - Member.DefinableStiffness(0, 26, 51, 52, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1) + Member.DefinableStiffness(26, 51, 52, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0], 1) # Member Coupling Rigid Rigid - Member.CouplingRigidRigid(0, 27, 53, 54) + Member.CouplingRigidRigid(27, 53, 54) # Member Coupling Rigid Hinge - Member.CouplingRigidHinge(0, 28, 55, 56) + Member.CouplingRigidHinge(28, 55, 56) # Member Coupling Hinge Rigid - Member.CouplingHingeRigid(0, 29, 57, 58) + Member.CouplingHingeRigid(29, 57, 58) # Member Coupling Hinge Hinge - Member.CouplingHingeHinge(0, 30, 59, 60) + Member.CouplingHingeHinge(30, 59, 60) Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_MembraneSurface_Test.py b/UnitTests/test_MembraneSurface_Test.py index 2d94e472..82c15797 100644 --- a/UnitTests/test_MembraneSurface_Test.py +++ b/UnitTests/test_MembraneSurface_Test.py @@ -36,7 +36,7 @@ def test_membrane_surface(): # Standard planar Surface Node(5, 0, -15, 0), Node(6, 10, -15, 0), Node(7, 10, -5, 0), Node(8, 0, -5, 0) Line(5, '5 6'), Line(6, '6 7'), Line(7, '7 8'), Line(8, '8 5') - Surface.Membrane(Surface, 2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') + Surface.Membrane(2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') # Standard NURBS Surface @@ -51,13 +51,13 @@ def test_membrane_surface(): Node(16, 10.0, 5.0, -2.5) ## NURBS-Curve Definition - Line.NURBS(Line, 9, '9 10 11', control_points= [[0, 0, 0], [5, 0, -2.5], [10, 0, 0]], weights= [1, 1, 1],params= {'nurbs_order':3}) - Line.NURBS(Line, 10, '12 13 14', control_points= [[0, 10, 0], [5, 10, -2.5], [10, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 11, '9 15 12', control_points= [[0, 0, 0], [0, 5, -2.5], [0, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 12, '11 16 14', control_points= [[10, 0, 0], [10, 5, -2.5], [10, 5, -2.5]], weights= [1, 1, 1], params= {'nurbs_order':3}) + Line.NURBS(9, '9 10 11') + Line.NURBS(10, '12 13 14') + Line.NURBS(11, '9 15 12') + Line.NURBS(12, '11 16 14') # Surfaces Definition - Surface.Membrane(Surface, 3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') + Surface.Membrane(3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') # Standard Quadrangle @@ -68,12 +68,12 @@ def test_membrane_surface(): Node(20, 10, 20, 0) # Boundary Lines - Line.Arc(1, 13, [17, 18], [5, 15, -2]) - Line.Arc(1, 14, [19, 20], [5, 20, -2]) + Line.Arc(13, [17, 18], [5, 15, -2]) + Line.Arc(14, [19, 20], [5, 20, -2]) Line(15, '17 19') Line(16, '18 20') # Quadrangle Defintion - Surface.Membrane(Surface, 4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') + Surface.Membrane(4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_MembraneWithoutTensionSurface_Test.py b/UnitTests/test_MembraneWithoutTensionSurface_Test.py index c3e598bf..902d82fa 100644 --- a/UnitTests/test_MembraneWithoutTensionSurface_Test.py +++ b/UnitTests/test_MembraneWithoutTensionSurface_Test.py @@ -36,11 +36,11 @@ def test_membrane_without_tension_surface(): # Standard planar Surface Node(5, 0, -15, 0), Node(6, 10, -15, 0), Node(7, 10, -5, 0), Node(8, 0, -5, 0) Line(5, '5 6'), Line(6, '6 7'), Line(7, '7 8'), Line(8, '8 5') - Surface.WithoutMemberaneTension(Surface, 2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') + Surface.WithoutMemberaneTension(2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') # Standard NURBS Surface - ## Define Nodes + # Define Nodes Node(9, 0.0, 0.0, 0.0) Node(10, 5.0, 0.0, -2.5) Node(11, 10.0, 0.0, 0.0) @@ -50,14 +50,14 @@ def test_membrane_without_tension_surface(): Node(15, 0.0, 5.0, -2,5) Node(16, 10.0, 5.0, -2.5) - ## NURBS-Curve Definition - Line.NURBS(Line, 9, '9 10 11', control_points= [[0, 0, 0], [5, 0, -2.5], [10, 0, 0]], weights= [1, 1, 1],params= {'nurbs_order':3}) - Line.NURBS(Line, 10, '12 13 14', control_points= [[0, 10, 0], [5, 10, -2.5], [10, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 11, '9 15 12', control_points= [[0, 0, 0], [0, 5, -2.5], [0, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 12, '11 16 14', control_points= [[10, 0, 0], [10, 5, -2.5], [10, 5, -2.5]], weights= [1, 1, 1], params= {'nurbs_order':3}) + # NURBS-Curve Definition + Line.NURBS(9, '9 10 11') + Line.NURBS(10, '12 13 14') + Line.NURBS(11, '9 15 12') + Line.NURBS(12, '11 16 14') # Surfaces Definition - Surface.WithoutMemberaneTension(Surface, 3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') + Surface.WithoutMemberaneTension(3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') # Standard Quadrangle @@ -68,12 +68,12 @@ def test_membrane_without_tension_surface(): Node(20, 10, 20, 0) # Boundary Lines - Line.Arc(1, 13, [17, 18], [5, 15, -2]) - Line.Arc(1, 14, [19, 20], [5, 20, -2]) + Line.Arc(13, [17, 18], [5, 15, -2]) + Line.Arc(14, [19, 20], [5, 20, -2]) Line(15, '17 19') Line(16, '18 20') # Quadrangle Defintion - Surface.WithoutMemberaneTension(Surface, 4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') + Surface.WithoutMemberaneTension(4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_ModelCheck.py b/UnitTests/test_ModelCheck.py index 5303aade..c323efeb 100644 --- a/UnitTests/test_ModelCheck.py +++ b/UnitTests/test_ModelCheck.py @@ -62,18 +62,18 @@ def test_model_check(): Model.clientModel.service.finish_modification() - identical_nodes = ModelCheck.GetIdenticalNodes(0, 0.0005) + identical_nodes = ModelCheck.GetIdenticalNodes(0.0005) assert identical_nodes[0][0] == "1,2" assert identical_nodes[0][1] == "3,4" - ModelCheck.DeleteUnusedNodes(0, 0.0005, identical_nodes) - connected_lines = ModelCheck.GetNotConnectedLines(0, 0.0005) + ModelCheck.DeleteUnusedNodes(0.0005, identical_nodes) + connected_lines = ModelCheck.GetNotConnectedLines(0.0005) assert connected_lines[0][0] == "1,2" assert connected_lines[0][1] == "5,6" - ModelCheck.CrossLines(0, 0.0005, connected_lines) - ModelCheck.GetNotConnectedMembers(0, 0.0005) - overlapping_lines = ModelCheck.GetOverlappingLines(0) + ModelCheck.CrossLines(0.0005, connected_lines) + ModelCheck.GetNotConnectedMembers(0.0005) + overlapping_lines = ModelCheck.GetOverlappingLines() assert overlapping_lines[0][0] == "3,4" assert overlapping_lines[0][1] == "7,8" - overlapping_members = ModelCheck.GetOverlappingMembers(0) + overlapping_members = ModelCheck.GetOverlappingMembers() assert overlapping_members[0][0] == "3,4" diff --git a/UnitTests/test_NodalLoad_test.py b/UnitTests/test_NodalLoad_test.py index 1ab46e8c..b973238f 100644 --- a/UnitTests/test_NodalLoad_test.py +++ b/UnitTests/test_NodalLoad_test.py @@ -65,16 +65,16 @@ def test_nodal_load(): NodalLoad(1, 1, '2', LoadDirectionType.LOAD_DIRECTION_LOCAL_X, 5000) # Force Type Nodal Load - NodalLoad.Force(0, 2, 1, '2', LoadDirectionType.LOAD_DIRECTION_LOCAL_X, 5000) + NodalLoad.Force(2, 1, '2', LoadDirectionType.LOAD_DIRECTION_LOCAL_X, 5000) # Moment Type Nodal Load - NodalLoad.Moment(0, 3, 1, '4', LoadDirectionType.LOAD_DIRECTION_LOCAL_X, 5000) + NodalLoad.Moment(3, 1, '4', LoadDirectionType.LOAD_DIRECTION_LOCAL_X, 5000) # Component Type Nodal Load - NodalLoad.Components(0, 4, 1, '6', [5000, 5000, 0, 0, 5000, 0]) + NodalLoad.Components(4, 1, '6', [5000, 5000, 0, 0, 5000, 0]) #Mass Type Nodal Load - NodalLoad.Mass(0, 5, 1, '8', True, [5000, 5000, 0, 0, 5000, 0]) + NodalLoad.Mass(5, 1, '8', True, [5000, 5000, 0, 0, 5000, 0]) #Calculate_all() # Don't use in unit tests. See template for more info. diff --git a/UnitTests/test_RigidLinks.py b/UnitTests/test_RigidLinks.py index f0a79e7c..a20afa80 100644 --- a/UnitTests/test_RigidLinks.py +++ b/UnitTests/test_RigidLinks.py @@ -55,9 +55,9 @@ def test_rigid_links(): Surface(2, '5-8') RigidLink(1, 3, 6) - RigidLink.LineToLine(0, 2, 3, 8) + RigidLink.LineToLine(2, 3, 8) # RigidLink.LineToSurface(0, 3, 3, 2) # bug 24282 - RigidLink.Diapragm(0, 4,'3 4', '6 9') + RigidLink.Diapragm(4,'3 4', '6 9') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_RigidSurface_Test.py b/UnitTests/test_RigidSurface_Test.py index a16ff837..58463afd 100644 --- a/UnitTests/test_RigidSurface_Test.py +++ b/UnitTests/test_RigidSurface_Test.py @@ -36,11 +36,11 @@ def test_rigid_surface(): # Standard planar Surface Node(5, 0, -15, 0), Node(6, 10, -15, 0), Node(7, 10, -5, 0), Node(8, 0, -5, 0) Line(5, '5 6'), Line(6, '6 7'), Line(7, '7 8'), Line(8, '8 5') - Surface.Rigid(Surface, 2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') + Surface.Rigid(2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') # Standard NURBS Surface - ## Define Nodes + # Define Nodes Node(9, 0.0, 0.0, 0.0) Node(10, 5.0, 0.0, -2.5) Node(11, 10.0, 0.0, 0.0) @@ -50,14 +50,14 @@ def test_rigid_surface(): Node(15, 0.0, 5.0, -2,5) Node(16, 10.0, 5.0, -2.5) - ## NURBS-Curve Definition - Line.NURBS(Line, 9, '9 10 11', control_points= [[0, 0, 0], [5, 0, -2.5], [10, 0, 0]], weights= [1, 1, 1],params= {'nurbs_order':3}) - Line.NURBS(Line, 10, '12 13 14', control_points= [[0, 10, 0], [5, 10, -2.5], [10, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 11, '9 15 12', control_points= [[0, 0, 0], [0, 5, -2.5], [0, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 12, '11 16 14', control_points= [[10, 0, 0], [10, 5, -2.5], [10, 5, -2.5]], weights= [1, 1, 1], params= {'nurbs_order':3}) + # NURBS-Curve Definition + Line.NURBS(9, '9 10 11') + Line.NURBS(10, '12 13 14') + Line.NURBS(11, '9 15 12') + Line.NURBS(12, '11 16 14') # Surfaces Definition - Surface.Rigid(Surface, 3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') + Surface.Rigid(3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') # Standard Quadrangle @@ -68,13 +68,13 @@ def test_rigid_surface(): Node(20, 10, 20, 0) # Boundary Lines - Line.Arc(1, 13, [17, 18], [5, 15, -2]) - Line.Arc(1, 14, [19, 20], [5, 20, -2]) + Line.Arc(13, [17, 18], [5, 15, -2]) + Line.Arc(14, [19, 20], [5, 20, -2]) Line(15, '17 19') Line(16, '18 20') # Quadrangle Defintion - Surface.Rigid(Surface, 4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') + Surface.Rigid(4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_SolidLoads.py b/UnitTests/test_SolidLoads.py index c54e3e56..745f493c 100644 --- a/UnitTests/test_SolidLoads.py +++ b/UnitTests/test_SolidLoads.py @@ -79,19 +79,19 @@ def test_solid_loads(): NodalLoad(1, 1, '1', LoadDirectionType.LOAD_DIRECTION_LOCAL_X, 12.8) SolidLoad(1, 1, '1', SolidLoadType.LOAD_TYPE_FORCE, SolidLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, SolidLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, 1289.0, 'My Comment') - SolidLoad.Force(SolidLoad, 2, 1, '1', SolidLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, 8569.21, 'My 2nd Comment') - SolidLoad.Force(SolidLoad, 3, 1, '1', SolidLoadDirection.LOAD_DIRECTION_GLOBAL_X_OR_USER_DEFINED_U_TRUE, 78548.21, 'My 2nd Comment') - SolidLoad.Temperature(SolidLoad, 4, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_UNIFORM,[78.4]) - SolidLoad.Temperature(SolidLoad, 5, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, [105.4, 507.8, 4, 3]) - SolidLoad.Temperature(SolidLoad, 6, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Y, [237, -8.9, 5, 7]) - SolidLoad.Temperature(SolidLoad, 7, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Z, [-2587.98, -8.9, 5, 2]) + SolidLoad.Force(2, 1, '1', SolidLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, 8569.21, 'My 2nd Comment') + SolidLoad.Force(3, 1, '1', SolidLoadDirection.LOAD_DIRECTION_GLOBAL_X_OR_USER_DEFINED_U_TRUE, 78548.21, 'My 2nd Comment') + SolidLoad.Temperature(4, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_UNIFORM,[78.4]) + SolidLoad.Temperature(5, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, [105.4, 507.8, 4, 3]) + SolidLoad.Temperature(6, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Y, [237, -8.9, 5, 7]) + SolidLoad.Temperature(7, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Z, [-2587.98, -8.9, 5, 2]) - SolidLoad.Strain(SolidLoad, 8, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, [0.01, 0.02, 0.03]) - SolidLoad.Strain(SolidLoad, 9, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, [0.01, 0.02, 0.03, 0.04, 0.05, 0.06, 5, 6]) - SolidLoad.Strain(SolidLoad, 10, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Y, [0.01, 0.02, 0.03, 0.04, 0.05, 0.06, 5, 8]) - SolidLoad.Strain(SolidLoad, 11, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Z, [0.01, 0.02, 0.03, 0.04, 0.05, 0.06, 5, 1]) + SolidLoad.Strain(8, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, [0.01, 0.02, 0.03]) + SolidLoad.Strain(9, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, [0.01, 0.02, 0.03, 0.04, 0.05, 0.06, 5, 6]) + SolidLoad.Strain(10, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Y, [0.01, 0.02, 0.03, 0.04, 0.05, 0.06, 5, 8]) + SolidLoad.Strain(11, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Z, [0.01, 0.02, 0.03, 0.04, 0.05, 0.06, 5, 1]) - SolidLoad.Motion(SolidLoad, 12, 1, '1',[ 5, 2, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0]) + SolidLoad.Motion(12, 1, '1',[ 5, 2, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0]) # Solid 2 Node(9, 0.0, 20.0, 0.0) @@ -152,15 +152,15 @@ def test_solid_loads(): Solid(3, '13-17,12', 1) # Solid Set - SolidSet.ContinuousSolids(SolidSet, 1, '2 3') + SolidSet.ContinuousSolids(1, '2 3') SolidSetLoad(1, 1, '1', SolidSetLoadType.LOAD_TYPE_FORCE, SolidSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, SolidSetLoadDirection.LOAD_DIRECTION_GLOBAL_Y_OR_USER_DEFINED_V_TRUE, 58.9*1000, 'My Comment') - SolidSetLoad.Force(SolidSetLoad, 2, 1, '1', SolidLoadDirection.LOAD_DIRECTION_GLOBAL_Y_OR_USER_DEFINED_V_TRUE, 8974.123, 'My 2nd Comment') - SolidSetLoad.Temperature(SolidSetLoad, 3, 1, '1', SolidSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, [25489], 'My 3rd Comment') - SolidSetLoad.Temperature(SolidSetLoad, 4, 1, '1', SolidSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, [1.5, 8.9, 16, 15], 'My 3rd Comment') - SolidSetLoad.Strain(SolidSetLoad, 5, 1, '1', SolidSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, [0.1, 0.2, 0.3], 'My Comment') - SolidSetLoad.Strain(SolidSetLoad, 6, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Y, [0.1, 0.2, 0.3, 0.1, 0.2, 0.3, 13, 16]) - SolidSetLoad.Motion(SolidSetLoad, 7, 1, '1', [1.5, 0.2, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0]) + SolidSetLoad.Force(2, 1, '1', SolidLoadDirection.LOAD_DIRECTION_GLOBAL_Y_OR_USER_DEFINED_V_TRUE, 8974.123, 'My 2nd Comment') + SolidSetLoad.Temperature(3, 1, '1', SolidSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, [25489], 'My 3rd Comment') + SolidSetLoad.Temperature(4, 1, '1', SolidSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, [1.5, 8.9, 16, 15], 'My 3rd Comment') + SolidSetLoad.Strain(5, 1, '1', SolidSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, [0.1, 0.2, 0.3], 'My Comment') + SolidSetLoad.Strain(6, 1, '1', SolidLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_Y, [0.1, 0.2, 0.3, 0.1, 0.2, 0.3, 13, 16]) + SolidSetLoad.Motion(7, 1, '1', [1.5, 0.2, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0]) #Calculate_all() # Don't use in unit tests. See template for more info. diff --git a/UnitTests/test_StandardSurface_Test.py b/UnitTests/test_StandardSurface_Test.py index 1334577a..c974bda9 100644 --- a/UnitTests/test_StandardSurface_Test.py +++ b/UnitTests/test_StandardSurface_Test.py @@ -36,11 +36,11 @@ def test_standard_surface(): # Standard planar Surface Node(5, 0, -15, 0), Node(6, 10, -15, 0), Node(7, 10, -5, 0), Node(8, 0, -5, 0) Line(5, '5 6'), Line(6, '6 7'), Line(7, '7 8'), Line(8, '8 5') - Surface.Standard(Surface, 2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') + Surface.Standard(2, SurfaceGeometry.GEOMETRY_PLANE, boundary_lines_no= '5 6 7 8') # Standard NURBS Surface - ## Define Nodes + # Define Nodes Node(9, 0.0, 0.0, 0.0) Node(10, 5.0, 0.0, -2.5) Node(11, 10.0, 0.0, 0.0) @@ -50,14 +50,14 @@ def test_standard_surface(): Node(15, 0.0, 5.0, -2,5) Node(16, 10.0, 5.0, -2.5) - ## NURBS-Curve Definition - Line.NURBS(Line, 9, '9 10 11', control_points= [[0, 0, 0], [5, 0, -2.5], [10, 0, 0]], weights= [1, 1, 1],params= {'nurbs_order':3}) - Line.NURBS(Line, 10, '12 13 14', control_points= [[0, 10, 0], [5, 10, -2.5], [10, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 11, '9 15 12', control_points= [[0, 0, 0], [0, 5, -2.5], [0, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 12, '11 16 14', control_points= [[10, 0, 0], [10, 5, -2.5], [10, 5, -2.5]], weights= [1, 1, 1], params= {'nurbs_order':3}) + # NURBS-Curve Definition + Line.NURBS(9, '9 10 11') + Line.NURBS(10, '12 13 14') + Line.NURBS(11, '9 15 12') + Line.NURBS(12, '11 16 14') # Surfaces Definition - Surface.Standard(Surface, 3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') + Surface.Standard(3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') # Standard Quadrangle @@ -68,12 +68,12 @@ def test_standard_surface(): Node(20, 10, 20, 0) # Boundary Lines - Line.Arc(1, 13, [17, 18], [5, 15, -2]) - Line.Arc(1, 14, [19, 20], [5, 20, -2]) + Line.Arc(13, [17, 18], [5, 15, -2]) + Line.Arc(14, [19, 20], [5, 20, -2]) Line(15, '17 19') Line(16, '18 20') # Quadrangle Defintion - Surface.Standard(Surface, 4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') + Surface.Standard(4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_SurfaceLoad_test.py b/UnitTests/test_SurfaceLoad_test.py index 0eccef45..45f6ee54 100644 --- a/UnitTests/test_SurfaceLoad_test.py +++ b/UnitTests/test_SurfaceLoad_test.py @@ -62,44 +62,44 @@ def test_surface_loads(): SurfaceLoad(1, 1, '1', 5000) ## Force Type Surface Load with UNIFORM Load Distribution ## - SurfaceLoad.Force(0, 2, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[5000]) + SurfaceLoad.Force(2, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[5000]) ## Force Type Surface Load with LINEAR Load Distribution ## - SurfaceLoad.Force(0, 3, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[5000, 6000, 7000, 2, 3, 4]) + SurfaceLoad.Force(3, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[5000, 6000, 7000, 2, 3, 4]) ## Force Type Surface Load with LINEAR_X or LINEAR_Y or LINEAR_Z Load Distribution ## - SurfaceLoad.Force(0, 4, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[5000, 6000, 3, 4]) + SurfaceLoad.Force(4, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[5000, 6000, 3, 4]) ## Force Type Surface Load with RADIAL Load Distribution ## - SurfaceLoad.Force(0, 5, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_RADIAL, + SurfaceLoad.Force(5, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_RADIAL, (5000, 6000, 3, 4, SurfaceLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, [1,2,3], [4,5,6])) ## Temperature Type Surface Load with UNIFORM Load Distribution ## - SurfaceLoad.Temperature(0, 6, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[18, 2]) + SurfaceLoad.Temperature(6, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[18, 2]) ## Temperature Type Surface Load with LINEAR Load Distribution ## - SurfaceLoad.Temperature(0, 7, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[18, 2, 20, 4, 22, 6, 2, 3, 4]) + SurfaceLoad.Temperature(7, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[18, 2, 20, 4, 22, 6, 2, 3, 4]) ## Temperature Type Surface Load with LINEAR_X or LINEAR_Y or LINEAR_Z Load Distribution ## - SurfaceLoad.Temperature(0, 8, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[18, 2, 20, 4, 2, 3]) + SurfaceLoad.Temperature(8, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[18, 2, 20, 4, 2, 3]) ## Axial Strain Type Surface Load with UNIFORM Load Distribution ## - SurfaceLoad.AxialStrain(0, 9, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[0.5, 1]) + SurfaceLoad.AxialStrain(9, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[0.5, 1]) ## Axial Strain Type Surface Load with LINEAR Load Distribution ## - SurfaceLoad.AxialStrain(0, 10, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[0.005, 0.006, 0.007, 0.008, 0.009, 0.01, 2, 3, 4]) + SurfaceLoad.AxialStrain(10, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[0.005, 0.006, 0.007, 0.008, 0.009, 0.01, 2, 3, 4]) ## Axial Strain Type Surface Load with LINEAR_IN_X Load Distribution ## - SurfaceLoad.AxialStrain(0, 11, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[0.005, 0.006, 0.007, 0.008, 2, 3]) + SurfaceLoad.AxialStrain(11, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[0.005, 0.006, 0.007, 0.008, 2, 3]) ## Precamber Type Surface Load ## - SurfaceLoad.Precamber(0, 12, 1, '1', 50) + SurfaceLoad.Precamber(12, 1, '1', 50) ## Rotary Motion Surface Load ## - SurfaceLoad.RotaryMotion(0, 13, 1, '1', load_parameter=[1, 2, SurfaceLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, [1,2,3], [4,5,6]]) + SurfaceLoad.RotaryMotion(13, 1, '1', load_parameter=[1, 2, SurfaceLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, [1,2,3], [4,5,6]]) ## Mass Type Surface Load ## - SurfaceLoad.Mass(0, 14, 1, '1', individual_mass_components=True, mass_parameter=[500, 600, 700]) + SurfaceLoad.Mass(14, 1, '1', individual_mass_components=True, mass_parameter=[500, 600, 700]) #Calculate_all() # Don't use in unit tests. See template for more info. diff --git a/UnitTests/test_SurfaceSetLoad_test.py b/UnitTests/test_SurfaceSetLoad_test.py index ffd237da..d6091383 100644 --- a/UnitTests/test_SurfaceSetLoad_test.py +++ b/UnitTests/test_SurfaceSetLoad_test.py @@ -75,8 +75,8 @@ def test_surface_set_load(): # Added types and functions just to cover SurfaceSet completely SurfaceSet(1, '1 2', SetType.SET_TYPE_GROUP) SurfaceSet(2, '3 4', SetType.SET_TYPE_GROUP) - SurfaceSet.ContinuousSurfaces(SurfaceSet, 3, '3 4') - SurfaceSet.GroupOfSurfaces(SurfaceSet, 4, '1 2') + SurfaceSet.ContinuousSurfaces(3, '3 4') + SurfaceSet.GroupOfSurfaces(4, '1 2') # Create Nodal Supports NodalSupport(1, '1', NodalSupportType.FIXED) @@ -102,47 +102,47 @@ def test_surface_set_load(): SurfaceSetLoad(1, 1, '1', 5000) ## Force Type Surface Load with UNIFORM Load Distribution ## - SurfaceSetLoad.Force(0, 2, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[5000]) + SurfaceSetLoad.Force(2, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[5000]) ## Force Type Surface Load with LINEAR Load Distribution ## - SurfaceSetLoad.Force(0, 3, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[5000, 6000, 7000, 2, 3, 4]) + SurfaceSetLoad.Force(3, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[5000, 6000, 7000, 2, 3, 4]) ## Force Type Surface Load with LINEAR_X or LINEAR_Y or LINEAR_Z Load Distribution ## - SurfaceSetLoad.Force(0, 4, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[5000, 6000, 2, 6]) + SurfaceSetLoad.Force(4, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[5000, 6000, 2, 6]) ## Force sType Surface Load with RADIAL Load Distribution ## - SurfaceSetLoad.Force(0, 5, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_RADIAL,(2000, 4000, 1, 6, SurfaceSetLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, [0,0,0], [0,0,1])) + SurfaceSetLoad.Force(5, 1, '1', SurfaceSetLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_RADIAL,(2000, 4000, 1, 6, SurfaceSetLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, [0,0,0], [0,0,1])) ## Force Type Surface Set Load with varying in Z - SurfaceSetLoad.Force(0, 32, 1, '2', SurfaceSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, load_parameter=[[1, 1, 1000], [2, 1, 2000]]) + SurfaceSetLoad.Force(32, 1, '2', SurfaceSetLoadDirection.LOAD_DIRECTION_LOCAL_Z, SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_VARYING_IN_Z, load_parameter=[[1, 1, 1000], [2, 1, 2000]]) ## Temperature Type Surface Load with UNIFORM Load Distribution ## - SurfaceSetLoad.Temperature(0, 6, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[18, 2]) + SurfaceSetLoad.Temperature(6, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[18, 2]) ## Temperature Type Surface Load with LINEAR Load Distribution ## - SurfaceSetLoad.Temperature(0, 7, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[18, 2, 20, 4, 22, 6, 2, 3, 4]) + SurfaceSetLoad.Temperature(7, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[18, 2, 20, 4, 22, 6, 2, 3, 4]) ## Temperature Type Surface Load with LINEAR_X or LINEAR_Y or LINEAR_Z Load Distribution ## - SurfaceSetLoad.Temperature(0, 8, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[18, 2, 20, 4, 2, 3]) + SurfaceSetLoad.Temperature(8, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[18, 2, 20, 4, 2, 3]) ## Axial Strain Type Surface Load with UNIFORM Load Distribution ## - SurfaceSetLoad.AxialStrain(0, 9, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[0.5, 1]) + SurfaceSetLoad.AxialStrain(9, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[0.5, 1]) ## Axial Strain Type Surface Load with LINEAR Load Distribution ## - SurfaceSetLoad.AxialStrain(0, 10, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[0.005, 0.006, 0.007, 0.008, 0.009, 0.01, 2, 3, 4]) + SurfaceSetLoad.AxialStrain(10, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR, load_parameter=[0.005, 0.006, 0.007, 0.008, 0.009, 0.01, 2, 3, 4]) ## Axial Strain Type Surface Load with LINEAR_IN_X Load Distribution ## - SurfaceSetLoad.AxialStrain(0, 11, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[0.005, 0.006, 0.007, 0.008, 2, 3]) + SurfaceSetLoad.AxialStrain(11, 1, '1', SurfaceSetLoadDistribution.LOAD_DISTRIBUTION_LINEAR_IN_X, load_parameter=[0.005, 0.006, 0.007, 0.008, 2, 3]) ## Precamber Type Surface Load ## - SurfaceSetLoad.Precamber(0, 12, 1, '1', 50) + SurfaceSetLoad.Precamber(12, 1, '1', 50) ## Rotary Motion Surface Load ## - SurfaceSetLoad.RotaryMotion(0, 13, 1, '1', load_parameter=[1, 2, SurfaceSetLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, [1,2,3], [4,5,6]]) + SurfaceSetLoad.RotaryMotion(13, 1, '1', load_parameter=[1, 2, SurfaceSetLoadAxisDefinitionType.AXIS_DEFINITION_TWO_POINTS, [1,2,3], [4,5,6]]) ## Mass Type Surface Load ## - # SurfaceSetLoad.Mass(0, 14, 1, '1', True, [500, 600, 700]) # bug 24241 - SurfaceSetLoad.Mass(0, 15, 1, '1', False, [0.5]) + SurfaceSetLoad.Mass(14, 1, '1', True, [500, 600, 700]) + SurfaceSetLoad.Mass(15, 1, '1', False, [0.5]) #Calculate_all() # Don't use in unit tests. See template for more info. diff --git a/UnitTests/test_Thickness_Test.py b/UnitTests/test_Thickness_Test.py index 44ad5e9b..4e4e2b47 100644 --- a/UnitTests/test_Thickness_Test.py +++ b/UnitTests/test_Thickness_Test.py @@ -6,7 +6,6 @@ ) sys.path.append(PROJECT_ROOT) -# Import der Bibliotheken from RFEM.enums import ThicknessDirection, ThicknessOrthotropyType from RFEM.enums import ThicknessShapeOrthotropySelfWeightDefinitionType, ThicknessStiffnessMatrixSelfWeightDefinitionType from RFEM.initModel import Model @@ -29,7 +28,7 @@ def test_thickness(): Thickness() # Constant - Thickness.Uniform(Thickness, + Thickness.Uniform( no= 2, name= 'Constant', properties= [0.2], @@ -39,7 +38,7 @@ def test_thickness(): Node(1, 5, 5, 0) Node(2, 5, 10, 0) Node(3, 10, 7.5, 0) - Thickness.Variable_3Nodes(Thickness, + Thickness.Variable_3Nodes( no= 3, name= 'Variable - 3 Nodes', properties= [0.1, 1, 0.25, 2, 0.45, 3], @@ -48,7 +47,7 @@ def test_thickness(): # Variable - 2 Nodes and Direction Node(4, 20, -10, 0) Node(5, 20, 0, -5) - Thickness.Variable_2NodesAndDirection(Thickness, + Thickness.Variable_2NodesAndDirection( no= 4, name= 'Variable - 2 Nodes and Direction', properties= [0.32, 4, 0.45, 5, ThicknessDirection.THICKNESS_DIRECTION_IN_Z], @@ -59,31 +58,29 @@ def test_thickness(): Node(7, 5, -25, 0) Node(8, 10, -25, 0) Node(9, 10, -20, 0) - Thickness.Variable_4SurfaceCorners(Thickness, + Thickness.Variable_4SurfaceCorners( no= 5, name= 'Variable - 4 Surface Corners', properties= [0.15, 6, 0.25, 7, 0.32, 8, 0.15, 9], comment= 'Comment') # Variable - Circle - Thickness.Variable_Circle(Thickness, + Thickness.Variable_Circle( no= 6, name= 'Variable - Circle', properties= [0.1, 0.5], comment= 'Comment') # Layers - """ skipped - Thickness.Layers(Thickness, + Thickness.Layers( no= 7, name= 'Layers', layers= [[1, 1, 0.123, 0, 'Schicht 1'], - [0, 1, 0.456, 90, 'Schicht 2']], + [0, 1, 0.456, 90, 'Schicht 2']], comment= 'Comment') - """ # Shape Orthotropy - Thickness.ShapeOrthotropy(Thickness, + Thickness.ShapeOrthotropy( no= 8, name= 'Shape Orthotropy', orthotropy_type= ThicknessOrthotropyType.HOLLOW_CORE_SLAB, @@ -93,7 +90,7 @@ def test_thickness(): comment= 'Comment') # Stiffness Matrix - Thickness.StiffnessMatrix(Thickness, + Thickness.StiffnessMatrix( no= 9, name= 'Stiffness Matrix', rotation_beta= 90, diff --git a/UnitTests/test_WithoutThicknessSurface_Test.py b/UnitTests/test_WithoutThicknessSurface_Test.py index c1338b13..af148382 100644 --- a/UnitTests/test_WithoutThicknessSurface_Test.py +++ b/UnitTests/test_WithoutThicknessSurface_Test.py @@ -36,11 +36,11 @@ def test_without_thickness_surface(): # Standard planar Surface Node(5, 0, -15, 0), Node(6, 10, -15, 0), Node(7, 10, -5, 0), Node(8, 0, -5, 0) Line(5, '5 6'), Line(6, '6 7'), Line(7, '7 8'), Line(8, '8 5') - Surface.WithoutThickness(Surface, 2, boundary_lines_no= '5 6 7 8') + Surface.WithoutThickness(2, boundary_lines_no= '5 6 7 8') # Standard NURBS Surface - ## Define Nodes + # Define Nodes Node(9, 0.0, 0.0, 0.0) Node(10, 5.0, 0.0, -2.5) Node(11, 10.0, 0.0, 0.0) @@ -50,14 +50,14 @@ def test_without_thickness_surface(): Node(15, 0.0, 5.0, -2,5) Node(16, 10.0, 5.0, -2.5) - ## NURBS-Curve Definition - Line.NURBS(Line, 9, '9 10 11', control_points= [[0, 0, 0], [5, 0, -2.5], [10, 0, 0]], weights= [1, 1, 1],params= {'nurbs_order':3}) - Line.NURBS(Line, 10, '12 13 14', control_points= [[0, 10, 0], [5, 10, -2.5], [10, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 11, '9 15 12', control_points= [[0, 0, 0], [0, 5, -2.5], [0, 10, 0]], weights= [1, 1, 1], params= {'nurbs_order':3}) - Line.NURBS(Line, 12, '11 16 14', control_points= [[10, 0, 0], [10, 5, -2.5], [10, 5, -2.5]], weights= [1, 1, 1], params= {'nurbs_order':3}) + # NURBS-Curve Definition + Line.NURBS(9, '9 10 11') + Line.NURBS(10, '12 13 14') + Line.NURBS(11, '9 15 12') + Line.NURBS(12, '11 16 14') # Surfaces Definition - Surface.WithoutThickness(Surface, 3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') + Surface.WithoutThickness(3, SurfaceGeometry.GEOMETRY_NURBS, [3,3,3,3], '9 10 11 12') # Standard Quadrangle @@ -68,12 +68,12 @@ def test_without_thickness_surface(): Node(20, 10, 20, 0) # Boundary Lines - Line.Arc(1, 13, [17, 18], [5, 15, -2]) - Line.Arc(1, 14, [19, 20], [5, 20, -2]) + Line.Arc(13, [17, 18], [5, 15, -2]) + Line.Arc(14, [19, 20], [5, 20, -2]) Line(15, '17 19') Line(16, '18 20') # Quadrangle Defintion - Surface.WithoutThickness(Surface, 4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') + Surface.WithoutThickness(4, SurfaceGeometry.GEOMETRY_QUADRANGLE, [17, 18, 19, 20], '13 14 15 16') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_basic_objects.py b/UnitTests/test_basic_objects.py index 7bd223a0..5e312aaf 100644 --- a/UnitTests/test_basic_objects.py +++ b/UnitTests/test_basic_objects.py @@ -5,7 +5,6 @@ os.pardir) ) sys.path.append(PROJECT_ROOT) -import pytest from RFEM.enums import * from RFEM.initModel import Model, SetAddonStatus from RFEM.BasicObjects.material import Material @@ -47,7 +46,7 @@ def test_line_polyline(): Node(1, 0, 0, 0) Node(2, 5, 0, 0) - Line.Polyline(0, 1, '1 2') + Line.Polyline(1, '1 2') Model.clientModel.service.finish_modification() @@ -64,7 +63,7 @@ def test_line_arc(): Node(1, 2, 0, 0) Node(2, 4, 0, 0) - Line.Arc(0, 1, [1, 2], [3, 3, 0], LineArcAlphaAdjustmentTarget.ALPHA_ADJUSTMENT_TARGET_BEGINNING_OF_ARC) + Line.Arc(1, [1, 2], [3, 3, 0], LineArcAlphaAdjustmentTarget.ALPHA_ADJUSTMENT_TARGET_BEGINNING_OF_ARC) Model.clientModel.service.finish_modification() @@ -78,7 +77,7 @@ def test_line_circle(): Model.clientModel.service.delete_all() Model.clientModel.service.begin_modification() - Line.Circle(0, 1, [5, 6, 7], 3, [0, 0, 1]) + Line.Circle(1, [5, 6, 7], 3, [0, 0, 1]) Model.clientModel.service.finish_modification() @@ -97,7 +96,7 @@ def test_line_ellipse(): Node(1,2,0,0) Node(2,-2,0,0) - Line.Ellipse(0, 2,[1,2],[0,1,0]) + Line.Ellipse(2,[1,2],[0,1,0]) Model.clientModel.service.finish_modification() @@ -112,7 +111,7 @@ def test_line_parabola(): Node(1,2,0,0) Node(2,-2,0,0) - Line.Parabola(0, 3,[1,2],[0,1,0],0.17453) + Line.Parabola(3,[1,2],[0,1,0],0.17453) Model.clientModel.service.finish_modification() @@ -130,7 +129,7 @@ def test_line_spline(): Node(3,0,-1,0) Node(4,-1,1,0) Node(5,-2,0,0) - Line.Spline(0, 1, "1-5") + Line.Spline(1, "1-5") Model.clientModel.service.finish_modification() @@ -143,8 +142,8 @@ def test_line_elipticalArc(): Model.clientModel.service.delete_all() Model.clientModel.service.begin_modification() - Line.EllipticalArc(Line, 1) - Line.EllipticalArc(Line, 2, [2,0,0], [-2,0,0], [0,-3,0], 0.17453, 2.79252) + Line.EllipticalArc(1) + Line.EllipticalArc(2, [2,0,0], [-2,0,0], [0,-3,0], 0.17453, 2.79252) Model.clientModel.service.finish_modification() @@ -183,7 +182,7 @@ def test_lineSetContinuous(): Line(1, '1 2') Line(2, '2 3') - LineSet.ContinuousLines(0, 1, '1 2') + LineSet.ContinuousLines(1, '1 2') Model.clientModel.service.finish_modification() @@ -203,7 +202,7 @@ def test_lineSetGroup(): Line(1, '1 2') Line(2, '2 3') - LineSet.GroupOfLines(0, 2, '1 2') + LineSet.GroupOfLines(2, '1 2') Model.clientModel.service.finish_modification() @@ -367,7 +366,7 @@ def test_thickness_uniform(): Material(1, 'S235') - Thickness.Uniform(0, 1, '1', 1, [0.03]) + Thickness.Uniform(1, '1', 1, [0.03]) Model.clientModel.service.finish_modification() @@ -387,7 +386,7 @@ def test_thickness_3nodes(): Node(2, 2, 2, 0) Node(3, 3, 4, 0) - Thickness.Variable_3Nodes(0, 1, '2', 1, [0.2, 1, 0.1, 2, 0.05, 3]) + Thickness.Variable_3Nodes(1, '2', 1, [0.2, 1, 0.1, 2, 0.05, 3]) Model.clientModel.service.finish_modification() @@ -406,7 +405,7 @@ def test_thickness_2nodes(): Node(1, 4, 0, 0) Node(2, 2, 2, 0) - Thickness.Variable_2NodesAndDirection(0, 1, '3', 1, [0.2, 1, 0.1, 2, ThicknessDirection.THICKNESS_DIRECTION_IN_X]) + Thickness.Variable_2NodesAndDirection(1, '3', 1, [0.2, 1, 0.1, 2, ThicknessDirection.THICKNESS_DIRECTION_IN_X]) Model.clientModel.service.finish_modification() thickness = Model.clientModel.service.get_thickness(1) @@ -426,7 +425,7 @@ def test_thickness_4corners(): Node(3, 3, 3, 0) Node(4, 0, 3, 0) - Thickness.Variable_4SurfaceCorners(0, 1, '4', 1, [0.2, 1, 0.15, 2, 0.1, 3, 0.05, 4]) + Thickness.Variable_4SurfaceCorners(1, '4', 1, [0.2, 1, 0.15, 2, 0.1, 3, 0.05, 4]) Model.clientModel.service.finish_modification() @@ -442,7 +441,7 @@ def test_thickness_circle(): Material(1, 'S235') - Thickness.Variable_Circle(0, 1, '5', 1, [0.2, 0.1]) + Thickness.Variable_Circle(1, '5', 1, [0.2, 0.1]) Model.clientModel.service.finish_modification() @@ -460,7 +459,7 @@ def test_thickness_layers(): Material(1, 'S235') - Thickness.Layers(0, 1, '6', [[0, 1, 0.1, 0, ''], [0, 1, 0.2, 0, '']]) + Thickness.Layers(1, '6', [[0, 1, 0.1, 0, ''], [0, 1, 0.2, 0, '']]) Model.clientModel.service.finish_modification() thickness = Model.clientModel.service.get_thickness(1) @@ -475,12 +474,12 @@ def test_thickness_shape_orthotropy(): Material(1, 'S275') - Thickness.ShapeOrthotropy(0, 1, 'EFFECTIVE_THICKNESS', 1, ThicknessOrthotropyType.EFFECTIVE_THICKNESS, 7) - Thickness.ShapeOrthotropy(0, 2, 'COUPLING', 1, ThicknessOrthotropyType.COUPLING, 8, parameters=[0.15,0.18,0.16]) - Thickness.ShapeOrthotropy(0, 3, 'UNIDIRECTIONAL_RIBBED_PLATE', 1, ThicknessOrthotropyType.UNIDIRECTIONAL_RIBBED_PLATE, 9, parameters=[0.15, 0.15,0.18,0.16]) - Thickness.ShapeOrthotropy(0, 4, 'BIDIRECTIONAL_RIBBED_PLATE', 1, ThicknessOrthotropyType.BIDIRECTIONAL_RIBBED_PLATE, 10, parameters=[0.15, 0.3,0.25, 0.8,0.75,0.2,0.15]) - Thickness.ShapeOrthotropy(0, 5, 'TRAPEZOIDAL_SHEET', 1, ThicknessOrthotropyType.TRAPEZOIDAL_SHEET, 11, parameters=[0.15, 0.45,0.4,0.14,0.14]) - Thickness.ShapeOrthotropy(0, 6, 'HOLLOW_CORE_SLAB', 1, ThicknessOrthotropyType.HOLLOW_CORE_SLAB, 12, parameters=[0.2, 0.15, 0.1]) - Thickness.ShapeOrthotropy(0, 7, 'GRILLAGE', 1, ThicknessOrthotropyType.GRILLAGE, 13,[ThicknessShapeOrthotropySelfWeightDefinitionType.SELF_WEIGHT_DEFINED_VIA_FICTITIOUS_THICKNESS, 0.15], [0.15,0.8,0.75,0.2,0.15]) + Thickness.ShapeOrthotropy(1, 'EFFECTIVE_THICKNESS', 1, ThicknessOrthotropyType.EFFECTIVE_THICKNESS, 7) + Thickness.ShapeOrthotropy(2, 'COUPLING', 1, ThicknessOrthotropyType.COUPLING, 8, parameters=[0.15,0.18,0.16]) + Thickness.ShapeOrthotropy(3, 'UNIDIRECTIONAL_RIBBED_PLATE', 1, ThicknessOrthotropyType.UNIDIRECTIONAL_RIBBED_PLATE, 9, parameters=[0.15, 0.15,0.18,0.16]) + Thickness.ShapeOrthotropy(4, 'BIDIRECTIONAL_RIBBED_PLATE', 1, ThicknessOrthotropyType.BIDIRECTIONAL_RIBBED_PLATE, 10, parameters=[0.15, 0.3,0.25, 0.8,0.75,0.2,0.15]) + Thickness.ShapeOrthotropy(5, 'TRAPEZOIDAL_SHEET', 1, ThicknessOrthotropyType.TRAPEZOIDAL_SHEET, 11, parameters=[0.15, 0.45,0.4,0.14,0.14]) + Thickness.ShapeOrthotropy(6, 'HOLLOW_CORE_SLAB', 1, ThicknessOrthotropyType.HOLLOW_CORE_SLAB, 12, parameters=[0.2, 0.15, 0.1]) + Thickness.ShapeOrthotropy(7, 'GRILLAGE', 1, ThicknessOrthotropyType.GRILLAGE, 13,[ThicknessShapeOrthotropySelfWeightDefinitionType.SELF_WEIGHT_DEFINED_VIA_FICTITIOUS_THICKNESS, 0.15], [0.15,0.8,0.75,0.2,0.15]) Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_intersections.py b/UnitTests/test_intersections.py index 4f7fd19a..646feb9f 100644 --- a/UnitTests/test_intersections.py +++ b/UnitTests/test_intersections.py @@ -54,7 +54,7 @@ def test_intersections(): Surface(1, '1-4') Surface(2, '5-8') - Surface.Standard(Surface,3,SurfaceGeometry.GEOMETRY_PIPE, params={'pipe_radius':0.3, 'pipe_center_line':9}) + Surface.Standard(3,SurfaceGeometry.GEOMETRY_PIPE, params={'pipe_radius':0.3, 'pipe_center_line':9}) Instersection(1,1,2) Instersection(2,1,3) diff --git a/UnitTests/test_loadCombination.py b/UnitTests/test_loadCombination.py index bff5301e..ceb2f510 100644 --- a/UnitTests/test_loadCombination.py +++ b/UnitTests/test_loadCombination.py @@ -20,7 +20,7 @@ def test_loadCombination(): Model.clientModel.service.delete_all() Model.clientModel.service.begin_modification() - StaticAnalysisSettings.GeometricallyLinear(0, 1, "Linear") + StaticAnalysisSettings.GeometricallyLinear(1, "Linear") LoadCase(1, 'DEAD', [True, 0.0, 0.0, 1.0]) LoadCase(2, 'LIVE', [False]) diff --git a/UnitTests/test_loads.py b/UnitTests/test_loads.py index 0c633d66..d09f207d 100644 --- a/UnitTests/test_loads.py +++ b/UnitTests/test_loads.py @@ -58,7 +58,7 @@ def test_nodal_load_force(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - NodalLoad.Force(0, 1, 1, '1', LoadDirectionType.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W, 5000) + NodalLoad.Force(1, 1, '1', LoadDirectionType.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W, 5000) Model.clientModel.service.finish_modification() nodal_load = Model.clientModel.service.get_nodal_load(1, 1) @@ -76,7 +76,7 @@ def test_nodal_load_moment(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - NodalLoad.Moment(0, 1, 1, '1', LoadDirectionType.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W, 5000) + NodalLoad.Moment(1, 1, '1', LoadDirectionType.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W, 5000) Model.clientModel.service.finish_modification() @@ -95,7 +95,7 @@ def test_nodal_load_components(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - NodalLoad.Components(0, 1, 1, '1', [5000, 0, 0, 0, 6000, 0]) + NodalLoad.Components(1, 1, '1', [5000, 0, 0, 0, 6000, 0]) Model.clientModel.service.finish_modification() @@ -114,7 +114,7 @@ def test_nodal_load_mass(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - NodalLoad.Mass(0, 1, 1, '1', False,[5000]) + NodalLoad.Mass(1, 1, '1', False,[5000]) Model.clientModel.service.finish_modification() @@ -164,7 +164,7 @@ def test_member_load_force(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.Force(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [6000]) + MemberLoad.Force(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [6000]) Model.clientModel.service.finish_modification() @@ -188,7 +188,7 @@ def test_member_load_moment(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.Moment(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [3000]) + MemberLoad.Moment(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [3000]) Model.clientModel.service.finish_modification() @@ -212,7 +212,7 @@ def test_member_load_mass(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.Mass(0, 1, 1, '1', False, mass_components=[5000]) + MemberLoad.Mass(1, 1, '1', False, mass_components=[5000]) Model.clientModel.service.finish_modification() member_load = Model.clientModel.service.get_member_load(1, 1) @@ -235,7 +235,7 @@ def test_member_load_temperature(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.Temperature(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.497, 0.596]) + MemberLoad.Temperature(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.497, 0.596]) Model.clientModel.service.finish_modification() @@ -259,7 +259,7 @@ def test_member_load_temperature_change(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.TemperatureChange(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6]) + MemberLoad.TemperatureChange(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.5, 0.6]) Model.clientModel.service.finish_modification() @@ -283,7 +283,7 @@ def test_member_load_axial_strain(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.AxialStrain(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, [0.5]) + MemberLoad.AxialStrain(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, [0.5]) Model.clientModel.service.finish_modification() @@ -307,7 +307,7 @@ def test_member_load_axial_displacement(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.AxialDisplacement(0, 1, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) + MemberLoad.AxialDisplacement(1, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) Model.clientModel.service.finish_modification() @@ -331,7 +331,7 @@ def test_member_load_precamber(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.Precamber(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [5]) + MemberLoad.Precamber(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [5]) Model.clientModel.service.finish_modification() @@ -355,7 +355,7 @@ def test_member_load_initial_prestress(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.InitialPrestress(0, 1, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) + MemberLoad.InitialPrestress(1, 1, '1', MemberLoadDirection.LOAD_DIRECTION_LOCAL_X, 50) Model.clientModel.service.finish_modification() @@ -379,7 +379,7 @@ def test_member_load_displacement(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.Displacement(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [60]) + MemberLoad.Displacement(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [60]) Model.clientModel.service.finish_modification() @@ -403,7 +403,7 @@ def test_member_load_rotation(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.Rotation(0, 1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.6]) + MemberLoad.Rotation(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_LOCAL_Z, [0.6]) Model.clientModel.service.finish_modification() @@ -427,7 +427,7 @@ def test_member_load_pipecontentfull(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.PipeContentFull(0, 1, 1, '1', MemberLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, 50) + MemberLoad.PipeContentFull(1, 1, '1', MemberLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, 50) Model.clientModel.service.finish_modification() @@ -451,7 +451,7 @@ def test_member_load_pipecontentpartial(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.PipeContentPartial(0, 1, 1, '1', MemberLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, 50, 50) + MemberLoad.PipeContentPartial(1, 1, '1', MemberLoadDirectionOrientation.LOAD_DIRECTION_FORWARD, 50, 50) Model.clientModel.service.finish_modification() @@ -475,7 +475,7 @@ def test_member_load_pipeinternalpressure(): StaticAnalysisSettings(1, 'Linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) LoadCase(1, 'DEAD') - MemberLoad.PipeInternalPressure(0, 1, 1, '1', 50) + MemberLoad.PipeInternalPressure(1, 1, '1', 50) Model.clientModel.service.finish_modification() @@ -555,7 +555,7 @@ def test_surface_load_force(): LoadCase(1, 'DEAD') - SurfaceLoad.Force(0, 1, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[5000]) + SurfaceLoad.Force(1, 1, '1', SurfaceLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE, SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[5000]) Model.clientModel.service.finish_modification() @@ -594,7 +594,7 @@ def test_surface_load_temperature(): LoadCase(1, 'DEAD') - SurfaceLoad.Temperature(0, 1, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[18, 2]) + SurfaceLoad.Temperature(1, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[18, 2]) Model.clientModel.service.finish_modification() @@ -633,7 +633,7 @@ def test_surface_load_axial_strain(): LoadCase(1, 'DEAD') - SurfaceLoad.AxialStrain(0, 1, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[0.5, 1]) + SurfaceLoad.AxialStrain(1, 1, '1', SurfaceLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[0.5, 1]) Model.clientModel.service.finish_modification() @@ -672,7 +672,7 @@ def test_surface_load_precamber(): LoadCase(1, 'DEAD') - SurfaceLoad.Precamber(0, 1, 1, '1', 50) + SurfaceLoad.Precamber(1, 1, '1', 50) Model.clientModel.service.finish_modification() @@ -711,7 +711,7 @@ def test_surface_load_mass(): LoadCase(1, 'DEAD') - SurfaceLoad.Mass(0, 1, 1, '1', individual_mass_components=True, mass_parameter=[500, 600, 700]) + SurfaceLoad.Mass(1, 1, '1', individual_mass_components=True, mass_parameter=[500, 600, 700]) Model.clientModel.service.finish_modification() @@ -790,7 +790,7 @@ def test_line_load_force(): LoadCase(1, 'DEAD') - LineLoad.Force(LineLoad, 1, 1, '1', + LineLoad.Force(1, 1, '1', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[1000]) @@ -831,7 +831,7 @@ def test_line_load_moment(): LoadCase(1, 'DEAD') - LineLoad.Moment(LineLoad, 1, 1, '1', + LineLoad.Moment(1, 1, '1', load_distribution= LineLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, load_parameter=[2000]) @@ -872,7 +872,7 @@ def test_line_load_mass(): LoadCase(1, 'DEAD') - LineLoad.Mass(LineLoad, 1, 1, '1', + LineLoad.Mass(1, 1, '1', individual_mass_components= False, mass_components= [10]) @@ -916,7 +916,7 @@ def test_free_concentrated_load(): LoadCase(1, 'DEAD') - FreeLoad.ConcentratedLoad(FreeLoad, 1, 1, load_parameter= [5000, 4, 2]) + FreeLoad.ConcentratedLoad(1, 1, load_parameter= [5000, 4, 2]) Model.clientModel.service.finish_modification() @@ -956,7 +956,7 @@ def test_free_line_load(): LoadCase(1, 'DEAD') - FreeLoad.LineLoad(FreeLoad, 1, 1, '1', + FreeLoad.LineLoad(1, 1, '1', FreeLineLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeLineLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -1000,7 +1000,7 @@ def test_free_rectangular_load(): LoadCase(1, 'DEAD') - FreeLoad.RectangularLoad(FreeLoad, 1, 1, '1', + FreeLoad.RectangularLoad(1, 1, '1', FreeRectangularLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeRectangularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -1046,7 +1046,7 @@ def test_free_circular_load(): LoadCase(1, 'DEAD') - FreeLoad.CircularLoad(FreeLoad, 1, 1, '1', + FreeLoad.CircularLoad(1, 1, '1', FreeCircularLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreeCircularLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, @@ -1090,7 +1090,7 @@ def test_free_polygon_load(): LoadCase(1, 'DEAD') - FreeLoad.PolygonLoad(FreeLoad, 1, 1, '1', + FreeLoad.PolygonLoad(1, 1, '1', FreePolygonLoadLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, FreeLoadLoadProjection.LOAD_PROJECTION_XY_OR_UV, FreePolygonLoadLoadDirection.LOAD_DIRECTION_GLOBAL_Z_TRUE, diff --git a/UnitTests/test_member.py b/UnitTests/test_member.py index 037f9e39..5d677fe3 100644 --- a/UnitTests/test_member.py +++ b/UnitTests/test_member.py @@ -48,7 +48,7 @@ def test_member_beam(): Node(1, 0, 0, 0) Node(2, 5, 0, 0) - Member.Beam(0, 1, 1, 2, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1, 1) + Member.Beam(1, 1, 2, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1, 1) Model.clientModel.service.finish_modification() @@ -68,7 +68,7 @@ def test_member_rigid(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.Rigid(0, 1, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618]) + Member.Rigid(1, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618]) Model.clientModel.service.finish_modification() @@ -89,7 +89,7 @@ def test_member_rib(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.Rib(0, 5, 1, 2, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, 1, 1) + Member.Rib(5, 1, 2, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, 1, 1) Model.clientModel.service.finish_modification() @@ -110,7 +110,7 @@ def test_member_truss(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.Truss(0, 5, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.Truss(5, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -130,7 +130,7 @@ def test_member_trussOnlyN(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.TrussOnlyN(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.TrussOnlyN(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -150,7 +150,7 @@ def test_member_tension(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.Tension(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.Tension(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -170,7 +170,7 @@ def test_member_compression(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.Compression(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.Compression(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -190,7 +190,7 @@ def test_member_buckling(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.Buckling(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.Buckling(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -210,7 +210,7 @@ def test_member_cable(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.Cable(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.Cable(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -230,7 +230,7 @@ def test_member_resultBeam(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.ResultBeam(0, 1, 1, 2, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, + Member.ResultBeam(1, 1, 2, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, MemberResultBeamIntegration.INTEGRATE_WITHIN_CUBOID_GENERAL, [0.2618], 1, 1, [], [1,2,3,4]) @@ -253,7 +253,7 @@ def test_member_definableStiffness(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.DefinableStiffness(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.DefinableStiffness(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -273,7 +273,7 @@ def test_member_couplingRigidRigid(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.CouplingRigidRigid(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.CouplingRigidRigid(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -293,7 +293,7 @@ def test_member_couplingRigidHinge(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.CouplingRigidHinge(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.CouplingRigidHinge(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -313,7 +313,7 @@ def test_member_couplingHingeRigid(): Node(1, 0, 0, 0) Node(2, 3, 3, -3) - Member.CouplingHingeRigid(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.CouplingHingeRigid(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() @@ -333,7 +333,7 @@ def test_member_couplingHingeHinge(): Node(1, 0, 0, 0) Node(2, 3, 3, 3) - Member.CouplingHingeHinge(0, 4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) + Member.CouplingHingeHinge(4, 1, 2, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1) Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_member_set.py b/UnitTests/test_member_set.py index 595967a6..0daed33d 100644 --- a/UnitTests/test_member_set.py +++ b/UnitTests/test_member_set.py @@ -59,7 +59,7 @@ def test_member_set_continuous(): Member(1, 1, 2, 0, 1, 1) Member(2, 2, 3, 0, 1, 1) - MemberSet.ContinuousMembers(0, 1, '1 2') + MemberSet.ContinuousMembers(1, '1 2') Model.clientModel.service.finish_modification() @@ -85,7 +85,7 @@ def test_member_set_group(): Member(1, 1, 2, 0, 1, 1) Member(2, 2, 3, 0, 1, 1) - MemberSet.GroupOfmembers(0, 1, '1 2') + MemberSet.GroupOfmembers(1, '1 2') Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_modalAnalysis_test.py b/UnitTests/test_modalAnalysis_test.py index d2dababb..9410f826 100644 --- a/UnitTests/test_modalAnalysis_test.py +++ b/UnitTests/test_modalAnalysis_test.py @@ -53,7 +53,7 @@ def test_modal_analysis_settings(): ModalMassMatrixType.MASS_MATRIX_TYPE_DIAGONAL, 2, [False, False, False, False, True, True]) # Load Case Static - # LoadCase(1, 'DEAD', [True, 0, 0, 1]) + LoadCase(1, 'DEAD', [True, 0, 0, 1]) modalParams = { "analysis_type": AnalysisType.ANALYSIS_TYPE_MODAL.name, "modal_analysis_settings":1, diff --git a/UnitTests/test_node.py b/UnitTests/test_node.py index 6ac64bfa..623de046 100644 --- a/UnitTests/test_node.py +++ b/UnitTests/test_node.py @@ -24,17 +24,17 @@ def test_node(): Node(1, 0, 0, 0) Node(2, 5, 0, 0) - Node.Standard(0, 3, [5, 5, 0],NodeCoordinateSystemType.COORDINATE_SYSTEM_CARTESIAN) - Node.BetweenTwoNodes(0,4,2,3,NodeReferenceType.REFERENCE_TYPE_L, 1, [True, 0.60]) - Node.BetweenTwoPoints(0,5,0,0,0,6,0,0,NodeReferenceType.REFERENCE_TYPE_L, [True, 0.7], 1, 1) + Node.Standard(3, [5, 5, 0],NodeCoordinateSystemType.COORDINATE_SYSTEM_CARTESIAN) + Node.BetweenTwoNodes(4,2,3,NodeReferenceType.REFERENCE_TYPE_L, 1, [True, 0.60]) + Node.BetweenTwoPoints(5,0,0,0,6,0,0,NodeReferenceType.REFERENCE_TYPE_L, [True, 0.7], 1, 1) Line(1,'1 2') - Node.OnLine(0, 6, 1, NodeReferenceType.REFERENCE_TYPE_L, 1, [True, 0.50]) + Node.OnLine(6, 1, NodeReferenceType.REFERENCE_TYPE_L, 1, [True, 0.50]) Material(1, 'S235') Section(1, 'IPE 300', 1) Member(1, 1, 2, 0, 1, 1) - Node.OnMember(0, 7,1,NodeReferenceType.REFERENCE_TYPE_L) + Node.OnMember(7,1,NodeReferenceType.REFERENCE_TYPE_L) Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_objectInformation.py b/UnitTests/test_objectInformation.py index cca0bdf1..78849915 100644 --- a/UnitTests/test_objectInformation.py +++ b/UnitTests/test_objectInformation.py @@ -34,7 +34,8 @@ def test_centre_of_gravity(): x1, y1, z1, = 0, 0, 0 x2, y2, z2 = 4, 10, -6 - Node(1, x1, y1, z1), Node(2, x2, y2, z2) + Node(1, x1, y1, z1) + Node(2, x2, y2, z2) Material(1, 'S235') Section() Member(1, start_node_no= 1, end_node_no= 2) @@ -45,9 +46,9 @@ def test_centre_of_gravity(): CoG_Y = (y2 - y1) / 2 CoG_Z = (z2 - z1) / 2 - assert CoG_X == ObjectInformation.CentreOfGravity(ObjectInformation, coord= 'X') - assert CoG_Y == ObjectInformation.CentreOfGravity(ObjectInformation, coord= 'Y') - assert CoG_Z == ObjectInformation.CentreOfGravity(ObjectInformation, coord= 'Z') + assert CoG_X == ObjectInformation.CentreOfGravity(coord= 'X') + assert CoG_Y == ObjectInformation.CentreOfGravity(coord= 'Y') + assert CoG_Z == ObjectInformation.CentreOfGravity(coord= 'Z') def test_member_information(): @@ -56,7 +57,8 @@ def test_member_information(): x1, y1, z1, = 0, 0, 0 x2, y2, z2 = 4, 10, -6 - Node(1, x1, y1, z1), Node(2, x2, y2, z2) + Node(1, x1, y1, z1) + Node(2, x2, y2, z2) Material(1, 'S235') Section() Member(1, start_node_no= 1, end_node_no= 2) @@ -68,9 +70,9 @@ def test_member_information(): V = L * A M = (V * 7850) / 1000 - assert round(L,3) == ObjectInformation.MemberInformation(ObjectInformation, information= SelectedObjectInformation.LENGTH) - assert round(V,3) == ObjectInformation.MemberInformation(ObjectInformation, information= SelectedObjectInformation.VOLUME) - assert round(M,3) == ObjectInformation.MemberInformation(ObjectInformation, information= SelectedObjectInformation.MASS) + assert round(L,3) == ObjectInformation.MemberInformation(information=SelectedObjectInformation.LENGTH) + assert round(V,3) == ObjectInformation.MemberInformation(information=SelectedObjectInformation.VOLUME) + assert round(M,3) == ObjectInformation.MemberInformation(information=SelectedObjectInformation.MASS) def test_surface_information(): @@ -82,8 +84,14 @@ def test_surface_information(): x3, y3, z3 = 10, 15, 0 x4, y4, z4 = 0, 15, 0 - Node(1, x1, y1, z1), Node(2, x2, y2, z2), Node(3, x3, y3, z3), Node(4, x4, y4, z4) - Line(1, '1 2'), Line(2, '2 3'), Line(3, '3 4'), Line(4, '4 1') + Node(1, x1, y1, z1) + Node(2, x2, y2, z2) + Node(3, x3, y3, z3) + Node(4, x4, y4, z4) + Line(1, '1 2') + Line(2, '2 3') + Line(3, '3 4') + Line(4, '4 1') Material(2, name='C30/37') Thickness(material_no= 2) Surface() @@ -94,6 +102,6 @@ def test_surface_information(): V = A * 0.2 M = (V * 2500) / 1000 - assert round(A,3) == ObjectInformation.SurfaceInformation(ObjectInformation, information= SelectedObjectInformation.AREA) - assert round(V,3) == ObjectInformation.SurfaceInformation(ObjectInformation, information= SelectedObjectInformation.VOLUME) - assert round(M,3) == ObjectInformation.SurfaceInformation(ObjectInformation, information= SelectedObjectInformation.MASS) + assert round(A,3) == ObjectInformation.SurfaceInformation(information=SelectedObjectInformation.AREA) + assert round(V,3) == ObjectInformation.SurfaceInformation(information=SelectedObjectInformation.VOLUME) + assert round(M,3) == ObjectInformation.SurfaceInformation(information=SelectedObjectInformation.MASS) diff --git a/UnitTests/test_solids.py b/UnitTests/test_solids.py index 51831ae5..6314b28c 100644 --- a/UnitTests/test_solids.py +++ b/UnitTests/test_solids.py @@ -65,7 +65,7 @@ def test_solids_and_solid_sets(): Surface(5, '3 11 7 12', 1) Surface(6, '4 12 8 9', 1) - Solid.Soil(0, 1, '1-6', 2) + Solid.Soil(1, '1-6', 2) solid = Model.clientModel.service.get_solid(1) assert round(solid.volume, 1) == 500 @@ -105,7 +105,7 @@ def test_solids_and_solid_sets(): Surface(12, '14 22 18 23', 1) Material(3, 'S275') - Solid.Standard(0, 2, '7-12', 3) + Solid.Standard(2, '7-12', 3) solid = Model.clientModel.service.get_solid(2) assert round(solid.volume, 1) == 500 @@ -133,7 +133,7 @@ def test_solids_and_solid_sets(): Surface(17, '26 31 29 32', 1) SolidContact() - Solid.Contact(0, 3, '13-17,12', 1, params={'solid_contact': 1, + Solid.Contact(3, '13-17,12', 1, params={'solid_contact': 1, 'solid_contact_first_surface':12}) solid = Model.clientModel.service.get_solid(3) @@ -176,7 +176,7 @@ def test_solids_and_solid_sets(): Material(4, 'Krypton') SolidGas(1,params={'pressure':21000000, 'temperature':293.1}) - Solid.Gas(0, 4, '18-23', 4,params={'gas':1}) + Solid.Gas(4, '18-23', 4,params={'gas':1}) Model.clientModel.service.finish_modification() @@ -194,13 +194,13 @@ def test_solids_and_solid_sets(): solidSet.set_type == SetType.SET_TYPE_GROUP solidSet.solids == '2 3' - SolidSet.ContinuousSolids(SolidSet, 2, '2 3') + SolidSet.ContinuousSolids(2, '2 3') solidSet = Model.clientModel.service.get_solid_set(2) solidSet.set_type == SetType.SET_TYPE_CONTINUOUS solidSet.solids == '2 3' - SolidSet.GroupOfSolids(SolidSet, 3, '1 4') + SolidSet.GroupOfSolids(3, '1 4') solidSet = Model.clientModel.service.get_solid_set(3) solidSet.set_type == SetType.SET_TYPE_GROUP diff --git a/UnitTests/test_stabilitysettings.py b/UnitTests/test_stabilitysettings.py index da341397..5f460993 100644 --- a/UnitTests/test_stabilitysettings.py +++ b/UnitTests/test_stabilitysettings.py @@ -44,7 +44,7 @@ def test_stability_analysis_settings_eigenvalue_method(): Model.clientModel.service.begin_modification() SetAddonStatus(Model.clientModel, AddOn.structure_stability_active, True) - StabilityAnalysisSettings.EigenvalueMethod(StabilityAnalysisSettings, no= 1, + StabilityAnalysisSettings.EigenvalueMethod(no= 1, name= 'Eigenvalue Method Test', number_of_lowest_eigenvalues= 5, considered_favored_effect= False, @@ -79,7 +79,7 @@ def test_stability_analysis_settings_incrementaly_method_with_eigenvalue(): Model.clientModel.service.begin_modification() SetAddonStatus(Model.clientModel, AddOn.structure_stability_active, True) - StabilityAnalysisSettings.IncrementalyMethodWithEigenvalue(StabilityAnalysisSettings, no= 1, + StabilityAnalysisSettings.IncrementalyMethodWithEigenvalue(no= 1, name= 'Incrementaly Method with Eigenvalue Test', number_of_lowest_eigenvalues= 5, considered_favored_effect= True, @@ -125,7 +125,7 @@ def test_stability_analysis_settings_incrementaly_method_without_eigenvalue(): Model.clientModel.service.begin_modification() SetAddonStatus(Model.clientModel, AddOn.structure_stability_active, True) - StabilityAnalysisSettings.IncrementalyMethodWithoutEigenvalue(StabilityAnalysisSettings, no= 1, + StabilityAnalysisSettings.IncrementalyMethodWithoutEigenvalue(no= 1, name= 'Incrementaly Method with Eigenvalue Test', minimum_initial_strain= 0, local_torsional_rotations= 0.2, diff --git a/UnitTests/test_staticAnalysisSetting.py b/UnitTests/test_staticAnalysisSetting.py index 66aa7137..9b01db6e 100644 --- a/UnitTests/test_staticAnalysisSetting.py +++ b/UnitTests/test_staticAnalysisSetting.py @@ -20,22 +20,22 @@ def test_StaticAnalysisSettings(): # Set Static Analysis Settings StaticAnalysisSettings(1, 'Geometrisch-linear', StaticAnalysisType.GEOMETRICALLY_LINEAR) - StaticAnalysisSettings.GeometricallyLinear(0,2,'Geometric-linear',[True, 1.5, True],True,True, + StaticAnalysisSettings.GeometricallyLinear(2,'Geometric-linear',[True, 1.5, True],True,True, StaticAnalysisSettingsMethodOfEquationSystem.METHOD_OF_EQUATION_SYSTEM_ITERATIVE, StaticAnalysisSettingsPlateBendingTheory.PLATE_BENDING_THEORY_KIRCHHOFF,[True,0,0,2.0]) - StaticAnalysisSettings.LargeDeformation(0,3,standard_precision_and_tolerance_settings = [True, 0.02, 0.02, 2.0]) - StaticAnalysisSettings.SecondOrderPDelta(0,4) + StaticAnalysisSettings.LargeDeformation(3,standard_precision_and_tolerance_settings = [True, 0.02, 0.02, 2.0]) + StaticAnalysisSettings.SecondOrderPDelta(4) Model.clientModel.service.finish_modification() linear = Model.clientModel.service.get_static_analysis_settings(2) assert linear['modify_loading_by_multiplier_factor'] == True - # TODO: these assigments are not working - # assert linear['loading_multiplier_factor'] == 1.5 - # assert linear['divide_results_by_loading_factor'] == True + # TODO: bug 26685 + #assert linear['loading_multiplier_factor'] == 1.5 + #assert linear['divide_results_by_loading_factor'] == True largeDef= Model.clientModel.service.get_static_analysis_settings(3) assert largeDef['standard_precision_and_tolerance_settings_enabled'] == True - # TODO: these assigments are not working + # TODO: bug 26685 # assert largeDef['precision_of_convergence_criteria_for_nonlinear_calculation'] == 0.02 # assert largeDef['instability_detection_tolerance'] == 0.02 # assert largeDef['iterative_calculation_robustness'] == 2.0 diff --git a/UnitTests/test_steelEffectiveLengths.py b/UnitTests/test_steelEffectiveLengths.py index 62084c32..7716f1f9 100644 --- a/UnitTests/test_steelEffectiveLengths.py +++ b/UnitTests/test_steelEffectiveLengths.py @@ -7,7 +7,6 @@ ) sys.path.append(PROJECT_ROOT) -# Import der Bibliotheken from RFEM.enums import * from RFEM.initModel import Model, SetAddonStatus, CheckIfMethodOrTypeExists from RFEM.TypesForSteelDesign.steelEffectiveLengths import SteelEffectiveLengths diff --git a/UnitTests/test_typesForLines.py b/UnitTests/test_typesForLines.py index 5657d19a..ac277046 100644 --- a/UnitTests/test_typesForLines.py +++ b/UnitTests/test_typesForLines.py @@ -60,8 +60,8 @@ def test_typesForLines(): params = LineMeshRefinements.TypeSpecificParams LineMeshRefinements(1,'3', LineMeshRefinementsType.TYPE_LENGTH, 2, '', params) - LineMeshRefinements.TargetFELength(0, 2, '4', 0.05) - LineMeshRefinements.NumberFiniteElements(0,3,'5',15) - LineMeshRefinements.Gradually(0,4,'6',4) + LineMeshRefinements.TargetFELength(2, '4', 0.05) + LineMeshRefinements.NumberFiniteElements(3,'5',15) + LineMeshRefinements.Gradually(4,'6',4) Model.clientModel.service.finish_modification() diff --git a/UnitTests/test_zCalculate.py b/UnitTests/test_zCalculate.py index e0190e84..c68b0bd9 100644 --- a/UnitTests/test_zCalculate.py +++ b/UnitTests/test_zCalculate.py @@ -31,7 +31,7 @@ def test_mesh_settings(): solid['QualityCriteriaConfigForSolids']['quality_criterion_parallel_deviations_warning'] = 1.7 wind = dict(MeshSettings.WindSimulationMeshConfig) - mesh = MeshSettings(common, surf, solid, wind) + MeshSettings(common, surf, solid, wind) control_mesh = GetMeshSettings() assert control_mesh['general_target_length_of_fe'] == 0.4321 @@ -41,7 +41,7 @@ def test_mesh_settings(): assert control_mesh['SolidsMeshQualityConfig']['QualityCriteriaConfigForSolids']['quality_criterion_parallel_deviations_warning'] == 1.7 control_mesh['general_maximum_distance_between_node_and_line'] = 0.003 - mesh.set_mesh_settings(control_mesh) + MeshSettings.set_mesh_settings(control_mesh) control_mesh = GetMeshSettings() assert control_mesh['general_maximum_distance_between_node_and_line'] == 0.003 @@ -57,9 +57,12 @@ def test_optimization_settings(): OptimizationSettings(True, 11, OptimizeOnType.E_OPTIMIZE_ON_TYPE_MIN_COST, Optimizer.E_OPTIMIZER_TYPE_PERCENTS_OF_RANDOM_MUTATIONS, 0.3) - opt_sett = OptimizationSettings.get_optimization_settings(OptimizationSettings) - assert opt_sett.general_optimization_active == True + opt_sett = OptimizationSettings.get_optimization_settings() + assert opt_sett.general_optimization_active assert opt_sett.general_keep_best_number_model_mutations == 11 assert opt_sett.general_optimize_on == OptimizeOnType.E_OPTIMIZE_ON_TYPE_MIN_COST.name assert opt_sett.general_optimizer == Optimizer.E_OPTIMIZER_TYPE_PERCENTS_OF_RANDOM_MUTATIONS.name assert opt_sett.general_number_random_mutations == 0.3 + + opt_sett.general_keep_best_number_model_mutations = 15 + OptimizationSettings.set_optimization_settings(opt_sett) diff --git a/pylintrc b/pylintrc index 7e6968c0..4f17287b 100644 --- a/pylintrc +++ b/pylintrc @@ -52,7 +52,8 @@ confidence= # --enable=similarities". If you want to run only the classes checker, but have # no Warning level messages displayed, use"--disable=all --enable=classes # --disable=W" -disable=W0614, W0401, W0622, C0103, C0114, C0115, C0116, C0301, C0413, R0913, R0914, R0915, C0305, C0411, W0102, W0702, E0602, E0401 +disable=W0614, W0401, W0622, C0103, C0114, C0115, C0116, C0301, C0413, R0912, R0913, R0914, R0915, C0305, C0411, W0102, W0702, E0602, E0401, W1405 + [REPORTS]