How, or in what way.
"The study examined wherein the participants showed significant improvement after three weeks of training."
Where, or in which location.
"The map shows the region wherein ancient civilizations first flourished."
Wherein comes from Middle English, formed by combining where and the preposition in. It has retained its original meaning of indicating a place or thing within which something happens.