fixed minor bug in investment plan calculation