Suppose the number of anions B=n . Then number of octahedral voids=n
Number of tetrahedral voids =2n
As octahedral and tetrahedral voids are equally occupied by cations A and all the octahedral voids are occupied (given ), therefore n cations A are present in octahedral voids and n cations A are present in tetrahedral voids. In other words, corresponding to n anions B, there are n+n=2n cations A . Thus, cations A and anions B are in the ratio 2n:n=2:1 . Hence , the formula of the solid will be `A_2B`