bug fixes
added debug print statements
added debug print statements
modified to be able to handle an "un-named" subset