Updating delta and theta