@@ -46,7 +46,7 @@ variable {α β : Type _} [Fintype α] [Fintype β] [DecidableEq β] [DecidableE
46
46
local notation3 "m" => Fintype.card α
47
47
local notation3 "n" => Fintype.card β
48
48
local notation3 "e" => m / ((n : ℝ) - m) -- exponent
49
- local notation3 "B" => Nat.floor (((n : ℝ) * ‖A‖) ^ e)
49
+ local notation3 "B" => Nat.floor (((n : ℝ) * max 1 ‖A‖) ^ e)
50
50
-- B' is the vector with all components = B
51
51
local notation3 "B'" => fun _ : β => (B : ℤ)
52
52
-- T is the box [0 B]^n
@@ -116,10 +116,8 @@ private lemma card_S_eq : (Finset.Icc N P).card = ∏ i : α, (P i - N i + 1) :=
116
116
rw [Int.card_Icc_of_le (N i) (P i) (N_le_P_add_one A i)]
117
117
exact add_sub_right_comm (P i) 1 (N i)
118
118
119
- variable (hA : A ≠ 0 )
120
-
121
119
/-- The sup norm of a non-zero integer matrix is at least one -/
122
- lemma one_le_norm_A_of_ne_zero : 1 ≤ ‖A‖ := by
120
+ lemma one_le_norm_A_of_ne_zero (hA : A ≠ 0 ) : 1 ≤ ‖A‖ := by
123
121
by_contra! h
124
122
apply hA
125
123
ext i j
@@ -140,49 +138,49 @@ private lemma card_S_lt_card_T : (S).card < (T).card := by
140
138
rify -- This is necessary because ‖A‖ is a real number
141
139
calc
142
140
∏ x : α, (∑ x_1 : β, ↑B * ↑(A x x_1)⁺ - ∑ x_1 : β, ↑B * -↑(A x x_1)⁻ + 1 )
143
- ≤ ∏ x : α, (n * ‖A‖ * B + 1 ) := by
141
+ ≤ ∏ x : α, (n * max 1 ‖A‖ * B + 1 ) := by
144
142
refine Finset.prod_le_prod (fun i _ ↦ ?_) (fun i _ ↦ ?_)
145
143
· have h := N_le_P_add_one A i
146
144
rify at h
147
145
linarith only [h]
148
146
· simp only [mul_neg, sum_neg_distrib, sub_neg_eq_add, add_le_add_iff_right]
149
- have h1 : n * ‖A‖ * B = ∑ _ : β, ‖A‖ * B := by
147
+ have h1 : n * max 1 ‖A‖ * B = ∑ _ : β, max 1 ‖A‖ * B := by
150
148
simp only [sum_const, card_univ, nsmul_eq_mul]
151
149
ring
152
- simp_rw [h1, ← Finset.sum_add_distrib, ← mul_add, mul_comm ‖A‖, ← Int.cast_add]
150
+ simp_rw [h1, ← Finset.sum_add_distrib, ← mul_add, mul_comm (max 1 ‖A‖) , ← Int.cast_add]
153
151
gcongr with j _
154
152
rw [posPart_add_negPart (A i j), Int.cast_abs]
155
- exact norm_entry_le_entrywise_sup_norm A
156
- _ = (n * ‖A‖ * B + 1 ) ^ m := by simp only [prod_const, card_univ]
157
- _ ≤ (n * ‖A‖) ^ m * (B + 1 ) ^ m := by
153
+ exact le_trans ( norm_entry_le_entrywise_sup_norm A) (le_max_right ..)
154
+ _ = (n * max 1 ‖A‖ * B + 1 ) ^ m := by simp only [prod_const, card_univ]
155
+ _ ≤ (n * max 1 ‖A‖) ^ m * (B + 1 ) ^ m := by
158
156
rw [← mul_pow, mul_add, mul_one]
159
157
gcongr
160
158
have H : 1 ≤ (n : ℝ) := mod_cast (hm.trans hn)
161
- exact one_le_mul_of_one_le_of_one_le H <| one_le_norm_A_of_ne_zero A hA
162
- _ = ((n * ‖A‖) ^ (m / ((n : ℝ) - m))) ^ ((n : ℝ) - m) * (B + 1 ) ^ m := by
159
+ exact one_le_mul_of_one_le_of_one_le H <| le_max_left ..
160
+ _ = ((n * max 1 ‖A‖) ^ (m / ((n : ℝ) - m))) ^ ((n : ℝ) - m) * (B + 1 ) ^ m := by
163
161
congr 1
164
- rw [← rpow_mul (mul_nonneg (Nat.cast_nonneg' n) (norm_nonneg A)), ← Real.rpow_natCast ,
165
- div_mul_cancel₀]
162
+ rw [← rpow_mul (mul_nonneg (Nat.cast_nonneg' n) (le_trans zero_le_one (le_max_left ..))) ,
163
+ ← Real.rpow_natCast, div_mul_cancel₀]
166
164
exact sub_ne_zero_of_ne (mod_cast hn.ne')
167
165
_ < (B + 1 ) ^ ((n : ℝ) - m) * (B + 1 ) ^ m := by
168
166
gcongr
169
167
· exact sub_pos.mpr (mod_cast hn)
170
- · exact Nat.lt_floor_add_one ((n * ‖A‖) ^ e)
168
+ · exact Nat.lt_floor_add_one ((n * max 1 ‖A‖) ^ e)
171
169
_ = (B + 1 ) ^ n := by
172
170
rw [← rpow_natCast, ← rpow_add (Nat.cast_add_one_pos B), ← rpow_natCast, sub_add_cancel]
173
171
174
172
end preparation
175
173
176
- theorem exists_ne_zero_int_vec_norm_le (hA_nezero : A ≠ 0 ) : ∃ t : β → ℤ, t ≠ 0 ∧
177
- A *ᵥ t = 0 ∧ ‖t‖ ≤ (n * ‖A‖) ^ ((m : ℝ) / (n - m)) := by
174
+ theorem exists_ne_zero_int_vec_norm_le : ∃ t : β → ℤ, t ≠ 0 ∧
175
+ A *ᵥ t = 0 ∧ ‖t‖ ≤ (n * max 1 ‖A‖) ^ ((m : ℝ) / (n - m)) := by
178
176
-- Pigeonhole
179
177
rcases Finset.exists_ne_map_eq_of_card_lt_of_maps_to
180
- (card_S_lt_card_T A hn hm hA_nezero ) (image_T_subset_S A)
178
+ (card_S_lt_card_T A hn hm) (image_T_subset_S A)
181
179
with ⟨x, hxT, y, hyT, hneq, hfeq⟩
182
180
-- Proofs that x - y ≠ 0 and x - y is a solution
183
181
refine ⟨x - y, sub_ne_zero.mpr hneq, by simp only [mulVec_sub, sub_eq_zero, hfeq], ?_⟩
184
182
-- Inequality
185
- have n_mul_norm_A_pow_e_nonneg : 0 ≤ (n * ‖A‖) ^ e := by positivity
183
+ have n_mul_norm_A_pow_e_nonneg : 0 ≤ (n * max 1 ‖A‖) ^ e := by positivity
186
184
rw [← norm_col (ι := Unit), norm_le_iff n_mul_norm_A_pow_e_nonneg]
187
185
intro i j
188
186
simp only [col_apply, Pi.sub_apply]
@@ -203,4 +201,11 @@ theorem exists_ne_zero_int_vec_norm_le (hA_nezero : A ≠ 0) : ∃ t : β →
203
201
simp only [le_add_iff_nonneg_right]
204
202
exact hyT.1 i
205
203
204
+
205
+ theorem exists_ne_zero_int_vec_norm_le' (hA : A ≠ 0 ) : ∃ t : β → ℤ, t ≠ 0 ∧
206
+ A *ᵥ t = 0 ∧ ‖t‖ ≤ (n * ‖A‖) ^ ((m : ℝ) / (n - m)) := by
207
+ have := exists_ne_zero_int_vec_norm_le A hn hm
208
+ rwa [max_eq_right] at this
209
+ exact Int.Matrix.one_le_norm_A_of_ne_zero _ hA
210
+
206
211
end Int.Matrix
0 commit comments