I was wondering if anyone out there have developed a code to generate a stochastic foam structure for numerical simulations and 3D printing purposes. I know I can use CT scan to reproduce the foam topology that I have, but I would like to try several configurations where I can change the relative density for example or the struct size if possible.