Does not speed of sound actually depend on the frequency and/or amplitude of the waves? If so, why it is constant?
[Physics] Is speed of sound really constant
acousticsdispersionfrequencywavelengthwaves
Related Solutions
Because the frequency of a sound wave is defined as "the number of waves per second."
If you had a sound source emitting, say, 200 waves per second, and your ear (inside a different medium) received only 150 waves per second, the remaining waves 50 waves per second would have to pile up somewhere — presumably, at the interface between the two media.
After, say, a minute of playing the sound, there would already be 60 × 50 = 3,000 delayed waves piled up at the interface, waiting for their turn to enter the new medium. If you stopped the sound at that point, it would still take 20 more seconds for all those piled-up waves to get into the new medium, at 150 waves per second. Thus, your ear, inside the different medium, would continue to hear the sound for 20 more seconds after it had already stopped.
We don't observe sound piling up at the boundaries of different media like that. (It would be kind of convenient if it did, since we could use such an effect for easy sound recording, without having to bother with microphones and record discs / digital storage. But alas, it just doesn't happen.) Thus, it appears that, in the real world, the frequency of sound doesn't change between media.
Besides, imagine that you switched the media around: now the sound source would be emitting 150 waves per second, inside the "low-frequency" medium, and your ear would receive 200 waves per second inside the "high-frequency" medium. Where would the extra 50 waves per second come from? The future? Or would they just magically appear from nowhere?
All that said, there are physical processes that can change the frequency of sound, or at least introduce some new frequencies. For example, there are materials that can interact with a sound wave and change its shape, distorting it so that an originally pure single-frequency sound wave acquires overtones at higher frequencies.
These are not, however, the same kinds of continuous shifts as you'd observe with wavelength, when moving from one medium to another with a different speed of sound. Rather, the overtones introduced this way are generally multiples (or simple fractions) of the original frequency: you can easily obtain overtones at two or three or four times the original frequency, but not at, say, 1.018 times the original frequency. This is because they're not really changing the rate at which the waves cycle, but rather the shape of each individual wave (which can be viewed as converting some of each original wave into new waves with two/three/etc. times the original frequency).
You make several assertions in your "For example" paragraph which simply aren't true. I'm curious as to your sources for these statements, or are they simply a statement you've formed yourself?
If you change only the frequency of a source (constant amplitude), you most definitely change the intensity of the wave, so the level will change. Plus, you are confusing loudness (a psychoacoustic perception) with level (a logarithmic ratio of intensities). To answer your final question: changing frequency with constant amplitude does change the loudness.
What you may seeing in the physics relationships is $$\beta=\log_{10}\left(\frac{I}{I_0}\right)$$ where $\beta$ is the intensity level in units called bels (decibels would be $10\times$ this), $I$ is the intensity of a wave, and $I_0$ is some reference intensity to define a level of $0$ bels.
While you don't explicitly see the frequency in this formula, it's there. It is true that if you have two sources of equal intensity and different frequency, they will have the same level, $\beta$.
Loudness is affected not only by amplitude and frequency, but also by the ear mechanism and the brain. Equal level sounds of differing frequencies have differing loudnesses. You can research Fletcher-Munson curves.
Best Answer
The speed of sound is constant in the same sense that the mass of an object is constant.
In the typical audible range, at frequencies below, like, $100\:\mathrm{kHz}$ and sound pressures much less than atmospheric pressure, the behaviour of air is very well described by a simple linear wave equation that's purely second order in both space and time. As a result, the dispersion is linear ($|k| \propto \omega$), and phase or, equivalently, group velocity is constant.
Much the same in mechanics: whilst nothing moves anywhere near the speed of sound, momentum and speed are related linearly as described by Newton's laws of motion; we call the ratio mass and it's constant.
Not really though: special relativity tell us that when $v$ approaches the speed of light, you can push kinetic energy and thus momentum ever higher by accelerating an object, but it won't become faster to the same degree. One way to look at this is saying the mass increases.
Similarly, when you go to high frequencies, the wavelength shrinks to a range comparable to the material's internal structure. Therefore, you can't really use a differential equation anymore to describe the spatial component; the dispersion becomes more complicated and the speed of sound isn't constant anymore. Or, if the sound pressure is in a similar range as the air pressure, the behaviour becomes nonlinear alltogether, and you get shock-wave phenomena.