Well... It's a weird equation that's logarithmically bound. The is no easy answer. Essentially - the more you have, the less it gives per point and it's different for each difficulty.
Basically - just keep your stuff leveled up to the level of the loot that drops around you. In WotSam/Strong, any armor can take a decent hit and most folks don't have enough stamina to wear heavy and go light with A Agility or medium with B agility.
In WotD, light armor will get one-shorted if low level, but survive if properly leveled to the level and plus value of the divine loot that drops. WotW, strong attacks from large yokai or skill attacks from bosses can only be survived with heavy armor, but any armor can take other hits of properly leveled.
WotN, if it's not heavy armor (roughly 35% damage reduction) you can't take much, if any, hits. But full heavy will survive until floor 160 in abyss. Above that, you need about 50+% damage reduction - so full Tatenashi or Oyamatsumi with heavy armor. But that can take a hit throughout the entire abyss if it doesn't weaken your armor.
Defense always does something, but from about WotW onwards - it's largely irrelevant. So just keep your gear leveled up to the level of divine loot that drops around you, and you should be just fine - just ignore defense and look at equipment level.
Because isolating the exact equation would involve non-linear regression that is exponentially bound at/above certain values. And you'd have to factor out spirit protection and damage reduction and it'd get really messy and really complicated.
The definition of insanity is doing the same thing again and again, while expecting different results. (As defined by Einstein)
Maybe we're all a little crazy.