fixed bugs in objective calculation. dakota in tmpl housekeeping