I am trying to model a simplified FSI problem.
I have simplified the problem to this:
A cantilevered beam is affected by a point load at the top. This point load is a known function of time, node displacement, and node velocity.
I would like to solve this as a transient problem.
I am a beginner in OpenSees. Is this possible to set up? Any hints on how to do it?
This is what I tried, and it does not work.
Code: Select all
...
ops.constraints('Plain')
ops.numberer('RCM')
ops.system('ProfileSPD')
ops.test('NormUnbalance', 1e-6, 400)
ops.algorithm('Newton')
ops.integrator('Newmark', 0.5, 0.25)
ops.analysis('Transient')
...
for step in range(n_steps):
# Trying to update the load
id_timeseries = 1
id_pattern = 1
t = ops.getTime()
f = slamming_force(t, ops.nodeVel(n,1), ops.nodeDisp(n,1))
ops.remove('pattern', id_pattern)
ops.remove('timeSeries', id_timeseries)
ops.timeSeries('Constant', id_timeseries)
ops.pattern('Plain', id_pattern, id_timeseries)
ops.load(n, *[f, 0.0, 0.0])
ops.analyze(1, 0.0005)
Perhaps I could define a material for a zero length element to model this? Can that be done in python?