0

在 Matlab 中是否有任何函数可以返回 Airy 函数的零点?

我正在使用 Matlab 7.11.0。

谢谢!

4

1 回答 1

1

您可以使用此功能:

function a = airyZeros(N)
#AIRYZEROS Computes the first N zeros of the Airy function
#
#    Example
#       >> airyZeros(3)
#       ans =
#          -2.3381   -4.0880   -5.5206

    a = NaN(1,N);

    for n = 1:N
        switch n
            case 1
                x = -2.3381;
            case 2
                x = -4.08795;
            case 3
                x = -5.52056;
            case 4
                x = -6.7867144;
            case 5
                x = -7.94413;
            case 6
                x = -9.02265;
            otherwise
                x = -(3*pi/2 * (n-0.25))^(2/3);
        end

        a(n) = real(fsolve(@airy, x, optimset('display','none')));

    end

end
于 2013-03-27T14:08:54.423 回答