Companion planting

In gardening and farming, companion planting is the planting of different crops next to each other. It is done to help the crops grow and to use the space available as much as possible.
Depending on the crops chosen, companion planting may encourage processes that help the plants, such as pollination. Some companion plants may help stop pests, such as caterpillars or fungi, from damaging the crop. Some of these, called "trap crops" attract pests away from the crop. Other plants may serve as shelter for the crops.
Many of the basic principles of companion planting were used thousands of years ago in Mesoamerica. From about 8,000 years ago, Native American peoples grew squash, maize and common beans together. The stalk of the corn were there for the beans to climb, and the beans fixed nitrogen, helping the maize.