Cognitive dissonance is a state characterized by a collision in the minds of a person of conflicting knowledge, beliefs, behavioral attitudes about a certain object or phenomenon. According to the theory of cognitive dissonance (Leon Festinger), such a state does not suit a person and gives rise to an unconscious desire to make the system of their knowledge and belief consistent and consistent.
For example, if I’m afraid of something, but do not see what - I have an internal dissonance. When I found or invented what I was right to fear, my soul calmed down. See →
Or, if to me like the clever person has told or said, that I the fool, and I consider myself like the clever person this contradiction. Eliminated in two ways - either to agree that in this situation I was a fool, or to think that the fool is the one who called me this. The second is usually more pleasant.
So, if you helped a person voluntarily or involuntarily, they helped, you will need to later explain to yourself why you did it. Well, not foolishly? The simplest explanation, which people almost unconsciously find their good deeds: "Because in this person there is something (kind)". And after that they treat a person with greater goodwill and sympathy. See →
Thinking about someone is bad and living away from him in the distance - internally logical. But to live next to a completely bad person is not logical, and people try not to live with such a person. However, if a joint life is inevitable and from this you can not get away at all, then maybe it’s not so bad, but just so special? See →
Cognitive dissonance and intrapersonal conflict
Cognitive dissonance is a mild version of an intrapersonal conflict. Look Intrapersonal Conflict.