Fix hs and sc matlab precomputations