Leguminous crop rotation and other crop rotations are used in agriculture because in these plants many bacteria important for the nitrogen cycle live. The leguminous crop rotation (or cojointly with the main crop) helps the soil to become rich in nitrates that are then absorbed by the plants.
Green manure, the covering of the soil with grass and leguminous plants, is also a way to improve the fixation of nitrogen and it is an option in avoiding chemical fertilizers.