diff --git a/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-bars.bsc b/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-bars.bsc new file mode 100644 index 00000000..ba48373e --- /dev/null +++ b/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-bars.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-nodes.bsc b/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-nodes.bsc new file mode 100644 index 00000000..750fa6da --- /dev/null +++ b/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-nodes.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-surfaces.bsc b/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-surfaces.bsc new file mode 100644 index 00000000..2d318f96 --- /dev/null +++ b/FemDesign.Examples/Python/run-analysis/bsc/finite-elements-surfaces.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-concrete.bsc b/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-concrete.bsc new file mode 100644 index 00000000..b7fb4448 --- /dev/null +++ b/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-concrete.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-steel.bsc b/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-steel.bsc new file mode 100644 index 00000000..5fa10b6b --- /dev/null +++ b/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-steel.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-total.bsc b/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-total.bsc new file mode 100644 index 00000000..05924ff6 --- /dev/null +++ b/FemDesign.Examples/Python/run-analysis/bsc/quantity-estimation-total.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-analysis/run_analysis.py b/FemDesign.Examples/Python/run-analysis/run_analysis.py new file mode 100644 index 00000000..1bf3bcf9 --- /dev/null +++ b/FemDesign.Examples/Python/run-analysis/run_analysis.py @@ -0,0 +1,38 @@ +from femdesign.comunication import FemDesignConnection, Verbosity +from femdesign.calculate.command import DesignModule +from femdesign.calculate.analysis import Analysis, Design, CombSettings, CombItem + + +pipe = FemDesignConnection(fd_path= r"C:\Program Files\StruSoft\FEM-Design 23\fd3dstruct.exe", + minimized= False) +try: + pipe.SetVerbosity(Verbosity.SCRIPT_LOG_LINES) + pipe.Open(r"example/simple_beam.str") + pipe.SetProjectDescription(project_name="Amazing project", + project_description="Created through Python", + designer="Marco Pellegrino Engineer", + signature="MP", + comment="Wish for the best", + additional_info={"italy": "amazing", "sweden": "amazing_too"}) + + + + + combSettings = CombSettings() + combSettings.combitems.append(CombItem.StaticAnalysis(NLE=True)) + + static_analysis = Analysis.StaticAnalysis(combSettings) + pipe.RunAnalysis(static_analysis) + + pipe.RunAnalysis(Analysis.FrequencyAnalysis(num_shapes=5)) + pipe.RunDesign(DesignModule.STEELDESIGN, Design(False)) + + pipe.Save(r"example\to_delete\simple_beam_out_2.str") + pipe.GenerateListTables(bsc_file=r"example\bsc\finite-elements-nodes.bsc", + csv_file=r"example\output\finite-elements-nodes.csv") + pipe.GenerateListTables(bsc_file=r"example\bsc\quantity-estimation-steel.bsc", + csv_file=r"example\output\quantity-estimation-steel.csv") + pipe.Exit() +except Exception as err: + pipe.KillProgramIfExists() + raise err \ No newline at end of file diff --git a/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-bars.bsc b/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-bars.bsc new file mode 100644 index 00000000..ba48373e --- /dev/null +++ b/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-bars.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-nodes.bsc b/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-nodes.bsc new file mode 100644 index 00000000..750fa6da --- /dev/null +++ b/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-nodes.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-surfaces.bsc b/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-surfaces.bsc new file mode 100644 index 00000000..2d318f96 --- /dev/null +++ b/FemDesign.Examples/Python/run-fdscript/bsc/finite-elements-surfaces.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-concrete.bsc b/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-concrete.bsc new file mode 100644 index 00000000..b7fb4448 --- /dev/null +++ b/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-concrete.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-steel.bsc b/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-steel.bsc new file mode 100644 index 00000000..5fa10b6b --- /dev/null +++ b/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-steel.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-total.bsc b/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-total.bsc new file mode 100644 index 00000000..05924ff6 --- /dev/null +++ b/FemDesign.Examples/Python/run-fdscript/bsc/quantity-estimation-total.bsc @@ -0,0 +1,13 @@ + + + + FEM-Design Batch template + 2300 + sframe + batchtable.log + + + + + + diff --git a/FemDesign.Examples/Python/run-fdscript/run_fdscript.py b/FemDesign.Examples/Python/run-fdscript/run_fdscript.py new file mode 100644 index 00000000..65a71bc0 --- /dev/null +++ b/FemDesign.Examples/Python/run-fdscript/run_fdscript.py @@ -0,0 +1,33 @@ +from femdesign.comunication import FemDesignConnection, Verbosity +from femdesign.calculate.command import DesignModule, CmdOpen, CmdUser, CmdCalculation, CmdSave, CmdListGen, CmdProjDescr, User +from femdesign.calculate.analysis import Analysis, Design, CombSettings, CombItem +from femdesign.calculate.fdscript import Fdscript + +pipe = FemDesignConnection() +try: + log = r"example\x.log" + cmd_open = CmdOpen(r"simple_beam.str") + + cmd_resmode = CmdUser(User.RESMODE) + + comb = CombSettings() + comb.combitems.append( CombItem.StaticAnalysis() ) + analysis = Analysis.StaticAnalysis(comb) + cmd_analysis = CmdCalculation(analysis) + + design = Design(False) + freq_analysis = Analysis.FrequencyAnalysis() + cmd_freq = CmdCalculation(freq_analysis) + cmd_save = CmdSave(r"simple_beam_out.str") + cmd_list_gen = CmdListGen(r"bsc\nodal_displacement.bsc", + r"nodal_displacement.csv") + cmd_project = CmdProjDescr("Test project", "Test project description", "Test designer", "Test signature", + "Test comment", {"a": "a_txt", "b": "b_txt"}) + + + fdscript = Fdscript(log, [cmd_open, cmd_project, cmd_resmode, cmd_analysis, cmd_freq, cmd_list_gen, cmd_save]) + + pipe.RunScript(fdscript) +except Exception as err: + pipe.KillProgramIfExists() + raise err \ No newline at end of file diff --git a/FemDesign.Python/packaging/dist/fem_design-0.0.1-py3-none-any.whl b/FemDesign.Python/packaging/dist/fem_design-0.0.1-py3-none-any.whl deleted file mode 100644 index 72bbba9d..00000000 Binary files a/FemDesign.Python/packaging/dist/fem_design-0.0.1-py3-none-any.whl and /dev/null differ diff --git a/FemDesign.Python/packaging/dist/fem_design-0.0.1.tar.gz b/FemDesign.Python/packaging/dist/fem_design-0.0.1.tar.gz deleted file mode 100644 index 6abb55a9..00000000 Binary files a/FemDesign.Python/packaging/dist/fem_design-0.0.1.tar.gz and /dev/null differ