The ecosystem consists of living organisms and non-living elements in a particular environment. The ecosystem can be a terrestrial or aquatic ecosystem.
The terrestrial ecosystem includes interaction between the species in the terrestrial region whereas the aquatic one includes species living in water bodies. The ecosystems are present everywhere in our surroundings though they are not visible to us.
Abiotic factors include rainfall, temperature, sunlight, atmospheric humidity, soil conditions, inorganic substances (carbon dioxide, water, nitrogen, calcium, phosphorus, potassium, etc.).
Biotic factors include the producers, the consumers (primary, secondary, tertiary) and the decomposers. Producers include all the green plants, which manufacture their own food through photosynthesis.
The primary consumers include herbivorous animals like deer, goats, mice and all plant eating animals. The carnivores include all the flesh-eating animals like snakes, tigers and lions.
Certain carnivores that feed also on carnivores are known as top carnivores like hawks and mongooses.
Decomposers are those that feed on dead organisms (for example, scavengers like vultures and crows), and further breaking down of the dead matter by other decomposing agents like bacteria and various micro-organisms.