delete a specific element within field collection programmatically
You need to grab the id of the field collection and wrap itself in an entity wrapper. Use the save method in the wrapper to do this instead of the entity_save function. E.g.

 $wrapper = entity_metadata_wrapper('field_collection_item', $entity);
 $wrapper-&gt;field_specific_field_collection_item-&gt;set("");


or:

$wrapper-&gt;field_specific_field_collection_item = array();
$wrapper-&gt;save();