equal
deleted
inserted
replaced
221 |
221 |
222 lemma fact_dvd_pochhammer: "fact k dvd pochhammer (a::int) k" |
222 lemma fact_dvd_pochhammer: "fact k dvd pochhammer (a::int) k" |
223 proof - |
223 proof - |
224 have dvd: "y \<noteq> 0 \<Longrightarrow> ((of_int (x div y))::'a::field_char_0) = of_int x / of_int y \<Longrightarrow> y dvd x" |
224 have dvd: "y \<noteq> 0 \<Longrightarrow> ((of_int (x div y))::'a::field_char_0) = of_int x / of_int y \<Longrightarrow> y dvd x" |
225 for x y :: int |
225 for x y :: int |
226 by (smt dvd_triv_left mult.commute nonzero_eq_divide_eq of_int_eq_0_iff of_int_eq_iff of_int_mult) |
226 by (metis dvd_triv_right nonzero_eq_divide_eq of_int_0_eq_iff of_int_eq_iff of_int_mult) |
227 show ?thesis |
227 show ?thesis |
228 proof (cases "0 < a") |
228 proof (cases "0 < a") |
229 case True |
229 case True |
230 moreover define n where "n = nat (a - 1) + k" |
230 moreover define n where "n = nat (a - 1) + k" |
231 ultimately have a: "a = int n - int k + 1" by simp |
231 ultimately have a: "a = int n - int k + 1" by simp |