Zulip Chat Archive
Stream: maths
Topic: Mismatch between BSG in survey and LeanAPAP
Daniel Weber (Mar 04 2024 at 09:10):
I'm trying to formalize Bourgain's randomness extractor, following Incidence Theorems and Their Applications, Zeev Dvir. I have noticed that LeanAPAP has the BSG theorem (note that E[A,B]
there is in the survey, and the survey's is A.card^2 * B.card^2 / E[A,B]
), but the statements of the theorem seem different—in theorem 3.3.2 there are two subsets with a small sum, while in LeanAPAP there is only a single subset which doesn't grow much.
Are these two statements equivalent by some argument I'm not seeing? Are there two versions of BSG?
Yaël Dillies (Mar 04 2024 at 09:13):
Indeed there are many variants of BSG. Let me try to match up your statement and mine
Yaël Dillies (Mar 04 2024 at 09:20):
(btw it would be nice if LeanAPAP#BSG could be linkified)
Yaël Dillies (Mar 04 2024 at 09:47):
I must say Theorem 3.3.2 is a weird statement. It forces A
and B
to have the same size. From BSG
in LeanAPAP you can deduce that there are some A' ⊆ A
, B' ⊆ B
such that |A' - A'|
and |B' - B'|
are small, but I don't currently see how to get |A' + B'|
small from it
Thomas Bloom (Mar 04 2024 at 10:07):
Yes, there are a few basically equivalent versions around. The version with two different sets (of the same size) is equivalent by elementary methods to the version with one set:
Here's one trick that will work if you need A',B' to be different: if E(A,B) is N^3/K say then by pigeonholing there is a set B', subset of some translate of B, of size at least N/K (and replacing B by a translate if necessary) you can deduce that 1_A*1_A is at least N/2K pointwise on B'. Now Cauchy-Schwarz implies E(A,B') is at least N^3/4K^2, and apply the version of BSG that Yael has formalised to find some B'' inside B' with small doubling. But by averaging some translate of B'' has intersection at least N/K^c with A, let this be A''. Now we have sets A'' in A and B'' in B (or some translates of them) such that |A''+B''| \leq |B''+B''| and done.
Alternatively the proof that Yael has formalised adapts very easily to the case of two sets anyway, so probably easier to just copy and paste that proof and change some sets to be different.
Yaël Dillies (Mar 04 2024 at 10:08):
Is the two sets version strictly more general?
Thomas Bloom (Mar 04 2024 at 10:10):
Yaël Dillies said:
Is the two sets version strictly more general?
In a qualitative sense yes, but it's quantitatively a little different, if you care about the exponents.
Yaël Dillies (Mar 04 2024 at 10:10):
Okay, I see, the proof in LeanAPAP already gives the stronger result so I might as well adapt it
Daniel Weber (Mar 04 2024 at 10:36):
Thanks! By the way, was Ruzsa calculus formalized in Lean? I saw PFR has entropic Rusza calculus, I guess the set version can be derieved from it?
Yaël Dillies (Mar 04 2024 at 10:40):
Yes, we have Ruzsa calculus in mathlib already, see file#Combinatorics/Additive/PluenneckeRuzsa
Daniel Weber (Mar 04 2024 at 10:42):
Ok, thanks!
Mario Carneiro (Mar 04 2024 at 20:28):
@Yaël Dillies said:
(btw it would be nice if LeanAPAP#BSG could be linkified)
Daniel Weber (Mar 21 2024 at 10:21):
Yaël Dillies said:
Okay, I see, the proof in LeanAPAP already gives the stronger result so I might as well adapt it
Sorry to bother you, but are you planning on doing this soon or should I do it?
Daniel Weber (Mar 27 2024 at 13:30):
@Yaël Dillies ?
Yaël Dillies (Mar 27 2024 at 13:31):
Sorry, have had no time to fix it! Feel free to open a PR if you know how to
Daniel Weber (Mar 27 2024 at 13:32):
Ok. Would you mind sending a reference to the proof you formalized?
Yaël Dillies (Mar 27 2024 at 13:33):
Here it is: SimpleBSG.pdf
Daniel Weber (Mar 27 2024 at 14:01):
Thanks! I might be missing something, but from the proof we have that is a subset of a translate of , so it should be possible to just translate it back to get our , right? I'll try formalizing this
Yaël Dillies (Mar 27 2024 at 14:59):
Yes, that's basically what Tom said above
Daniel Weber (Mar 27 2024 at 15:42):
Yaël Dillies said:
Sorry, have had no time to fix it! Feel free to open a PR if you know how to
:+1: I opened https://github.com/YaelDillies/LeanAPAP/pull/6
Last updated: May 02 2025 at 03:31 UTC