Add recursive doubling in pyss.