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.

Filter by
Sorted by
Tagged with
0 votes
0 answers
33 views

What is happening under this simple calculation? [duplicate]

My Mathematica version is 11.3. Please look at the screenshot. If we add an integer to a number with a finite precision without any spaces, like ...
Keyspire's user avatar
  • 359
0 votes
1 answer
53 views

Delayed evaluation of nested functions

i am new to Mathematica. Here is the situation: I have a exponential function of n,t that I want to calculate integral over t ...
Amin Gholizad's user avatar
0 votes
1 answer
98 views

Exp[-690255.2204176334] is too small to represent as a normalized machine number; precision may be lost [closed]

I'm trying to visualize the relationship of maximum temperature $(T_{m})$ with the heating rate with Randall-Wilkins theory for an energy depth of 0.85 eV. The Randall-Wilkins expression used is ...
D A.'s user avatar
  • 9
0 votes
0 answers
54 views

Overflow + Underflow Problems with Code

I am trying to use Mathematica to verify simulation results with an analytic result. The analytic results are performance measures of the M/D/1 queue, which unfortunately uses the factorial function ...
PiE's user avatar
  • 427
5 votes
2 answers
102 views

Precision problem in DensityPlots

I need to perform a DensityPlot, but the figure is partially displayed. The codes and figure are shown below. ...
user14634's user avatar
  • 771
2 votes
3 answers
100 views

How to modify the given codes (NIntegrate of Boole) to get the most accurate result possible?

I have five conditions con1 to con5 over the two-dimensional domain $t,u\in[o,2\pi]$. I want to compute this area $(con1 \cap con2 )\cup(con3 \cap con4 \cap con5)$ numerically. I try the two codes ...
Martha97's user avatar
  • 349
1 vote
1 answer
52 views

How to modify NIntegrate code below so that it gives the most accurate/reliable numerical result?

Imagine that I have two conditions con1 and con2 over the two-dimensional domain $x,y\in[-2,2]$. I want to compute the area of the union of these two conditions i.e. the region $(con1 )\cup(con2)$. I ...
Martha97's user avatar
  • 349
6 votes
1 answer
349 views

Table does not give expected result with `30 but right with `40

