equal
deleted
inserted
replaced
464 have "0 + 0 \<le> a + b" |
464 have "0 + 0 \<le> a + b" |
465 using assms by (rule add_mono) |
465 using assms by (rule add_mono) |
466 then show ?thesis by simp |
466 then show ?thesis by simp |
467 qed |
467 qed |
468 |
468 |
469 lemma add_neg_nonpos: |
469 lemma add_neg_nonpos: |
470 assumes "a < 0" and "b \<le> 0" shows "a + b < 0" |
470 assumes "a < 0" and "b \<le> 0" shows "a + b < 0" |
471 proof - |
471 proof - |
472 have "a + b < 0 + 0" |
472 have "a + b < 0 + 0" |
473 using assms by (rule add_less_le_mono) |
473 using assms by (rule add_less_le_mono) |
474 then show ?thesis by simp |
474 then show ?thesis by simp |
491 proof - |
491 proof - |
492 have "a + b \<le> 0 + 0" |
492 have "a + b \<le> 0 + 0" |
493 using assms by (rule add_mono) |
493 using assms by (rule add_mono) |
494 then show ?thesis by simp |
494 then show ?thesis by simp |
495 qed |
495 qed |
|
496 |
|
497 lemmas add_sign_intros = |
|
498 add_pos_nonneg add_pos_pos add_nonneg_pos add_nonneg_nonneg |
|
499 add_neg_nonpos add_neg_neg add_nonpos_neg add_nonpos_nonpos |
496 |
500 |
497 lemma add_nonneg_eq_0_iff: |
501 lemma add_nonneg_eq_0_iff: |
498 assumes x: "0 \<le> x" and y: "0 \<le> y" |
502 assumes x: "0 \<le> x" and y: "0 \<le> y" |
499 shows "x + y = 0 \<longleftrightarrow> x = 0 \<and> y = 0" |
503 shows "x + y = 0 \<longleftrightarrow> x = 0 \<and> y = 0" |
500 proof (intro iffI conjI) |
504 proof (intro iffI conjI) |