Closed mhscott closed 1 year ago
@mhscott Could you please give an example where it does not work? For example, frame elements connected to zero length elements should give the deformation of frame elements based on corresponding nodal displacements/rotations. However the beam elements with joint moment releases do not work because there are one node and two rotations and the element response command does not provide this additional element rotational data. I will look into this issue in more detail, but for now please provide an example and I will fix it.
@sewkokot Sure! Here is a minimal example
import openseespy.opensees as ops
import opsvis as opsv
ops.wipe()
ops.model('basic','-ndm',3,'-ndf',6)
ops.node(1,0,0,0); ops.fix(1,1,1,1,1,1,1)
ops.node(2,0,0,0); ops.fix(2,0,1,1,1,1,1)
ops.uniaxialMaterial('Elastic',1,1.0)
ops.element('zeroLength',1,1,2,'-mat',1,'-dir',1)
ops.timeSeries('Linear',1)
ops.pattern('Plain',1,1)
ops.load(2,1.0,0,0,0,0,0)
ops.analysis('Static','-noWarnings')
ops.analyze(1)
print(ops.nodeDisp(2))
opsv.plot_defo()
Gives the following nodal displacement and displaced shape:
@mhscott Thank you for the report and MWE. Please update the package and let me know what do you think of the fix, and if it can be improved? You can use a scale factor 'sfac' optional parameter.
# opsv.plot_defo(sfac=0.5)
opsv.plot_defo()
@sewkokot Looks good, thanks!
@sewkokot It appears zero length elements are not included in the plot_defo() function. Is this correct? I can do a PR to add the functionality, or this may be something you plan for the next release? Let me know what you think!