Determining nest now more elegant. Fixes Issue #111.