Updating SHIVA code with Bill's latest and reminifying