Theorem: ArithmeticFunction.IsMultiplicative.map_prod
File: Mathlib/NumberTheory/ArithmeticFunction.lean

tactic: induction' s using Finset.induction_on with a s has ih hs
state_before: R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
s : Finset ι
hs : (↑s).Pairwise (Coprime on g)
⊢ f (∏ i ∈ s, g i) = ∏ i ∈ s, f (g i)
state_after: case empty
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
hs : (↑∅).Pairwise (Coprime on g)
⊢ f (∏ i ∈ ∅, g i) = ∏ i ∈ ∅, f (g i)

case insert
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
a : ι
s : Finset ι
has : a ∉ s
ih : (↑s).Pairwise (Coprime on g) → f (∏ i ∈ s, g i) = ∏ i ∈ s, f (g i)
hs : (↑(insert a s)).Pairwise (Coprime on g)
⊢ f (∏ i ∈ insert a s, g i) = ∏ i ∈ insert a s, f (g i)

tactic: rw [coe_insert, Set.pairwise_insert_of_symmetric (Coprime.symmetric.comap g)] at hs
state_before: case insert
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
a : ι
s : Finset ι
has : a ∉ s
ih : (↑s).Pairwise (Coprime on g) → f (∏ i ∈ s, g i) = ∏ i ∈ s, f (g i)
hs : (↑(insert a s)).Pairwise (Coprime on g)
⊢ f (∏ i ∈ insert a s, g i) = ∏ i ∈ insert a s, f (g i)
state_after: case insert
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
a : ι
s : Finset ι
has : a ∉ s
ih : (↑s).Pairwise (Coprime on g) → f (∏ i ∈ s, g i) = ∏ i ∈ s, f (g i)
hs : (↑s).Pairwise (Coprime on g) ∧ ∀ b ∈ ↑s, a ≠ b → (Coprime on g) a b
⊢ f (∏ i ∈ insert a s, g i) = ∏ i ∈ insert a s, f (g i)

tactic: rw [prod_insert has, prod_insert has, hf.map_mul_of_coprime, ih hs.1]
state_before: case insert
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
a : ι
s : Finset ι
has : a ∉ s
ih : (↑s).Pairwise (Coprime on g) → f (∏ i ∈ s, g i) = ∏ i ∈ s, f (g i)
hs : (↑s).Pairwise (Coprime on g) ∧ ∀ b ∈ ↑s, a ≠ b → (Coprime on g) a b
⊢ f (∏ i ∈ insert a s, g i) = ∏ i ∈ insert a s, f (g i)
state_after: case insert
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
a : ι
s : Finset ι
has : a ∉ s
ih : (↑s).Pairwise (Coprime on g) → f (∏ i ∈ s, g i) = ∏ i ∈ s, f (g i)
hs : (↑s).Pairwise (Coprime on g) ∧ ∀ b ∈ ↑s, a ≠ b → (Coprime on g) a b
⊢ (g a).Coprime (∏ x ∈ s, g x)

tactic: exact .prod_right fun i hi => hs.2 _ hi (hi.ne_of_not_mem has).symm
state_before: case insert
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
a : ι
s : Finset ι
has : a ∉ s
ih : (↑s).Pairwise (Coprime on g) → f (∏ i ∈ s, g i) = ∏ i ∈ s, f (g i)
hs : (↑s).Pairwise (Coprime on g) ∧ ∀ b ∈ ↑s, a ≠ b → (Coprime on g) a b
⊢ (g a).Coprime (∏ x ∈ s, g x)
state_after: no goals

tactic: simp [hf]
state_before: case empty
R : Type u_1
ι : Type u_2
inst✝ : CommMonoidWithZero R
g : ι → ℕ
f : ArithmeticFunction R
hf : f.IsMultiplicative
hs : (↑∅).Pairwise (Coprime on g)
⊢ f (∏ i ∈ ∅, g i) = ∏ i ∈ ∅, f (g i)
state_after: no goals