Within ecosystems are habitats. A habitat (for "it inhabits") is an ecological or environmental area that is inhabited by a particular animal or plant species. It is the natural environment in which an organism lives, or the physical environment that surrounds (influences and is utilized by) a species population.
Abiotic Interactions - Oxygen, water, nutrients for growth, light for photosynthesis and soil as an anchor and a sponge are all important.
Biotic Interactions - (when organisms interact) are sometimes ordered in an ecological hierachy of organism, population, community, and ecosystem. These interactions may be either positive (e.g. prey items, mutualists) or negative (e.g., predators, competitors); the biotic environment for an individual usually is composed both of organisms of the same species as the individual (intraspecific interactions) and organisms of other species (interspecific interactions).
For both the abiotic and biotic environment, the environment shapes the organism in a variety of ways including behaviorally, developmentally and evolutionarily. Ecologists may concentrate on particular aspects of the effect of the environment on organisms and, therefore, there are behavioral ecologists and evolutionary ecologists for example.
Keep in mind that the "interactions" among organisms and their environment occur at the level of the individual: it is individual organisms that interact (e.g., they eat, they are eaten, they release oxygen, they mate) with their environment. Therefore, underlying all of ecology (and all of biology) is the evolutionary process, particularly natural selection. The traits and mechanisms that individual organisms have that allow them to interact with their environment in specific ways are a result of natural selection.
Commensalism - In ecology, Commensalism is a class of relationship between two organisms where one organism benefits but the other is unaffected.
Commensalism derives from the English word commensal, meaning "sharing of food" in human social interaction, which in turn derives from the Latin com mensa, meaning "sharing a table".
An example of commensalism would be birds following army ant raids on a forest floor. As the army ant colony travels on the forest floor, they stir up various flying insect species. As the insects flee from the army ants, the birds following the ants catch the fleeing insects. In this way, the army ants and the birds are in a commensal relationship because the birds benefit while the army ants are unaffected. The D. folliculorum mites living in your eyelash follicles share a similar relationship with you. Orchids and mosses are plants that can have a commensal relationship with trees. The plants grow on the trunks or branches of trees. They get the light they need as well as nutrients that run down along the tree. As long as these plants do not grow too heavy, the tree is not affected.
Mutualism - Mutualism is a biological interaction between two organisms, where each individual derives a fitness benefit, for example increased survivorship. Similar interactions within a species are known as co-operation. It can be contrasted with interspecific competition, in which each species experiences reduced fitness, and exploitation, in which one species benefits at the expense of the other. Mutualism and symbiosis are sometimes used as if they are synonymous, but this is strictly incorrect: symbiosis is a broad category, defined to include relationships which are mutualistic, parasitic or commensal. Mutualism is only one type.
Mutualism plays a key part in ecology. For example, mutualistic interactions are vital for terrestrial ecosystem function as more than 70% of land plants rely on mycorrhizal relationships with fungi to provide them with inorganic compounds and trace elements.
In addition, mutualism is thought to have driven the evolution of much of the biological diversity we see, such as flower forms (important for pollination mutualisms) and co-evolution between groups of species. However mutualism has historically received less attention than other interactions such as predation and parasitism.
Parasitism - Parasitism is a type of symbiotic relationship between organisms of different species where one organism, the parasite, benefits at the expense of the host.
In general, parasites are much smaller than their hosts, show a high degree of specialization for their mode of life, and reproduce more quickly and in greater numbers than their hosts. Classic examples of parasitism include interactions between vertebrate hosts and diverse animals such as tapeworms, flukes, and the Plasmodium species.
The harm and benefit in parasitic interactions concern the biological fitness of the organisms involved. Parasites reduce host fitness in many ways, ranging from general or specialized pathology to the modification of host behaviour. Parasites increase their fitness by exploiting hosts for food, habitat and dispersal.
Competition - Competition is a contest between individuals, groups, nations, animals, etc. for territory, a niche, or allocation of resources. It arises whenever two or more parties strive for a goal which cannot be shared. Competition occurs naturally between living organisms which co-exist in the same environment. For example, animals compete over water supplies, food, and mates, etc. Humans compete for water, food, and mates, though when these needs are met deep rivalries often arise over the pursuit of wealth, prestige, and fame. Business is often associated with competition as most companies are in competition with at least one other firm over the same group of customers.
Predation - In ecology, predation describes a biological interaction where a predator (an organism that is hunting) feeds on its prey, (the organism that is attacked). Predators may or may not kill their prey prior to feeding on them, but the act of predation always results in the death of the prey.
Selective pressures imposed on one another has led to an evolutionary arms race between prey and predator, resulting in various antipredator adaptations.
Check out Wator an online Predator-Prey Simulator
Also check out Foxes and Rabbits another online Predator-Prey Simulator