When humans respire, they tank in air and give off a lot of CO2. When fish respire, the the gills give off a lot of CO2, but also quite a bit of ammonia, NH3. This NH3 off the gills is the largest contributor to ammonia in the tank. Fish waste, excess fishfood and plant debris all litter the tank with organic materials. These organic materials are quickly used by clouds of heterotrophic bacteria that are present in large numbers in the water and more ammonia is given off.
In nature the ammonia is immediately carried away from fish gills by and diluted in millions of gallons of water. By contrast, our aquariums are tiny glass boxes and the ammonia concentration builds up very differently than in the wild. Ammonia, even in small amounts, causes permanent gill damage and can lead to shortened fish lives and even death. In our tanks, when the bacteria suppression of chlorine/choramine is removed, many species of microscopic bacteria are freed up to reproduce. Besides the heterotrophic species populating the water, there are autotrophic species that attach themselves to hard surfaces. One specific type, Nitrosomonas, will grow in freshwater conditions with trace to 7ppm ammonia and pH conditions of 6.2 to 8.9 or so and will be the most efficient "ammonia oxidizing bacteria" or "ammonia eaters." These bacteria will convert ammonia (NH3) into nitrite(NO2) which, unfortunately, is also deadly to fish.
Nitrite(NO2), even in small amounts, breaks down the hemoglobin protein, destroying the red blood cells in fish blood, leading to suffocation and initially to brain and nerve damage. This causes shortened lives and/or death. There is a second autotrophic type of bacteria, Nitrospira, which grows in our filters and which eats this nitrite(NO2) and converts it to Nitrate(NO3.) Nitrate(NO3), while not a particularly good thing, is much less deadly to fish and can be removed with weekly water changes.
So in fishless cycling, what you're doing is artificially adding ammonia, in the correct concentration (2 to 6 parts per million or so) and maintaining other conditions that are ideal for autotrophic colony growth (84F/28C temp, 8.0 to 8.4 pH, traces of calcium and iron) and then waiting for the slow (3 weeks to 2 months) and unpredictable time period that these two types of bacteria need in order to both reproduce and to outcompete other species of bacteria within the given surface areas that are in the prime ammonia and oxygen areas of the tank (almost entirely inside a correctly working filter.)
Within reason, the bacterial colonies will grow to match the particular ammonia concentration of the water. The concentration of 5ppm has been worked out to be more than the concentration that would be produced by an over-population of a tank, using the one inch of adult fish body per US gallon of tank volume guideline. In all cases it is desirable to have an oversized, over-robust bacterial population that can "drop back" to match the real ammonia output of the actual fish population that is introduced to the tank after the fishless cycle. The bacterial colonies are made of of millions of cells. When the fish population gets smaller (or larger by a reasonably small amount) hundreds of thousands of bacterial cells can die off or can multiply to precisely match the current output of ammonia in the tank environment. This "adjusting" happens without any intervention by the aquarist. I believe this was one of the things you were asking about.
As for your other question, Nitrite(NO2) is nitrogen with two oxygens, Nitrate(NO3) has 3 oxygens. Nitrite is the ion that is much more deadly to fish, whereas nitrate(NO3) is the ion that includes nitric acid as about 7% of its state in water and thus is the substance that can move the tank water in an acid direction during cycling. And you'll recall that the autotrophic bacteria won't die, but will stop their growth process if the pH moves below 6.2 as the water gets more acidic.
In case you're having trouble going to sleep this weekend you can read this post a couple times.
~~waterdrop~~
