While the meaning of 代える seems rather straightforward, the other two at times delude me. When should one be used over another? Are there any situations where both 換える and 替える are applicable?
Here's how I understand them
変える: You didn't include it, but most generic. "Change", "alter"
代える: Substitute (one thing for another)
- バターをマーガリンに代えてみたらどうですか → Why [don't you / not] substitute margarine for butter?
- 円をドルに換える → Exchange yen for dollars / Change yen into dollars
- 乗客に席を換えてもらう → Get another passenger to switch seats with me
- オイル交換 → Oil change
- 換気扇 → A ventilation fan
The idea here is that there is some kind of reciprocation. Agent A gives something to agent B, and agent B gives something back to agent A.
替える: Replace (something with a newer something)
- 古い機械を新しいのに替える必要がある → The old machines need to be replaced by [with] new ones.
- 畳を替える → Have the tatami mats re-covered
- 替え芯【しん】 → (pencil) lead refills; (pen) ballpoint pen refill
The truth is, there is a lot of overlap, so it's not always so easy to decide which is most correct.