The theory behind companion planting is that certain plants such as marigolds, and nasturtiums are so pungent and produce an odour which many insects absolutely loathe. Tomatoes are particularly susceptible to aphids, whitefly and root nematodes. Marigolds work well to repel these harmful pests. When you plant basil with tomatoes both plants will grow stronger and better. Even if you just have a tomato in a pot you can plant some flowers and herbs around it. You just have to make sure you provide enough water for all the plants that are in the pot, and fertilize more frequently as well.