Religiously, it's a punishment undergone in token of sorrow for sin
... sins 
themselves, which were not forgiven either as to guilt or punishment ... suffer for 
its sins, and can gain merit for this suffering, a soul in purgatory can ...