Modelling of the structure of glasses