I want Mathematica to generate a table, but I am very confused by its behaviour. tab = Table[i, {i, 6.311, 6.312, 0.001}] Now I get the desired result, namely {6....
Charlotte Myin's user avatar
7 votes
3 answers
432 views

Since when does Mathematica have an 'Inf' symbol?

When I do: ...
berniethejet's user avatar
  • 1,407
2 votes
0 answers
33 views

Working Precision Slowing Down Numerical Integration Computation

...
Smithy's user avatar
  • 31
0 votes
1 answer
96 views

Is there any alternative for conditional plot that gives a more precise result in a shorter time?

I have the given function $Func$ and want to have a plot of those domains where $-3\leq Func\leq 3$ in precise details. I am using ...
Phys96's user avatar
  • 361
1 vote
0 answers
73 views

How to handle "too small to represent as a normalized machine number" when plotting a figure [duplicate]

I am trying to plot a figure by the following codes: Plot[(27 2^((-2 + a)/(-1 + a)) 5^(a/(-1 + a)) 7^(1/(1 - a)) a^2)/((-1 + a) (4 + 9 a)), {a, 1.001, 3}] ...
Ya He's user avatar
  • 150
2 votes
2 answers
252 views

How to prevent Mathematica from rounding some PDF values to 0?

Dear Mathematica community, I'm having a problem with the PDF function for the hypoexponential distribution. Specifically, Mathematica returns 0 as soon as the value is very small. Below is an example:...
user88652's user avatar
0 votes
1 answer
72 views

How to avoid General::munfl errors?

Let's have a look at a following system of equations: ...
kozapdh's user avatar
  • 15
0 votes
1 answer
175 views

Floating point precision and speed [closed]

I am attempting to understand how to speed up the evaluation of numerical expression. Specifically, following the first point of this blog, Mathematica is much quicker dealing with floating-point ...
Patrick.B's user avatar
  • 1,349
9 votes
1 answer
309 views

IntegerPart - is this a known bug?

I'm working in Mathematica 13.0 and I type a=0.00001; IntegerPart[a/a] and well, the output is 0. Try with almost any other value of ...
Davide Venturelli's user avatar
4 votes
2 answers
158 views

Adding numbers with defined precision produces incorrect result

I've tracked a bug in my code down to the problem of adding two numbers together, with the left argument having machine precision, e.g by 3` . The issue is, if ...
shanedrum's user avatar
  • 557
1 vote
0 answers
65 views

Issue with some floating-point errors and not others

Not looking for a solution necessarily, but just trying to understand why this issue occurrs. I have a 'Do' loop which iterates some algorithm over values of a parameter 'x' with range {x,0,1,0.1} and ...
Ssdmitten's user avatar
  • 185
3 votes
1 answer
188 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 ...
YaGoi Root's user avatar
2 votes
2 answers
2k views

Error "is too small to represent as a normalized machine number; precision \ may be lost " for small values in Plot

I'm trying to plot two curves but I'm having issues with the lower end of the range: ...
Rodrigo's user avatar
  • 1,304
0 votes
1 answer
142 views

Spurious poles in a gain plot (due to machine precision or complex numbers?)

I have the following plot that I like to make. It details the gain of an amplifier. ...
kowalski's user avatar
  • 375
4 votes
1 answer
350 views

Real number equality (==) not working: what's the least-overcomplicated solution?

I'm running a program that evaluates equalities after I substitute all symbols for numbers. The equalities on floats are giving me trouble. My program is reaching a point where something like the ...
Lucas Mumbo's user avatar
3 votes
1 answer
143 views

FixedPoint not working, despite quick convergence of sequence [closed]

Trying the computation below, with Mathematica 13.0.0, I am not getting a result returned. FixedPoint[Cos, 0.85] This appears in the 3rd edition of "...
S.V's user avatar
  • 315
1 vote
1 answer
127 views

Exponential fit precision lost

I have a data: ...
Paweł Chmolewski's user avatar
0 votes
0 answers
54 views

How to set up precision by default?

I have a table computing many numbers with large precision. Because of this, probably, Mathematica consumes a lot of RAM. Is it possible to restrict the precision in any calculations by default (...
John Taylor's user avatar
  • 4,984
1 vote
2 answers
46 views

`KernelMixtureDistribution` error message about precision

I want to use KernelMixtureDistribution to deal with a large amount of data points. For example, the following codes shows how I use it: ...
Jie Zhu's user avatar
  • 513
0 votes
0 answers
42 views

Why is the `N` function giving me the wrong result when using WolframScript? [duplicate]

I am using wolframscript.exe to learn mathematica and I would expect the following code to return 0.7071: ...
mbl's user avatar
  • 185
1 vote
0 answers
50 views

plot and limit are not in agreement [closed]

I am plotting the following function $\frac{\sqrt{t \text{$\omega_c $}}-\sqrt{\pi } e^{\frac{1}{t \text{$\omega_c $}}} \text{erfc}\left(\frac{1}{\sqrt{t \text{$\omega_c$}}}\right)}{(t \text{$\omega_c$}...
sined's user avatar
  • 573
0 votes
1 answer
41 views

Indeterminant numerical value of summation

I have the following two-fold summation. ...
Epsilon's user avatar
  • 1,122
0 votes
0 answers
63 views

Mathematica accuracy errors when creating data

I created training data for a neural network and below are two errors I got The only code that uses "FindRoot" command is the following ...
Gabi23's user avatar
  • 295
1 vote
1 answer
153 views

General:munfl error problem

I have the following function, that is the result of The integration between x and some upper limit of a positive function, thus should be positive $f(x,vE) = \frac{e^{-1140.09 x} \left(e^{67945.5 \...
Giorgio Busoni's user avatar
1 vote
0 answers
62 views

How does WorkingPrecision in NDSolve handle MachinePrecision?

I'm wondering why the following code NDSolve[{y''[t] + y[t] == 0, y[0] == 1., y'[0] == 0}, y, {t, 0, 10}, WorkingPrecision -> 6] throws the error/warning, that ...
freddy90's user avatar
  • 851
1 vote
0 answers
43 views

ContourPlot3D with small domain produces glitchy mess

I'm able to plot some graphs over small domains, but not others. For example, this works just fine: ...
ppm's user avatar
  • 61
3 votes
2 answers
177 views

Simplify for precision

I have an a set of equations to solve — details irrelevant — the result of which will be converted into PostScript, a 1980s printer-control language the only floating precision of which is single. ...
jdaw1's user avatar
  • 499
0 votes
0 answers
39 views

General::munfl - Precision lost in LinearModelFit

I am new to mathematica so I am confused regarding the loss of precision in LinearModelFit. In building a linear model with uora (1 or 2) and encodeSeverity (1,2 or 3) ...
Stuart Mackintosh's user avatar
3 votes
0 answers
246 views

How to deal with too small numbers

When dealing with a code that produces too small numbers (in a complicated way) like 0.33691 4.015757066049965*10^-330 I get the following warning General::munfl: ...
S. Euler's user avatar
  • 317
0 votes
0 answers
51 views

Solving a determinant to get non-zero roots in a heat transfer problem

I am trying to solve a mathematical model of a heat transfer problem. As an intermediate step there is a characteristic equation in the form of a determinant, which needs to be solved for variable <...
Avrana's user avatar
  • 297
0 votes
0 answers
92 views

How to change Machine Precision digits to meet the tolerances

I am trying to solve for Tcm and Mag by solving nonlinear equations using FindRoot command using following code: ...
Tiku's user avatar
  • 51
1 vote
0 answers
46 views

Are pixels machine numbers? [closed]

Mathematica allows one to work with the information that is behind a photo. For example, the command ImageData generates a list containing the “pixels” (which will it be a number from $0$ to $1$ if no ...
Air Mike's user avatar
  • 141
0 votes
0 answers
70 views

Problem with the Rank of a matrix after a FindRoot

I am solving a boundary problem defined by a set of four-component vectorial functions. Without going into many details, I have two functions on the left and two on the right of an interface. The ...
Dario Bercioux's user avatar
1 vote
2 answers
96 views

How to increase the value of MinMachineNumber to avoid overflow error?

I have a complicated function called f2[re] ...
Wisdom's user avatar
  • 1,248
0 votes
0 answers
92 views

How to copy and paste numbers with "`" mark and use them in calculations, without using N or setting precision every time

Suppose we have run a calculation and get a number like 2.758952615889003` If we then copy-paste this number and do a calculation like ...
user106860's user avatar
2 votes
0 answers
111 views

Generalizing technique to handle General::munfl error?

In contrast to earlier versions of Mathematica, in versions 11.3 and later Mathematica no longer switches to arbitrary precision when it detects a MachineNumber underflow. While this behavior is ...
Lauren Pearce's user avatar
3 votes
1 answer
89 views

Too small to represent and Chop in inaccessible algorithm

Overview I want to apply a specified Chop function to every step in an function call in Mathematica (in my case LegendreP), ...
Phteven's user avatar
  • 33
0 votes
0 answers
27 views

Different sensitivies from LinearSolve and Eigenvalues. How to conciliate them?

I use the following functions to receive a matrix, and make it symmetric positive definite: ...
An old man in the sea.'s user avatar
2 votes
0 answers
1k views

General:: Exp[-717.401] is too small to represent as a normalized machine number; precision may be lost

I am solving pde. For the post processing bvp, there is solution given in output which is the solution from mathematica version 10.0.1. Output from above in mathematica 10.0.1 is, But when the similar ...
user75507's user avatar
3 votes
1 answer
55 views

Avoid MachinePrecision numbers in Message

Can I change the output of Message to not show MachinePrecision numbers? E.g. ...
Chris K's user avatar
  • 19.3k
1 vote
4 answers
208 views

Can I change the default behavior so that "0.1" is interpreted as "1/10" automatically?

Consider the function f[a_] := NIntegrate[Sqrt[a + Log[x]], {x, 1, 10}, WorkingPrecision -> 30]. With this definition, I cannot call ...
WillG's user avatar
  • 844
1 vote
1 answer
109 views

Machine-precision numbers cause loss of precision

I am trying to use the Mod function as follows. Table[ Nest[Mod[2 #, 1] &, FractionalPart[Pi], n], {n, 100}] // N ...
q than a's user avatar
  • 183
3 votes
3 answers
719 views

How can I compute Erf of large numbers to more precision?

I would like to compute Erf[80/3] to enough precision to know the order of magnitude of 1 - Erf[80/3] How can I do that? I ...
Joe's user avatar
  • 457

1
2 3 4 5