JWock82 / PyNite

A 3D structural engineering finite element library for Python.
MIT License
421 stars 86 forks source link

Spring Supports: reactions = 2x input forces #187

Closed flit-float-fly closed 3 months ago

flit-float-fly commented 3 months ago

Describe the bug I am trying to simulate a grade beam, so I have made a beam model that is supported by springs. I apply a simple UDL or Point load at the centre of the beam and the total sum of my reactions is 2x what my UDLxL or point load are. I have attached a screen shot of the statics check.

I double checked all of my inputs, and the best guess I have (apart from a bug) is that I initialized the spring supports incorrectly... but I can't see where.

To Reproduce Import the attached module (as".py") fdn_model_20240311_issue.txt

and call up a beam with this script: input_dict = {"mat": "conc", "L": 10000, "w": 1000, "E": 23000,
"A": 1e6, "Iz": 83333333333, "Iy": 83333333333, "nu": 0.3, "rho": 24e-6, "J": 10e6, "subgrade_modulus": 0.1, "n_springs": 10, "UDL": [1,1,0,10000], "pt_loads": [(0,5000)] } gb = fdn.grade_beam(**input_dict)

gb.analyze(check_statics=True) <- this should produce the screenshot attached.

Expected behavior I was expecting to have the sum of the reactions match my input forces.

Screenshots image

JWock82 commented 3 months ago

I've isolated the issue and have corrected it in the GitHub repo. I'll push this change out with version 0.0.93.

The program did not like having both a support and a spring at the same node. This helped me lock on to a bigger bug that was reporting phantom reactions at unsupported degrees of freedom that should not be showing any reactions. Thank you for reporting. That bug was a tricky one to find and only triggered under very rare circumstances.

flit-float-fly commented 3 months ago

Well this is great! This is my first time reporting anything, and I'm glad I could help; I'm also very glad you're so responsive. This is an impressive tool, and am looking forward to following its development.