entities – How can I programmatically delete a field value?

The field content is a field item list and normally you would need to include a single value also in an array. The fact that you can set a scalar like in your example is due to extra code in the Field API detecting the scalar and transferring it to a field item list with a single value. To delete the field you can’t set an empty scalar, though, because this would be interpreted as a single field item with that empty value.

So to delete the entire field content set an empty array:

$node->set('field_nom', ());

BTW you can get the entire field content:

$values = $node->get('field_nom')->getValue();

Change the array $values and set it again:

$node->set('field_nom', $values);