Questions dealing with the relative uncertainty in the values computed, stored, or manipulated by Mathematica.

learn more… | top users | synonyms

0
votes
0answers
28 views

Analogue maple's Digits Environment Variable [duplicate]

I want setup (in Mathematica) once and for all operations number of digits after decimal point, similar how it's done in maxima: ...
4
votes
1answer
81 views

How can I completely discard decimals after a set number of significant figures?

I have a number with a long decimal tail, like x=1.23456789789456123 and I would like to (i) keep the first $n$ significant figures, and (ii) completely discard ...
1
vote
1answer
25 views

Passive Transformation does not return the expectedt result due to precision of expressions

So I wish to perform a passive rotation in N dimensional space. Let me take N=5 for this question. ...
7
votes
2answers
170 views

Multiply integrand with -1, and the precision changes?

"After multiplying the integrand of NIntegrate with -1, the Precision of the output will ...
2
votes
1answer
109 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 ...
4
votes
1answer
348 views

How to calculate accurate answer in Mathematica?

I accidentally discovered for myself, that Mathematica outputs inaccurate answer. For instance, if I take $\sin(2 \cdot \pi \cdot 0.5) = 0 $, then in Mathematica it is: But if I calculate it on ...
1
vote
1answer
58 views

Precision in calculation [duplicate]

I am writing some code to demonstrate the effect of the number of significant figures a coefficient has on the solution of a nonlinear equation. I define the coefficient as follows: ...
3
votes
1answer
45 views

My NIntegrate expression returns a wildly inaccurate value

I am trying to integrate a function using NIntegrate: ...
1
vote
0answers
56 views

Artifacts in the solutions of NSolve [closed]

I have (what I think are) some problems with the precision of NSolve. I'm trying to solve this cubic equation: $a f^3(x)-b f^2(x)-c f(x)-z=0$ for the function $f(x)$ and then plot the following ...
1
vote
0answers
41 views

Numerical Integral with Boolean as part of argument

I am trying to numerically calculate a partial surface area integral of an oblate spheroid in spherical coordinates. The area I want to calculate is determined by a boolean function in the argument of ...
1
vote
1answer
40 views

How to preserve real number's precision

RealDigits[523.502] gives me {{5, 2, 3, 5, 0, 1, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9}, 3}. Is there a way in run time to tell ...
2
votes
3answers
189 views

What's the proper way to 'cut out' an irrelevant part of an integral, so I don't run into problems with precision?

I'm doing a numerical integration that involves an integrand with a few exponentials whose values over the integration region range enormously. I'm really only interested in the part of the range that ...
0
votes
1answer
61 views

WorkingPrecision and AccuracyGoal for using with NIntegrate

I'm modeling a quantum tunneling barrier. Because I want to express my quantities in mks units, that means that some of the variables I'm using are pretty small (10^-9). I use NIntegrate for part of ...
0
votes
1answer
50 views

How to set Precision with a variable? [closed]

I get confusing output from the code below. If I put a number after a variable value, the precision gets set just fine. But if I put a variable after the backtick, MMa multiplies the values. Three ...
1
vote
2answers
60 views

Using a rule to increase precision [closed]

I'm sure this is a very simple question, but I can't work out how to do it. Construct a rule to set x=0.32 to a precision of 20 digits. The rule is to be applied ...
1
vote
1answer
79 views

NIntegrate discrepancies

I want to compute a numerical integral for a gaussian trivariate distribution. Say ...
0
votes
0answers
94 views

Why do Precision and Accuracy level off in this calculation?

I am confused by this behavior, where Precision and Accuracy seem to reach a bottom and deteriorate no further as I perform more iterations on this calculation. Have I misunderstood something about ...
0
votes
0answers
21 views

N[variable,2] displays 6 digits [duplicate]

The following code doesn't behave as I expect. Rather than getting 2 digits upon varying r, I get the default value of 6 digits. What's up? ...
2
votes
3answers
81 views

How to set/adjust Precision for an iterative calculation?

How should I restructure this code? I generate a high-order polynomial poly with integer coefficients, then find roots and divide them out of poly one at a time. ...
6
votes
1answer
150 views

Bug in ListPlot?

I want to check if this is a bug before I email WR about it. I can't get ListPlot[] to make scatter plots over a very small area: ...
6
votes
0answers
129 views

Why has Version 10.3 precision reduced?

In version 7.0.1.0 and versions 10.0 and 10.1 the following is produced: ...
0
votes
1answer
63 views

Lack of precision in solar declination leads to odd Fourier result

Here's the sun's declination for a 10 year period (roughly 2000-2010): ...
0
votes
0answers
38 views

Maintaining working precision in my program

I am badly stuck with this program I am writing. I want output of program below to be precise up to 25 digits after decimal point. I am supplying all inputs with precision 25. But after each iteration ...
0
votes
0answers
30 views

How to fill in missing points on a graph? [duplicate]

If I plot the function Plot[Surd[x, 10], {x, 0, 10}, PlotRange -> {{-3, 3}, {-2, 2}}] I get This issue I have is that graph does not extend down to the ...
4
votes
1answer
148 views

A difficult precision problem

I need to calculate values of a highly nonlinear recursive function, and I am confused by the results Mathematica is returning. ...
1
vote
1answer
100 views

