A methodology for modelling energy-related human behaviour: Application to window opening behaviour in residential buildings