Extended Gauss code