I don't know if I understand the meaning of the different modes, but the idea is here