fixed ecart() function
fixed display of length depending on punctual events or periods