Agent-based modelling of travel behaviour and flow