Thermo-chemical modelling of the formation of a composite material