updated stokes-balance
numerous script and source bug fixes