Are aircraft equipped with any instruments that measure actual crosswind velocity during a flight? What is that instrument called and is it used by autopilots to apply wind correction?
There is not a specific instrument for this, because it is not directly measurable.
Most modern aircraft have digital sensors for heading and airspeed, and their GPS/IRS will know ground track and ground speed. Any difference between those two vectors will be due to wind, and it’s a simple calculation to determine the wind vector’s direction and magnitude.
In practice, pilots (or autopilots) know the desired track, so we simply adjust where the nose is pointed until the actual track matches the desired one. There’s no need to know the exact winds.
I’ve flown planes with a wind display, and the only thing I really used it for was when practicing engine failures, to maximize glide distance with a tailwind and then minimize landing distance with a headwind. Otherwise, it was for entertainment value only.
Yes, it is called a driftmeter and consists of a telescope aimed straight down at the ground. It has a set of scribed lines projected onto its field of view which the navigator can rotate so the scribes exactly follow the paths of objects on the ground. The navigator then reads off the resulting angle between the plane's axis of motion and the scribe lines. Knowing the plane's airspeed, the navigator then solves the resulting wind triangle to obtain the crosswind component.
This is a simplified explanation; in practice the navigator also needs to know whether the plane is in a tailwind or headwind to solve for the exact value of the crosswind.
Today, radionavigation systems have eliminated the driftmeter from common use.
Not crosswind per-se but wind in general is calculated on-board by comparing aircraft internal data with GPS data. Your aircraft knows it's current heading and most computers can give you a pretty accurate educated guess on your True Air Speed. If you compare both of those with your Ground Speed and Track (this is, the actual lateral flight path of your aircraft) then you know your Drift and the speed difference. This is now simple math. "Aircraft" Vector + Wind Vector = Flight Path Vector so Flight Path Vector - Aircraft Vector = Wind Vector.
Modern airliners have Flight Management Computers that automatically calculate the crosswind component and then apply any necessary course corrections in any Lateral Navigation mode.
Many can also display the current crosswind component.
Airplanes with FMS systems normally display calculated wind direction and speed on the navigation display. It's simply based on the differences in heading vs track, and true airspeed vs groundspeed, worked out within the FMS computer.
You can watch it in action in real time if you fly across a jetstream on a perpendicular track. You will see the heading change several degrees upwind but with little change in groundspeed because the wind is at 90 degrees, but the FMS will calculate the velocity of the jet from TAS and the heading vs track change, and you'll see the wind velocity rise from, say 30kt, to 90 kt or more, with the airplane turning into it to maintain track as you enter the core of the jet, then back to what it was originally when you exit the other side.