no goals
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ ∏ x in s, f x ≤ ∏ x in t, f x
classical calc
  (∏ x in s, f x) = (∏ x in s.filter fun x ↦ f x = 1, f x) *
      ∏ x in s.filter fun x ↦ f x ≠ 1, f x := by
    rw [← prod_union, filter_union_filter_neg_eq]
    exact disjoint_filter.2 fun _ _ h n_h ↦ n_h h
  _ ≤ ∏ x in t, f x :=
    mul_le_of_le_one_of_le
      (prod_le_one' <| by simp only [mem_filter, and_imp] ; exact fun _ _ ↦ le_of_eq)
      (prod_le_prod_of_subset' <| by simpa only [subset_iff, mem_filter, and_imp] )
no goals
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ ∏ x in s, f x ≤ ∏ x in t, f x
calc
(∏ x in s, f x) = (∏ x in s.filter fun x ↦ f x = 1, f x) *
∏ x in s.filter fun x ↦ f x ≠ 1, f x := by
rw [← prod_union, filter_union_filter_neg_eq]
exact disjoint_filter.2 fun _ _ h n_h ↦ n_h h
_ ≤ ∏ x in t, f x :=
mul_le_of_le_one_of_le
(prod_le_one' <| by simp only [mem_filter, and_imp] ; exact fun _ _ ↦ le_of_eq)
(prod_le_prod_of_subset' <| by simpa only [subset_iff, mem_filter, and_imp] )
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ Disjoint (filter (fun x => f x = 1) s) (filter (fun x => f x ≠ 1) s)
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ ∏ x in s, f x = (∏ x in filter (fun x => f x = 1) s, f x) * ∏ x in filter (fun x => f x ≠ 1) s, f x
rw [← prod_union, filter_union_filter_neg_eq]
no goals
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ Disjoint (filter (fun x => f x = 1) s) (filter (fun x => f x ≠ 1) s)
exact disjoint_filter.2 fun _ _ h n_h ↦ n_h h
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ ∀ (i : ι), i ∈ s → f i = 1 → f i ≤ 1
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ ∀ (i : ι), i ∈ filter (fun x => f x = 1) s → f i ≤ 1
simp only [mem_filter, and_imp]
no goals
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ ∀ (i : ι), i ∈ s → f i = 1 → f i ≤ 1
exact fun _ _ ↦ le_of_eq
no goals
ι : Type u_1
α : Type ?u.118811
β : Type ?u.118814
M : Type u_2
N : Type ?u.118820
G : Type ?u.118823
k : Type ?u.118826
R : Type ?u.118829
inst✝ : CanonicallyOrderedMonoid M
f : ι → M
s t : Finset ι
h : ∀ (x : ι), x ∈ s → f x ≠ 1 → x ∈ t
⊢ filter (fun x => f x ≠ 1) s ⊆ t
simpa only [subset_iff, mem_filter, and_imp]