add shrinkTo function

add shrinkTo function for CT::Vector
fix compile crashs
Merge pull request #392 from psychocoderHPC/topic-addShrinkFunction

Topic add shrink function