(Deuteronomy 22: 20-21)
or
(Leviticus 21:18-21)
You honestly think they are better or logical at all?
I can see why rules must be in place to limit infidelity and preserve the stability of the family unit and ultimately society at large. I can see why the options for such rules in primitive tribal time would be very limited.
I can also see the logic in establishing the precedent that drawing closer to God entails increasing perfection. Perfection in thought, perfection in action, and ultimately perfection in form.
So yes I think those passages were a logical means of stabilizing early societies and leading towards long term prosperity. Do I think we should execute people via stoning or forbid the very sick and deformed from entering churches today of course not.