Nitrogen fixing plants play an important role in sustainable gardening.
With nodules on their roots and the presence of beneficial bacteria, they take nitrogen out of the air and store it for use in their own growth, and once they die the roots release nitrogen back into the soil.
Some nitrogen fixing plants such as Alders (Alnus species) are essential pioneer trees. With soft wood, and short lived, they quickly grow to their adulthood then the brittle wood rots quickly once the tree dies, leaving behind nutrients for subsequent plants.
All peas and their leguminous relatives are nitrogen fixing plants.
These are often deliberately planted as cover crops to be dug in or to cut for composting.
Many leguminous plants also attract beneficial insects, including many pollinators.
Once the plants reach a certain size, they are either dug in to enrich the soil with organic matter, or cut down as fodder for animals (in the case of alfalfa hay) and as many of them are perennials, the top part will grow again, sometimes producing as many as three crops a year.The green part will compost quickly in the summer compost pile, making it useable to spread in the fall.
The roots of leguminous plants release nitrogen in small amounts as the roots die off and are replaced.
If the plant is killed off completely, this can cause a huge flush of nitrogen to be released as the roots decompose.Make sure you have something there to benefit from it, either a subsequent cover crop such as fall rye, buckwheat or another clover, or a crop of winter peas, or winter vegetables.