Linear pattern with varying path length

Hi,

I need to create a geometry with curved tubes of varying length (see picture). I'm sure there is a way to use any kind of pattern. I tried a linear pattern, but this does not vary the tube length rather than just copy the exact feature. Does anyone know how to use a "smart" pattern?

Bests,
MGG

SolidworksParts And Features