# Questions tagged [machine-precision]

For questions on the use of machine-precision real numbers (also known as floats), the numbers that can be directly manipulated through the underlying numerical capabilities of your computer system.

233 questions
Filter by
Sorted by
Tagged with
122 views

### Make mathematica "forget" numbers beyond the precision goal

I need Mathematica to remember only things upto two decimal places. I'm currently using the unwieldy Floor[x*100]/100 which works but is there a better way to ...
• 259
360 views

### How to handle very numbers that are "too small to represent as a normalized machine number"?

I will preface this by saying that I am not very familiar with Mathematica whatsoever. That is why I am asking this here even though I have found a few forum posts that might provide the solution to ...
145 views

### Forcing divisions to be a machine-precision floating point divisions instead of multiplication by inverse

I want to imitate machine-precision, de facto IEEE division on Mathematica. On my quick trials I find this surprisingly hard to accomplish, since Mma rewrites a / b ...
• 19.1k
3k views

### Truncate a number in mathematica

I want to truncate a simple number to n decimal digits. For example, 2/3. I used f[x_, n_] := N[IntegerPart[x 10^n]/10^n] but I get ...
• 55
151 views

### Numerical precision problem

I have this simple code: ep = 1 - 80000000000 (-(199999/200000) + 1/E^(1/200000)) ep // N -8.27404*10^-8 ...
141 views

### Copy-paste with annoying trailing 0s

When one copies an output containing machine-precision numbers to a input, many trailing 0s appears. For example : Evaluate the following expression : ...
• 18.7k
708 views

### Mathematica Precisions vs Doubles in C/C++

I'm having a bit of an issue regarding numerical precision and I'm not sure how to deal with it. I have a certain randomly generated matrix, say $M$, that I wish to compute the eigenvalues. The ...
• 147
1k views

### NIntegrate 2D highly oscillatory function

I am trying to integrate a function, and the error I get is greater than the result. So I need to calculate ...
• 33
343 views

### WorkingPrecision causes issue in the NIntegrate

I really can't figure out why my code sometimes is not working. My integrals involve two variables (k and kz). The integration ...
169 views

### Why does precision decrease after increasing PrecisionGoal and WorkingPrecision on this integral?

I am trying to calculate a messy double-integral to many digits of precision. As shown below, the precision seems to increase reliably as WorkingPrecision goes from ...
• 1,000
100 views

### problem in matching two sets of particles

I have been trying to simulate a simple system in which there are two set of particles. One kind of particles are localized on the boundary of a circle (shown in purple below), whereas the second kind ...
• 9,030