custom stack in area calculation