PyNite icon indicating copy to clipboard operation
PyNite copied to clipboard

Enforce Use of Section Properties

Open bjhowie opened this issue 1 year ago • 1 comments

Following on from the discussion here #202 and working towards a v1.0.0 release, this pull request enforces the use of section properties when defining Member3D elements. This simplifies the processes of creating Member3D objects, by effectively grouping parameters to be passed to the __init__ method. It also ensures consistency in the way that section properties are stored within the FEA model, which is critical as the package matures.

This pull request also alters the Member3D class logic slightly, so that the section and material properties are not extracted in the Member3D __init__ method, but instead accessed directly from the appropriate section or material instances during analysis. This enables simple alteration of section or material properties between analysis runs, with the confidence that any changes are propogated through to all members referencin gthe given section or material.

The same approach could be taken for Quad & Plate elements, but can be covered in a different pull request.

These changes will break most user's code.

bjhowie avatar Sep 24 '24 14:09 bjhowie

I am not sure where exactly, but it seems the docstrings got lost for the section and material classes regarding this pull request 🤔

KwentiN-ui avatar Oct 14 '24 20:10 KwentiN-ui

I am not sure where exactly, but it seems the docstrings got lost for the section and material classes regarding this pull request 🤔

I'm not sure if the Section or Material ever had docstrings to begin with. I added basic docstrings to both classes as part of this pull request.

bjhowie avatar Nov 06 '24 13:11 bjhowie

Great work @bjhowie! I merged this pull request. This is going to force some longtime users (including myself) to adapt, but I think it's the direction Pynite needs to move. A very useful pull request!

JWock82 avatar Nov 12 '24 03:11 JWock82