Repentance is a Sadness accompanied by the idea of some deed we believe ourselves to have done from a free decision of the Mind. Exp.: We have shown the causes of these affects in P51 S, P53, P54, P55, and P55 S. On the free decision of the Mind, see IIP35 S.
But we ought also to note here that it is no wonder Sadness follows absolutely all those acts which from custom are called wrong, and Joy, those which are called right. For from what has been said above we easily understand that this depends chiefly on education. Parents —by blaming the former acts, and often scolding their children on account of them, and on the other hand, by recommending and praising the latter acts—have brought it about that emotions of Sadness were joined to the one kind of act, and those of Joy to the other.
Experience itself also confirms this. For not everyone has the same custom and Religion. On the contrary, what among some is holy, among others is unholy; and what among some is honorable, among others is dishonorable. Hence, according as each one has been educated, so he either repents of a deed or exults at being esteemed for it.