Monotonicity and contractivity in reaction networks: algorithms and theory.