debugging current state of code
merged new code base
added null handler for calcTargets