What is the best way to express my condolence to a professor? I am a Ph.D student at the university. Every student has a favourite professor same as mine. I really care about and our student-teacher relationship growing stronger day by day. My professor really cares about my professional/academic growth.

But a few days sooner I heard that the professor has been gone for an extended period of time.I am very confused and don't have any idea how to contact my professor.

Mistakenly I used google and I realized that my professor loses his loved once.
I feel really ashamed to break my professor privacy. I know that express condolence is the best way to support your close one who is under deep pain.

I am more worried about to disrespect our teacher-student relationship.
I am really confused. Can anyone guide me any positive way to handle this situation?
If you found this information online then it’s hardly an invasion of privacy (unless of course you hacked his email or something). I wouldn’t worry about that. 

If there is a public announcement (an obituary) of a religious service (eg a wake or a shiv’a), you can probably attend as these things are usually open to the public for exactly people like you- distant relatives or acquaintances who wish to comfort the grieving family. For example, if they’re Jewish, it’s customary to bring some simple baked goods (say, cookies) since the family is hosting a seven-day event. I’m not familiar with grieving customs in other religions but that should be easy enough to find out. In these situations your professor would most likely greatly appreciate your presence and the gesture. 

If there’s no public announcement then wait for the professor to come back to the university and try to catch them in person to offer your condolences. Again, the gesture would be greatly appreciated I believe.

My condolences...