Simulate an Euler-Bernoulli Beam?

How would you (roughly) simulate an Euler-Bernoulli beam?

I’ve tried with multiple rigidbodies and spring joints between them, but can’t quite get the behavior of a beam. What it should really have is a torsional spring but all I can seem to mimic is translational springs. Is there anyway to do this?

It seams you will need to code it yourself with complex maths.