Answer:
When a friend is going through a difficult time and is feeling badly, you might sympathize with your friend. This means that you in some way share the grief with your friend, or express feelings of sorrow that your friend is in pain. In another context it can also mean that you are in agreement, fully or partially, with someone's position. In this context it can have little or nothing to do with feelings. For example, you may be having a discussion about politics and someone expresses some factual evidence supporting his/her position. Even though you might come to a completely different conclusion, you might say that you sympathize with that person regarding the factual evidence. Using the word this way, it can even have a bit of a cynical flavor, depending on your delivery.