submitted version of paper, probably needs proof reading and further work