Wastewater from characterization to treatment