Skip to content
本页内容

BesselY (方法)

返回 Bessel 函数,该函数也称为 Weber 函数或 Neumann 函数。

说明

  • 如果 x 为非数值型,则 BesselY 将生成一个错误值。
  • 如果 n 为非数值型,则 BesselY 将生成一个错误值。
  • 如果 n < 0,则 BesselY 将生成一个错误值。
  • 变量 x 的 n 阶 Bessel 函数为:

参数

属性数据类型必填说明
Arg1Any必填计算的函数值。
Arg2Any必填函数的阶。如果 n 不是整数,则将被截尾取整。

返回值

float

示例

python
#本示例为A2等单元格分别赋值,并使用BesselY方法计算并显示结果
def test():
    Range("A2").Value2 = 1
    Range("B2").Value2 = 2
    Range("C2").Value2 = 2.5
    Range("D2").Value2 = 10
    bessely1 = Application.WorksheetFunction.BesselY(Range("C2").Value2, Range("B2").Value2)
    bessely2 = Application.WorksheetFunction.BesselY(Range("D2").Value2, Range("A2").Value2)
    print(bessely1)
    print(bessely2)
python
#本示例使用BesselY方法计算,并将结果赋值于B3等单元格
def test():
    Range("B3").Value2 = Application.WorksheetFunction.BesselY(3, 3)
    Range("B4").Value2 = Application.WorksheetFunction.BesselY(23.5, 4)
    Range("B5").Value2 = Application.WorksheetFunction.BesselY(40.12, 1)