produces reasonable results but still an error