Mathematica 输出格式 [英] Mathematica output formatting

查看:120
本文介绍了Mathematica 输出格式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Mathematica 如何决定何时在其输出中舍入数字?例如,

How does Mathematica decide when to round numbers in its output? For example,

提供输入

250000.5

给出输出

2500001

虽然

25000.5

确实打印为

25000.5

N[] 在这里也没有帮助,我需要使用 NumberForm[] 让它实际将 250000.5 打印为 250000.5

N[] isn't helpful here either, I need to use NumberForm[] to get it to actually print 250000.5 as 250000.5

我是 Mathematica 的新手,我确信当它开始忽略输出中的小数时,控制这个阈值非常容易,但有人可以指出我正确的方向吗?

I'm a Mathematica newbie, and I'm sure its ridiculously easy to control this threshold for when it starts ignoring decimals in its output, but could somebody please point me in the right direction?

推荐答案

在默认的 TraditionalFormStandardForm 输出模式下,Mathematica 只显示一定数量的最高有效数字.您可以使用 InputForm 获取完整的精度数.

In the default TraditionalForm and StandardForm output modes Mathematica only shows a certain number of most significant digits. You can use InputForm to get the full precision number.

这篇关于Mathematica 输出格式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