Biological fluidized beds for water and wastewater treatment