The pyroxenes (commonly abbreviated to Px) are a group of important rock-forming inosilicate minerals found in many igneous and metamorphic rocks.
The creation of pryoxenes are made throughout the process of which containing the substances and cooling of lava (and) magma cools.
Hope this helps!
Have a great day.