Source: https://www.fresnel.fr/perso/marot/Documents/Enseignements/Automatismes/Automatismes_Transparents_Cours_L3_SPI.pdf