Polymer trace devolatilization: I. Foaming experiments and model development