One-dimensional maps with two discontinuity points and three linear branches: mathematical lessons for understanding the dynamics of financial markets