For a property Gamma and a family of sets F, let f(F,Gamma) be the size of the largest subfamily of F having property Gamma. For a positive integer m, let f(m,Gamma) be the minimum of f(F,Gamma) over all families of size m.
A family F is said to be Bd-free if it has no subfamily F'={FI:I is a subset of [d]} of d2 distinct sets such that for every two subsets I,J of [d], the union of FI and FJ is euqal to F(I union J) and the intersection of FI and FJ is euqal to F(I intersection J). A family F is a-union free if the union of F_1, F_2... and F_a is different from F_a+1 whenever F1,...,F_a+1 are distinct sets in F.
We verify a conjecture of Erdős and Shelah that f(m,B2-free)=Theta(m2/3). We also obtain lower and upper bounds for f(m,Bd-free) and f(m,a-union free).