Modelling damage progression by a statistical energy-balance algorithm