Labfans是一个针对大学生、工程师和科研工作者的技术社区。 论坛首页 | 联系我们(Contact Us)
MATLAB爱好者论坛-LabFans.com
返回   MATLAB爱好者论坛-LabFans.com > 工程数学软件 > Mathematica论坛
Mathematica论坛 Mathematica是比较流行的符号运算软件之一
回复
 
主题工具 显示模式
旧 2014-10-16, 07:16   #1
allendingjun
初级会员
 
注册日期: 2008-08-18
年龄: 42
帖子: 1
声望力: 0
allendingjun 正向着好的方向发展
默认 请求帮忙解释一下这一小段程序

要重新定义一个反三角函数(如下):

arcCos[z_, i_] := Block[{x = Re[z], y = Im[z], y0},

If[i == 1, arcCos["s"] = 1; arcCos["n"] = 0,
y0 = Im[arcCos["last arg"]];

If[(Min[y0, y] < 0 <= Max[y0, y] \[And]
x < -1) \[Or] (Min[y0, y] <= 0 < Max[y0, y] \[And] x > 1),
arcCos["n"] +=
arcCos["s"] Round[(ArcCos[z] + ArcCos[arcCos["last arg"]])/(
2 \[Pi])]; arcCos["s"] = -arcCos["s"]]];
arcCos["last arg"] = z;
arcCos["s"] ArcCos[z] + 2 \[Pi] arcCos["n"]
]

请问其中 (1)["last arg"]是什么意思?(2)第一个 if 管到哪里?
如果有谁能详细解释一下这段程序最好了,谢谢~~
allendingjun 当前离线   回复时引用此帖
回复


发帖规则
不可以发表新主题
不可以发表回复
不可以上传附件
不可以编辑自己的帖子

启用 BB 代码
论坛启用 表情符号
论坛启用 [IMG] 代码
论坛禁用 HTML 代码



所有时间均为北京时间。现在的时间是 07:39


Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.