以小写字母开头的危险符号名称
我正在寻找 Mathematica 中以小写字母开头的危险符号名称的完整列表。
目前我知道三个这样的名字:min
、max
和lim
。这些名称显示在 LimitsPositioningTokens
列表中,并且 至少在使用上标在前端输入时被视为运算符:
In[3]:= Options[$FrontEnd,LimitsPositioningTokens]
Out[3]= {LimitsPositioningTokens->{\[Sum],\[Product],\[Intersection],
\[Union],\[UnionPlus],\[Wedge],\[Vee],lim,max,min,\[CirclePlus],
\[CircleMinus],\[CircleTimes],\[CircleDot]}}
例如,在前端中键入以下内容(使用 Ctrl+^ 制作上标- 这很重要!):
In[1]:= max^n+4
(max^n+4)//HoldComplete//FullForm
Out[1]= 4 max^n
Out[2]//FullForm= HoldComplete[Times[Power[max,n],Plus[4]]]
您会看到 max^n+4
被解释为在这种情况下4*max^n
。
谁能解释一下 LimitsPositioningTokens
选项的真正作用吗?
Mathematica 中是否还有其他以小写字母开头的危险符号?
I am looking for a full list of dangerous symbol names that begin with a lowercase letter in Mathematica.
At this moment I know three such names: min
, max
and lim
. These names appear in the LimitsPositioningTokens
list and are being treated as operators at least when they are entered in the FrontEnd with a superscript:
In[3]:= Options[$FrontEnd,LimitsPositioningTokens]
Out[3]= {LimitsPositioningTokens->{\[Sum],\[Product],\[Intersection],
\[Union],\[UnionPlus],\[Wedge],\[Vee],lim,max,min,\[CirclePlus],
\[CircleMinus],\[CircleTimes],\[CircleDot]}}
For example, type in the FrontEnd the following (use Ctrl+^ for making superscript - it is important!):
In[1]:= max^n+4
(max^n+4)//HoldComplete//FullForm
Out[1]= 4 max^n
Out[2]//FullForm= HoldComplete[Times[Power[max,n],Plus[4]]]
You see that max^n+4
is interpreted as 4*max^n
in this case.
Can anyone explain what LimitsPositioningTokens
option really does?
Are there other dangerous symbols that begin with a lowercase letter in Mathematica?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我无法确认您报告的问题。此外,您找到的标记似乎是字符串而不是符号。
这是在 win7-64/M8.0.1 上,我妻子的 mac lion/M8 不显示它任何一个。
它们是字符串这一事实似乎与
LimitsPositioning
文档页面上的描述一致那里给出的所有示例都使用字符串。
更新以说明下面评论中提出的观点
这是 $FrontEnd 中的标准
LimitsPositioningTokens
设置:这是使用
SetOptions[$FrontEnd, LimitsPositioningTokens -> {}]
:请注意,SetOptions 中的 $FrontEnd 设置是粘性的. 您的系统可能不再处于默认状态。使用选项检查器将
LimitsPositioningTokens
返回到其默认值(在全局设置打开的情况下搜索LimitsPositioningTokens
并删除变量旁边的叉号(如果有))。I cannot confirm the problem you report. Besides, the tokens you've found seem to be strings rather than symbols.
This is on win7-64/M8.0.1, my wife's mac lion/M8 doesn't show it either.
The fact that they are strings seems to be consistent with the description on the doc page of
LimitsPositioning
All examples given there use strings.
Update to illustrate the point made in the comments below
This is with the standard
LimitsPositioningTokens
setting in $FrontEnd:and this is with
SetOptions[$FrontEnd, LimitsPositioningTokens -> {}]
:Please note that the $FrontEnd setting with SetOptions is sticky. It is likely that yours isn't at default anymore. Use the option inspector to return
LimitsPositioningTokens
to its default value (search forLimitsPositioningTokens
with Global Settings on and remove the cross next to the variable if there is any).