Questions tagged [truncation-error]

This tag is for questions relating to truncation error, which is the difference between the true (analytical) derivative of a function and its derivative obtained by numerical approximation.

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

Show that a linear multistep method is of rank $p$ $\Leftrightarrow$ its local trunctation error is equal to 0 for any $x \in \pi_p$

We have the following ODE: $$x'(t) = f(t,x) \quad \wedge \quad x(t_0) = x_0$$ Let's say we have a linear multistep ($q$ steps) method: $$\sum_{j=0}^q \alpha_j x_{k+j} = h \sum_{j=0}^q \beta_j f_{k+j}$...
user avatar
  • 459
0 votes
1 answer
28 views

Finding the Local Truncation Error for the Explicit Euler Scheme

I need to demonstrate finding the LTE for the Explicit Euler scheme when i) $\mu=\frac{1}{6}$ and ii) $\mu\neq\frac{1}{6}$. I have been looking for a reference text/video and I looked at the ...
user avatar
2 votes
0 answers
34 views

Truncation error in solving Differential Equation

Tomorrow I've got a test for my Numerical Analysis course and there's this one type of question I cant seem to understand. An example: We have the Differential Equation $u'(t) = f(u(t))$ and we're ...
user avatar
0 votes
1 answer
94 views

Can the left side of the equation be truncated to the first term?

