>>22644753Contact is based on whether or not your pokemon touches the opponent. Physical vs. Special is based on whether the pokemon uses its physical strength, or magical power/energy. So it makes sense that contact won't always align perfectly with physical, but I agree there are some questionable ones.
You could imagine stone edge as throwing rocks or making rocks appear by smashing (hence why fighting types often learn it). Power gem I think is magically making gems come out of a gem on your body.
Grass knot is clearly a "magical" technique. I guess the reason they made it contact is because they envisioned like Tangrowth using its body to do it, but yeah, it usually doesn't make sense.
>>22644772Earthquake is physically slamming the ground to make an earthquake. I suppose there's also a magical terraforming element to it but the idea is clearly along the lines of "this beast is so powerful it can cause earthquakes."
Earth power is literally summoning like volcanic activity from the earth below the opponent's feet.