Initial commit
merge code from mark mandel