bernstein_coefficients: skip infinite (sub)domains