some leg work for Issue #2

a number of gerneralizations and file additions to make the code more portable and easier to work on Issue #2