From synaptic plasticity to spatial maps and sequence learning