Question: In Magento 1.9 I would like to filter the products returned by the layered navigation.
The collection should be filtered if the name contains a string passed through a parameter in the querystring, if present.

How can I achieve this results? Should I extend some layered navigation classes?

Answer: 
You cannot filter by names because Layer navigation only support attributes such as prices, drop-down or multi select.
You would have to write your own filter model that extends `Mage_Catalog_Model_Layer_Filter_Abstract`.

You can not use the core implementation for dropdown/multiselect attributes (`Mage_Catalog_Model_Layer_Filter_Attribute`) because it relies on the attribute index and exact matching.

To display the filter, you need to add a block that extends `Mage_Catalog_Block_Layer_Filter_Abstract` and rewrite [`Mage_Catalog_Block_Layer_View`](https://github.com/OpenMage/magento-mirror/blob/magento-1.9/app/code/core/Mage/Catalog/Block/Layer/View.php#L86-L90) to include it.