functions from Paul and Julia added and examples inserted.