ST. CHARLES — St. Charles officials have gone to court in their push to get a federal agency to require Ameren to spend millions of dollars to help the city deal with groundwater contamination near the city’s drinking-water wells.