So, I am deriving a high-order compact finite difference scheme, and got into the equation below: \begin{multline} \delta t^2 \{1 + \dfrac{h^2}{12} (\delta x^2 + \delta y^2 + \delta z^2) + ...
user avatar
0 votes
1 answer
38 views

Computation of global error bound for Euler's formula [closed]

I am trying to calculate the global error bound for Euler's method, but I am having trouble. I am given the formula $|y(t_{i}) - u_{i}| \leq \frac{1}{L}(\frac{hM}{2} + \frac{\delta}{h})(e^{L(t_{i}-a)}-...
user avatar
0 votes
0 answers
64 views

Consistency finite differences vs finite elements

Whether a discretisation is consistent (and the order of consistency) in the FDM setting is defined by the the truncation term, e.g.: $$\partial_{xx} = \frac{1}{h^2}\begin{bmatrix}1 & -2 & 1\...
user avatar
  • 1,748
0 votes
2 answers
48 views

Order of accuracy of $0$

I had to calculate the truncation error, but the error gave me $0$. Then the question asked what is the order of accuracy, however since the error is $0$ should it be infinity? We use this difference ...
user avatar
0 votes
0 answers
14 views

Find the strict bound for the error due to the truncation of an asymptotic series

As you may know, the asymptotic relations $y(t) \sim x(t)$ as $t\to 0$ tells us that $$ \lim_{t\to 0 } \frac{y(t)}{x(t)} = 1. $$ If $x(t)=\sum_i^\infty \epsilon^i z(t)$ is an asymptotic series, then ...
user avatar
  • 7,121
0 votes
1 answer
189 views

Is the Global Error of the Taylor Series Second Order Method $O(h^2)$?

To solve an initial value problem $\frac{dx}{dt}=f(t,x(t))$ with $t\in[t_0,t_N]$, $x(t_0)=x_0$ we can use a Taylor series method of second order, with step size $h$: $$x_{i+1}=x_i+hf(t_i,x_i)+\frac{h^...
user avatar
1 vote
2 answers
110 views

Are expressions including radicals particularly difficult to integrate numerically?

I noticed some unusual result errors when numerically integrating using a TI-84 Plus CE. This answer explains that the TI-84 uses a 15-point Gauss-Kronrod method with a maximum error of $10^{-5}$ to ...
user avatar
  • 2,219
0 votes
0 answers
13 views

Errors for two dimensional Gauss Legendre method

I'm trying to integrate a function $f(\theta,\phi)$ over a unit sphere using Gauss Legendre method. I can find out the integral associated with $N$ points on the sphere. But how do I find the error ...
user avatar
1 vote
0 answers
27 views

Deriving bounds for the remainder of asymptotic series

Given a sequence $(g_m)_{m\geq 1}$ with the asymptotic series $$g_m=\frac{a_1}{m} + \frac{a_2}{m^2} + \frac{R_m}{m^3}$$ where the numbers $a_1$, $a_2$ are known and we know $0<R_m<0.35$. Given $...
user avatar
  • 688
1 vote
2 answers
42 views

How does truncating a series affect "upstream" values in the series?

It is known that truncating the Gregory’s series to 5,000,000 terms leads to an "almost but not quite" value for π: $$ \pi=4 \sum_{k=1}^{\infty} \frac{(-1)^{k+1}}{2 k-1}=4(1-1 / 3+1 / 5-1 / ...
user avatar
1 vote
0 answers
25 views

Relative error of a number in machine epsilon units

I came across an estimation of the relative error between two representations of the same number, one implemented in C++ and another one via a computer algebra program, that was in units of machine ...
user avatar
  • 121
0 votes
1 answer
134 views

Truncation and rounding error bound derivation for finite difference approximation to the first derivative

Finite difference approximation to the first derivative: $$ f'(x)= \frac{f(x+h) - f(x)}{h} $$ Heath's book on Scientific computing Section 1.2.4, Example 1.3 says truncation error for the finite ...
user avatar
1 vote
0 answers
23 views

Stirling's approximation fractional error

Given Stirling's approximation $\ln N!$ is approximated by $N\ln N-N+\frac{1}{2}\ln N$. I want to calculate the fractional error that comes from neglecting the third term $\frac{1}{2}\ln N$ for $N=10$ ...
user avatar
  • 111
0 votes
1 answer
47 views

How to calculate the centered approximation of ${\frac{{df}}{{dt}} = - \frac{f}{\tau }}$?

In the textbook of An Introduction to Computational Methods in Hydrodynamics by Willy Benz. 2.2 Differential Equations. I know how to derive the general formula above $$ f\left( {{x_0} + \Delta x} \...
user avatar
  • 35
1 vote
1 answer
432 views

Local Truncation Error on Improved Euler's Method

I need to reach the conclusion that $$\tau(x,h) = \frac{\phi(x + h) - \phi(x)}{h} - \frac{1}{2}[f(x,\phi(x)) + f(x+h,\phi(x) + h f(x,\phi(x)))] = O(h^2)$$ So I tried using Taylor expansions and ...
user avatar
0 votes
1 answer
80 views

Numerical Methods - Relative Error

In our lectures, we've been looking at relative error and in our recent problem sheet we were asked to prove the following: Let $\hat{x} \neq 0$ be an approximation of a non-zero quantity $x$. ...
user avatar
0 votes
1 answer
24 views

What is the error of FEM-like spline discretizations?

Let's have $f(x)$ a nice*, scalar valued function. It is approximated by $$ f(x)\approx g(x)=\sum_i f(x_i) N_i(x), $$ where $x_i = x_0+i \Delta x$ are uniformly spaced points, $N_i(x) = N(x-x_i)$, ...
user avatar
  • 329
1 vote
0 answers
67 views

Find the local truncation error of the exponential-Euler approximation.

The Problem I have a differential equation of the following form $$\dot{y} = A(y)y+B(y)$$ Provided that $A$ does not depend on $y$ (or depends very weakly on $y$), I can approximate by using the ...
user avatar
0 votes
0 answers
34 views

Truncate a sum in order to speed up an algorithm (Big O)

Let $k\leq n$, I am looking to truncate this sum (with a Big O or Little o) in order to compute just few terms $$ \sum^k_{i=1} (k-(i-1))^{p}\sqrt{y_i} $$ where $y=(y_i)_{i\leq n}$ is a bounded ...
user avatar
  • 460
0 votes
1 answer
125 views

Numerical analysis - Error analysis for the second order Taylor method

I'm trying to prove the following result for the second order Taylor method: $f$ is continuous and satisfies a Lipschitz condition with constant L on $D=\{(t,y)\mid a\leq t \leq b, -\infty<y<\...
user avatar
  • 431
0 votes
1 answer
53 views

Simple loss of significance question.

I know that (because of the finiteness of computer arithmetic) for large values of $x$, the function $$f(x)=\log(x+1)-\log(x)$$ will be subtracting two very close values. Can I get around this by re-...
user avatar
  • 1,114
0 votes
3 answers
233 views

Forward and centered finite difference give same error plot: why?

Let us consider the following standard approximations of the first derivative of a function $$FD = \frac{f(x+h)-f(x)}{h}$$ $$CFD = \frac{f(x+h)-f(x-h)}{2h}$$ The first is first order accurate, while ...
user avatar
  • 675
0 votes
0 answers
36 views

What factorial number to get a good approximation of the matrix exponential?

$$e^X = \sum_{k=0}^N{1 \over k!}X^k$$ Assume that $X \in \Re^{nxn}$ is random matrix. What number $N$ should I use to get a good accuracy compared if $N = \infty$? Is this possible to measure?
user avatar
  • 2,497
0 votes
0 answers
60 views

Relative error from truncation error in Taylor series expansion

Given the function $f(x)=\sin x$, please expand it about $x=0$ using Taylor series and truncate the series to $n=6$ terms then find the relative error at $x=\pi/4$ due to truncation found?
user avatar
0 votes
2 answers
42 views

Closely minimize error bound $\frac{4 \pi \exp(\cosh(a))}{\exp(a N) -1}$

I'm trying to minimize an error bound $$\frac{4 \pi \exp(\cosh(a))}{\exp(a N) -1},$$ where $N$ is the step size for the trapezoidal rule and $-a < Im < a, a > 0$ is a strip bound which may ...
user avatar
1 vote
1 answer
120 views

forward - backward differencing = central differencing

From Taylor series, we can derive: Forward Differencing Formula: $$ f'(x_{i}) = \frac{f(x_{i+1}) - f(x_{i})}{h} - \frac{f''(x_{i})h}{2!} $$ $$\tag 1 f'(x) \approx \dfrac{f(x+h)-f(x)}{h}$$ (1) ...
user avatar
  • 169
0 votes
2 answers
72 views

Approximate the integral $\int_0^{0.5}{x^2e^{x^2}}dx$ correct to four decimal places using a Maclaurin series.

I got $$\int_0^{0.5}{\sum_0^\infty}\frac{x^{2n+2}}{n!}dx$$ for the taylor series representation, but I'm not sure what to do next. Do I use 0 and 0.5 as bounds for z for the Lagrange Error Bound? And ...
user avatar
1 vote
0 answers
105 views

The numerical solution of Van der Pol's equation does not show chaotic behavior as expected.

I post this question again with more details : For a bachelor's work we have to study the chaotic behavior shown in the numerical solution of the driven van der pol oscillator as a function of the ...
user avatar
  • 11
1 vote
1 answer
377 views

Finding an upper bound for the local error with the Euler method

This is not about a particular problem but more a question about how to best approach this kind of problem. I'll give three examples and my approach to them. Problem 1 $$ y' = 2y - 5 \sin(t)$$ $$ y(...
user avatar
2 votes
1 answer
94 views

Order of accuracy for non-smooth solutions and non-smooth local truncation errors

I'm working with numerical methods for solving PDEs (Linear Advection/Euler equations with temporal and spatial discretisation) using finite difference/finite volume methods. In these simulations I ...
user avatar
0 votes
1 answer
42 views

Bounding the error for the remainder of $\log(x)$

We are asked to bound the error given by the remainder of the Taylor series of $\log(x)$ about some point $a>0$. Using the remainder as: $$R_n = \frac{f^{(n+1)}(\xi)}{(n+1)!}(x - a)^{n+1} $$ and ...
user avatar
2 votes
1 answer
167 views

Global Error Bound for Implicit Euler

I'm trying to derive an error bound for the approximate solution obtained with Backward Euler to the IVP $$\frac{dy}{dt} = f(y), \hspace{.75cm} y(0) = y_0,$$ where $f \in C^2(\mathbb{R})$ with ...
user avatar
  • 331
3 votes
2 answers
696 views

Calculating the truncation error for exponential function in complex plane

Having seen this question on Taylor approximation of complex exponential function, I am looking for a solution this problem and would be great if I also knew the name of the paper. It is about ...
user avatar
  • 159
0 votes
0 answers
49 views

Nummerical truncation on MATLAB - Increase of precision

It might be not suitable for the current forum, but it is math-related. Than, I wonder if there is a MATLAB user among us. I currently implement multible degrees of Runge-Kutta methods on mentioned ...
user avatar
2 votes
1 answer
55 views

How do I avoid significant rounding error in evaluating $(\ln(x) - \sin(\pi x))(1-x)^{-1}$?

How do I avoid significant rounding error in evaluating $$\frac{\ln(x) - \sin(\pi x) }{1-x}$$ This function causes error as $x\to 1$. How can this be avoided? I tried using taylor's expansion but I ...
user avatar
0 votes
1 answer
177 views

A minus sign on the truncation error: Crank-Nicolson method for a diffusion equation with consume

I was studying by first time truncation error on finite schemes and the author of the article I am studying states the equation: $u_t=u_{xx}-1$ and the truncation error $T_m^{n+1}=\dfrac{\...
user avatar
  • 1,205
0 votes
1 answer
29 views

Given an analytic function can I derive to what precision I need to evaluate its arguments to get a result of a given precision?

Suppose I have some arbitrary analytic function over the reals e.g.: $$ x \mapsto \frac{\sqrt{\sin(x)+2e^x}}{x^2 - \ln(x^x)} $$ Given some input of arbitrary precision $x$ how can I evaluate such an ...
user avatar
0 votes
1 answer
140 views

Confusion regarding order of error/truncation notation for iterative methods

I am confused as to the meaning of the $O(h)$ notation used to denote error associated with an iterative algorithm (for example RKF45 has an local error of order $O(h^5)$) The general template for ...
user avatar
0 votes
0 answers
20 views

Error Analysis for a Fraction

Suppose I have the following functions $f(x)$ and $g(x)$, such that: $$ f(x) = \tilde{f}(x) + O(x^{-p}) $$ $$ g(x) = \tilde{g}(x) + O(x^{q}) $$ where $p,q \in \mathbb{Z}_{++}$ and f,g are positive ...
user avatar
1 vote
1 answer
122 views

How do I interpret my error graph?

I wrote an RK4 algorithm and am testing it on $y' = -ty$ which has the solution $y(t) = e^{-t^2 / 2}$ I decided to also graph the error, which I am now trying to decipher. I plotted the solution and ...
user avatar
0 votes
1 answer
42 views

proof: upper bound error of approximating a number with only $n$ decimals precision

Suppose you have a real number $A$ and approximate it by only $n$ decimal places. Call this number $a$. proof that the upper bound of absolute error of this approximation $|A-a| \le 5 \times 10^{-(n+1)...
user avatar
1 vote
1 answer
77 views

Truncation error

I wonder if the truncation error that I derived in the following approximation really has order 2? If so I also wonder what happens to the $u_{xxxx}$ term since it does not cancel out? $$u^n_{j+2}-4u^...
user avatar
0 votes
1 answer
113 views

How to prove finite difference approximation has error of order $\mathcal{O}(\Delta x^2)$

I'm asked to prove that the finite difference approximation $$u_{xx}(x_i) = \frac{u_{i+1} - 2u_i + u_{i-1}}{\Delta x^2}$$ gives a discretization error of order $\mathcal{O}(\Delta x^2).$ My attempt: ...
user avatar
1 vote
1 answer
243 views

maximum error when rounding off multiple times

So I am aware that when you round to n decimal places accuracy, the maximum error is $~0.5 × 10^n~$ But if I use the rounded result, and use multiply it by another un-rounded number and round the ...
user avatar
1 vote
0 answers
146 views

Truncation error and non self-starting Heun

I've seen two different truncation formulas for the midpoint rule. A common one is $h^3 \frac{ f''}{24}$. Another, referred to as open Newton Cotes, is $h^3 \frac{f''}{3}$. The Newton Cotes ...
user avatar
  • 11
1 vote
1 answer
73 views

Truncation error when applying a finite difference scheme to solve $u_t +Au_x = 0$

The wave equation in one space dimension is given as $$ u_t + Au_x = 0 $$ where $$ u := \begin{bmatrix} v(x,\, t) \\ w(x,\, t) \end{bmatrix}, \quad A = \begin{bmatrix} 0 & -1 \\ -1 & 0 \end{...
user avatar
0 votes
0 answers
47 views

Bounding the error in a solution, to an IVP, produced by RK4.

What techniques exist for bounding the error in a solution, to an IVP, produced by RK4? The below problem is intended to contextualize the question. Problem The $x$, $y$ and $z$ axes of a coordiante ...
user avatar