Modified orthogonality test for ellipsoidal harmonics