How can I increase the precision of my computation?

How can I increase precision up to 15 digits for the results (EC, and that of FindRoot) computed below? ...
2
votes
2answers
110 views

How can I increase the precision of my table?

I want to see first 15 digits for the values in the table computed below. ...
0
votes
2answers
80 views

Exact calculating the multiply of two real [closed]

As the machine calculate,the exact calculating with real number have some problem to puzzle me long time.We know the 0.142*0.36523=0.05186266 is exactly equalized ...
0
votes
1answer
52 views

Why won't something print with desired precision in a while loop?

I have a problem: when I ask something to print with precision P, that is, Print[N[something, P]], it does not print with precision P, just with the usual output precision. In particular, I have a ...
3
votes
1answer
91 views

Is there any way to use compile and still maintain high precision in Mathematica? [duplicate]

Is there any way to use compile and still maintain Arbitrary-precision like 50 in Mathematica?
3
votes
1answer
53 views
13
votes
2answers
535 views

more numerically accurate inverse matrix

I encountered the following matrix mat = {{2, 2.161209223472559` + 1.682941969615793` I}, {2.161209223472559` - 1.682941969615793` I, 2}} and ...
0
votes
1answer
104 views

Precision of Eigensystem? [closed]

I was using Eigensystem to obtain the rotation matrix. However, I find out Mathematica does not fully diagonalize my matrix (or say not precise enough). My matrix ...
1
vote
0answers
77 views
-1
votes
1answer
55 views

Solve Numerical Equation [closed]

I want to find $x\in \ \mathbb{Q} $ such that the first ten digits of $ x \pi $ are 1.234567890. I tried: ...
1
vote
1answer
103 views

Wrong root when using numerical values

I have the following inequality: $$ \sqrt{\frac{a}{2x}}+ \frac{b}{1-\frac{a}{a+\sqrt{a(2bx + a)}}} + \frac{a}{2x\frac{a}{a+\sqrt{a(2bx + a)}}\left(1-\frac{a}{a+\sqrt{a(2bx + a)}}\right)} < f $$ on ...
0
votes
0answers
57 views

Workaround of non-integer indexed objects? [duplicate]

When using indexed object, I found the behavior of value 0.7 as the index quite strange, then did the following test. The first output cell was executed directly as the second input cell. Have not ...
4
votes
1answer
93 views

What is a sufficient decrease in the merit function?

As far as I understand, the merit function measures how far the data is from the fitted function. I am calulcating the second partial derivative of a function, and then numerically finding its maxima ...
11
votes
1answer
115 views

Abnormal behavior of RealDigits[x]

In the Details of the document of RealDigits writes the following line: RealDigits[x] normally returns a list of digits of ...
1
vote
1answer
78 views

Nonlinear 2nd order ODE with regular singularities

I am tring to solve the following ODE with NDsolve $2x~(1-x)~f''(x)+(3-4x)~f'(x)+a~f(x)+b~f^n(x)=0;~~a,b\in\mathbb{R},~n\in\mathbb{N}$. The mathematica "code" is: ...
1
vote
1answer
60 views

Behaviour of RealDigits expected or wrong?

Is this behavior expected or a bug? RealDigits[10304.390456] {{1, 0, 3, 0, 4, 3, 9, 0, 4, 5, 5, 9, 9, 9, 9, 9}, 5} when I ...
7
votes
2answers
258 views

NIntegrate fails to converge under almost any PrecisionGoal, MinRecursion etc. How can I trust the result?

I have been getting some ideas by reading other related questions in the forum, but the integral I have to do is not converging in many cases. The integrand is of the form: ...
0
votes
1answer
58 views

Problem with precision of fraction numbers

I have tried to take a series of harmonic numbers using Mathematica and its precision but there has been an issue. So far when I computed the sums at a whole numbers using a precision of 100 digits I ...
1
vote
0answers
71 views

Problem with calculating Harmonic Numbers

I have tried to take a series of Harmonic Numbers using mathematica but there have been issues in calculations. So far when I computed the sums at a small value range such as ...
1
vote
1answer
83 views

Limited Precision calculation in Mathematica

I apologize upfront for the simple minded question, however i couldn't find an answer in either the Mathematica documentation or Stack exchange. I am trying to explore the effect of finite precision ...
3
votes
1answer
73 views

WorkingPrecision in a sum

If I am interested in getting a fairly precise plot of f2 below, can I use WorkingPrecision to do this? ...
4
votes
1answer
42 views

Failure in use of SetPrecision with Filter

I am working with a narrow band filter and I wish to use a high precision version. The filter is defined using Integers with Laplace variable s. Here is the, rather horrific, equation: ...
1
vote
1answer
67 views

Invoking WorkingPrecision slows down Eigenvalue calculation drastically?

Normally, obtaining eigenvalues of random numerical matrices is fast. For instance a generic result looks like ...
1
vote
0answers
74 views

Odd plotting/math issue (could be a precision problem) [closed]

I've got a pretty odd error on a project I'm working on and was hoping to enlist some advice to fix it. The goal of this notebook is to show that I can eliminate the non-normalizable (blowing up part) ...
1
vote
1answer
72 views

Calculations after NumberForm [duplicate]

As specified in documentation center the functions AccountingForm, NumberForm, etc. are useful only to display numbers in ...