The mirror neuron system provides a biological explanation of social cognition by explaining how one individual could imitate the behaviour of another.
Mirror neurons encode activity of the other person, which helps us to act the same way.
When we see someone produce a facial expression, the mirror neurons that are responsible for producing the same facial expression activate as well.
This then activates feelingsassociated with that facial expression, which helps us feel the same emotion we observe others going through.
This allows us to understand the emotional cognitions behind the other person's expressions, as a result we show empathy towards them.