It took me a while to figure out how to do this stuff. I, eventually, have been able to forgive women at whom I was angry for their falling in love with and having sex with a friend. It is a lot of work, and I was a little late on it. I forgave them after we split up. So it is a very difficult problem.
Forgiveness is one of the big issues of human beings.
What you need to do to forgive another human being is to tell the truth about what you are experiencing until that comes and goes with regard to experiencing anger. You have to get resentful and get over it. That's what forgiveness is. If a woman has an affair it's in her partner's enlightened self interest to forgive her. The reason that forgiveness is important is because I forgive you for my benefit, not for yours.