s/pend/dpend/ in rest of script, theta0/1->1/2