Mr. Purewal You have said this on some different thread located here, but that thread is now closed.
"In which" is, of course, totally different. It doesn't have anything to do with purpose; it just refers to some situation in which something goes/happens in something else.
The teacher drew a diagram in which a circle was enclosed in a square.
Can we also safely conclude that after "in which" we will always have a clause, which means a Subject-Verb pair.