roughed in the ray equation