It’s good to remember that scientists are just as capable of violence (if anything, they can be better at it). It might also be a mistake to think that rational people are inherently less violent towards other people. Finally, I reckon it’s especially dangerous to think the Nazi did what they did just because of “bad emotions”.
The trolley problem adjacent research has shown (if inconclusively) that more rational people are more likely to be OK being a cause of harm to other people to achieve some goal. In those experiments such goal is usually “save more people”, but all you need is to define some terms and “kill some now” might seem imperative to “save more later” to a sufficiently rational, long-term-thinking, “smart” person.
So the Nazi did, and there is much less conjecture here since it’s mostly well-documented. They were specifically inspired by natural sciences, including the then-new Darwin’s theory of natural selection. If anything, their shtick might’ve been to overcome the “bad” (for the Nazi) emotions that one may experience when sending some disabled person or a Jew to death. Which, according to them, had to be done since they were detrimental to survival of humanity (as Nazis defined it, of course) by polluting its genetic pool—so they were taught to train themselves to treat Jews as non-human bedbugs, stripped Jews of citizenship, disciplined fellow Germans who dared to shake hands with a Jew, etc. To Nazis emotions were a hindrance, they included the “irrational” compassion, and we might be better off remembering that when we discuss rationality, which consequentialism tends to go hand in hand with.
Addendum: An obvious argument can be made that Nazis were “not rational enough”, i.e. the problem is not with rationality per se but only with rationality based on premises that we now know are wrong. That, however, shows nothing because if we’ve learned anything it should be not to assume that now we have finally got all of our premises in order and possess absolute truth and complete understanding of reality.