Behavioural and physical model of synaptic devices