Compute main from aux