more robust finite cell code