Calculation of no. of bricks