Yes, exactly, “Crime and punishment” or ”Demons” or others. Some of the dialogues are exactly about the ideologies and how different characters think and apply them, how reason manifests in violence.
This made me think of C&P as well. Specifically how Raskolnikov developed his own half baked ideology where “great men” were free to act with impunity. It’s not hard to draw parallels with “longtermism” and effective altruism.