function IncDecF = NED2IDF(NEDVector)
%NED2IDF  Transform NED-data to IDF-data (in grad and microteslas).
%Usage: IncDecF = NED2IDF(NEDVector)
    
       TO_GRAD=180.0/pi;
       IncDecF=0.0*NEDVector;
       
       IncDecF(3)=norm(NEDVector);
       if IncDecF(3) <= 0.0
            return;
       end
       
       IncDecF(1)=asin(NEDVector(3)/IncDecF(3));
       IncDecF(2) = acos(NEDVector(1)/(IncDecF(3)*cos(IncDecF(1))))*TO_GRAD;
       if NEDVector(2) < 0.0
           IncDecF(2) = -IncDecF(2);
       end
       IncDecF(1) = IncDecF(1)*TO_GRAD;

       return
 
