Anti-aircraft warfare
The essence of air defence is to detect hostile aircraft and destroy them. The critical issue is to hit a target moving in three-dimensional space; an attack must not only match these three coordinates, but must do so at the time the target is at that position. This means that projectiles either have to be guided to hit the target, or aimed at the predicted position of the target at the time the projectile reaches it, taking into account speed and direction of both the target and the projectile.

Q: What is the first purpose of air defence?
detect hostile aircraft