Users' Mathboxes Mathbox for Mario Carneiro < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  subfaclefac Structured version   Visualization version   GIF version

Theorem subfaclefac 31674
Description: The subfactorial is less than the factorial. (Contributed by Mario Carneiro, 19-Jan-2015.)
Hypotheses
Ref Expression
derang.d 𝐷 = (𝑥 ∈ Fin ↦ (♯‘{𝑓 ∣ (𝑓:𝑥1-1-onto𝑥 ∧ ∀𝑦𝑥 (𝑓𝑦) ≠ 𝑦)}))
subfac.n 𝑆 = (𝑛 ∈ ℕ0 ↦ (𝐷‘(1...𝑛)))
Assertion
Ref Expression
subfaclefac (𝑁 ∈ ℕ0 → (𝑆𝑁) ≤ (!‘𝑁))
Distinct variable groups:   𝑓,𝑛,𝑥,𝑦,𝑁   𝐷,𝑛   𝑆,𝑛,𝑥,𝑦
Allowed substitution hints:   𝐷(𝑥,𝑦,𝑓)   𝑆(𝑓)

Proof of Theorem subfaclefac
StepHypRef Expression
1 anidm 561 . . . . . 6 ((𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ 𝑓:(1...𝑁)–1-1-onto→(1...𝑁)) ↔ 𝑓:(1...𝑁)–1-1-onto→(1...𝑁))
21abbii 2917 . . . . 5 {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ 𝑓:(1...𝑁)–1-1-onto→(1...𝑁))} = {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}
3 fzfid 13026 . . . . . 6 (𝑁 ∈ ℕ0 → (1...𝑁) ∈ Fin)
4 deranglem 31664 . . . . . 6 ((1...𝑁) ∈ Fin → {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ 𝑓:(1...𝑁)–1-1-onto→(1...𝑁))} ∈ Fin)
53, 4syl 17 . . . . 5 (𝑁 ∈ ℕ0 → {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ 𝑓:(1...𝑁)–1-1-onto→(1...𝑁))} ∈ Fin)
62, 5syl5eqelr 2884 . . . 4 (𝑁 ∈ ℕ0 → {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)} ∈ Fin)
7 simpl 475 . . . . 5 ((𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦) → 𝑓:(1...𝑁)–1-1-onto→(1...𝑁))
87ss2abi 3871 . . . 4 {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ⊆ {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}
9 ssdomg 8242 . . . 4 ({𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)} ∈ Fin → ({𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ⊆ {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)} → {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ≼ {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}))
106, 8, 9mpisyl 21 . . 3 (𝑁 ∈ ℕ0 → {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ≼ {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)})
11 deranglem 31664 . . . . 5 ((1...𝑁) ∈ Fin → {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ∈ Fin)
123, 11syl 17 . . . 4 (𝑁 ∈ ℕ0 → {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ∈ Fin)
13 hashdom 13417 . . . 4 (({𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ∈ Fin ∧ {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)} ∈ Fin) → ((♯‘{𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)}) ≤ (♯‘{𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}) ↔ {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ≼ {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}))
1412, 6, 13syl2anc 580 . . 3 (𝑁 ∈ ℕ0 → ((♯‘{𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)}) ≤ (♯‘{𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}) ↔ {𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)} ≼ {𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}))
1510, 14mpbird 249 . 2 (𝑁 ∈ ℕ0 → (♯‘{𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)}) ≤ (♯‘{𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}))
16 derang.d . . . 4 𝐷 = (𝑥 ∈ Fin ↦ (♯‘{𝑓 ∣ (𝑓:𝑥1-1-onto𝑥 ∧ ∀𝑦𝑥 (𝑓𝑦) ≠ 𝑦)}))
17 subfac.n . . . 4 𝑆 = (𝑛 ∈ ℕ0 ↦ (𝐷‘(1...𝑛)))
1816, 17subfacval 31671 . . 3 (𝑁 ∈ ℕ0 → (𝑆𝑁) = (𝐷‘(1...𝑁)))
1916derangval 31665 . . . 4 ((1...𝑁) ∈ Fin → (𝐷‘(1...𝑁)) = (♯‘{𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)}))
203, 19syl 17 . . 3 (𝑁 ∈ ℕ0 → (𝐷‘(1...𝑁)) = (♯‘{𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)}))
2118, 20eqtrd 2834 . 2 (𝑁 ∈ ℕ0 → (𝑆𝑁) = (♯‘{𝑓 ∣ (𝑓:(1...𝑁)–1-1-onto→(1...𝑁) ∧ ∀𝑦 ∈ (1...𝑁)(𝑓𝑦) ≠ 𝑦)}))
22 hashfac 13490 . . . 4 ((1...𝑁) ∈ Fin → (♯‘{𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}) = (!‘(♯‘(1...𝑁))))
233, 22syl 17 . . 3 (𝑁 ∈ ℕ0 → (♯‘{𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}) = (!‘(♯‘(1...𝑁))))
24 hashfz1 13385 . . . 4 (𝑁 ∈ ℕ0 → (♯‘(1...𝑁)) = 𝑁)
2524fveq2d 6416 . . 3 (𝑁 ∈ ℕ0 → (!‘(♯‘(1...𝑁))) = (!‘𝑁))
2623, 25eqtr2d 2835 . 2 (𝑁 ∈ ℕ0 → (!‘𝑁) = (♯‘{𝑓𝑓:(1...𝑁)–1-1-onto→(1...𝑁)}))
2715, 21, 263brtr4d 4876 1 (𝑁 ∈ ℕ0 → (𝑆𝑁) ≤ (!‘𝑁))
Colors of variables: wff setvar class
Syntax hints:  wi 4  wb 198  wa 385   = wceq 1653  wcel 2157  {cab 2786  wne 2972  wral 3090  wss 3770   class class class wbr 4844  cmpt 4923  1-1-ontowf1o 6101  cfv 6102  (class class class)co 6879  cdom 8194  Fincfn 8196  1c1 10226  cle 10365  0cn0 11579  ...cfz 12579  !cfa 13312  chash 13369
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1891  ax-4 1905  ax-5 2006  ax-6 2072  ax-7 2107  ax-8 2159  ax-9 2166  ax-10 2185  ax-11 2200  ax-12 2213  ax-13 2378  ax-ext 2778  ax-rep 4965  ax-sep 4976  ax-nul 4984  ax-pow 5036  ax-pr 5098  ax-un 7184  ax-cnex 10281  ax-resscn 10282  ax-1cn 10283  ax-icn 10284  ax-addcl 10285  ax-addrcl 10286  ax-mulcl 10287  ax-mulrcl 10288  ax-mulcom 10289  ax-addass 10290  ax-mulass 10291  ax-distr 10292  ax-i2m1 10293  ax-1ne0 10294  ax-1rid 10295  ax-rnegex 10296  ax-rrecex 10297  ax-cnre 10298  ax-pre-lttri 10299  ax-pre-lttrn 10300  ax-pre-ltadd 10301  ax-pre-mulgt0 10302
This theorem depends on definitions:  df-bi 199  df-an 386  df-or 875  df-3or 1109  df-3an 1110  df-tru 1657  df-ex 1876  df-nf 1880  df-sb 2065  df-mo 2592  df-eu 2610  df-clab 2787  df-cleq 2793  df-clel 2796  df-nfc 2931  df-ne 2973  df-nel 3076  df-ral 3095  df-rex 3096  df-reu 3097  df-rmo 3098  df-rab 3099  df-v 3388  df-sbc 3635  df-csb 3730  df-dif 3773  df-un 3775  df-in 3777  df-ss 3784  df-pss 3786  df-nul 4117  df-if 4279  df-pw 4352  df-sn 4370  df-pr 4372  df-tp 4374  df-op 4376  df-uni 4630  df-int 4669  df-iun 4713  df-br 4845  df-opab 4907  df-mpt 4924  df-tr 4947  df-id 5221  df-eprel 5226  df-po 5234  df-so 5235  df-fr 5272  df-we 5274  df-xp 5319  df-rel 5320  df-cnv 5321  df-co 5322  df-dm 5323  df-rn 5324  df-res 5325  df-ima 5326  df-pred 5899  df-ord 5945  df-on 5946  df-lim 5947  df-suc 5948  df-iota 6065  df-fun 6104  df-fn 6105  df-f 6106  df-f1 6107  df-fo 6108  df-f1o 6109  df-fv 6110  df-riota 6840  df-ov 6882  df-oprab 6883  df-mpt2 6884  df-om 7301  df-1st 7402  df-2nd 7403  df-wrecs 7646  df-recs 7708  df-rdg 7746  df-1o 7800  df-2o 7801  df-oadd 7804  df-er 7983  df-map 8098  df-pm 8099  df-en 8197  df-dom 8198  df-sdom 8199  df-fin 8200  df-card 9052  df-cda 9279  df-pnf 10366  df-mnf 10367  df-xr 10368  df-ltxr 10369  df-le 10370  df-sub 10559  df-neg 10560  df-div 10978  df-nn 11314  df-n0 11580  df-xnn0 11652  df-z 11666  df-uz 11930  df-fz 12580  df-seq 13055  df-fac 13313  df-bc 13342  df-hash 13370
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator