Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [numerical-calculus]

The tag has no usage guidance.

0
votes
1answer
27 views

How do you compute relative error when the exact solution is unknown?

I'd have a rather complex system of non linear ODEs and with a lot of help I've written an algorithm that solves them. I'd now like to compute the relative error, but I do not have a known solution to ...
0
votes
0answers
26 views

Floating-point rounding error in numerical differentiation formula

In Numerical Analysis by Timothy Sauer (Pearson, 2nd Edition) it says that $\tilde{f'}(x+h) = f(x+h) + \epsilon_{\text{mach}}$, where $\tilde{f'}(x)$ is the floating-point representation of the given ...
0
votes
0answers
18 views

Numerical Double Integration with inverse over inner integral failing using common methods and inbuilt functions

Implementing a paper, I want the value of this double integral which has endpoint singularities in both integrals. $\int_0^{\inf} \frac{1}{w} Im( 0.5^{-iw}({12{\int_0^1 (1 - (0.5+\frac{0.5} {1+by^\...
0
votes
1answer
18 views

Numerical integration of a function with several parameters

I would like to thank in advance anyone willing to take a look at my question. I am asking whether there exists a method which can be used to numerically evaluate an integral of a function containing ...
0
votes
0answers
17 views

Lax Equivalence Theorem

I learned about Lax Equivalence Theorem in the context of numerically solving PDEs. Now I am doing a little research project that involves solving a system of non-linear ODEs. I know RK methods work ...
2
votes
1answer
41 views

weights of Gaussian quadrature rule, numerical integration, reference request

The weights $A_j$ of the Gaussian quadrature rule are positive and furthermore it is $A_j=\int_a^b w(x)\prod_{i\neq j} \left(\frac{x-x_i}{x_j-x_i}\right)^2$ I am searching for a reference on the ...
3
votes
1answer
33 views

Midpoint rule, error estimation for $f\in C^2$

Let $I(f)=\int_a^b f(x)\, dx$. The midpoint rule (open Newton-Cotes for $n=0$) is $I_0(f)=(b-a)f(\frac{a+b}{2})$ Show: For $f\in C^2([a,b])$ holds $|I(f)-I_0(f)|\leq \frac{(b-a)^3}{24}\|f''\|_\...
1
vote
1answer
33 views

Midpoint rule, error estimation, $|I(f)-I_0(f)|\leq\frac{(b-a)^2}{4}\|f'\|_\infty$

Let $I(f)=\int_a^b f(x)\, dx$. The midpoint rule (open Newton-Cotes for $n=0$) is $I_0(f)=(b-a)f(\frac{a+b}{2})$ Show: For $f\in C^1([a,b])$ holds $|I(f)-I_0(f)|\leq \frac{(b-a)^2}{4}\|f'\|_\...
0
votes
0answers
18 views

Visualization of solution of one dimensional Heat Equation

The one dimensional heat equation for a long rod is given by $\frac{\partial T}{\partial t} = D\frac{\partial^2 T}{\partial x^2} $, where $D>0$. Let us say a rod of Aluminium of length $l_1$ (...
0
votes
0answers
22 views

Numerical solution of a 1st order PDE

I tried to solve numerically this problem $$ \begin{cases} u_x+3u_t=x\\ u(0,t)=3t^2 \end{cases} $$ Firstly, I solved it analitically, in order to have also the exact solution, that is $$u(x,t)=\...
1
vote
1answer
28 views

Question about the FFT version of the gradient of a function.

We know that for a sufficiently smooth function $f:\mathbb{R}^{3}\to\mathbb{R}$, its Fourier Transform $\hat{f}(\mathbf{k}) \colon= \mathcal{F}\{f\}$ should satisfy (using integration by parts): $$\...
0
votes
1answer
40 views

Euler's method example: Where this value came from?

So, i've found an example that suits what i want to do, and i understood the majority of it, but i didn't really figured out where the last value, of the last line came from. I wanna know where did ...
0
votes
1answer
36 views

Adams-Bashforth algorithm

So i got a project and I've been trying to solve it, but I just don't know how to start, and I haven't found an example similar to this one. So if you could guide me a little bit I would really ...
0
votes
0answers
12 views

Roots of a n-variable non linear function with numerical methods

Currently I am working with finding the solutions for the following problem: I have a unit sphere in which I have n points defined by their polar and azimuthal angles: $\theta_n , \phi_n$. I then do ...
0
votes
1answer
35 views

Can someone help me numerically integrate some integrals involving quotient and $\sin(x)$?

I am trying to numerically integrate the following integrals ($*$ is multiplication symbol): (1) $$ \dfrac{1}{4}\dfrac{\sin(\pi y) - \sin(\pi x)}{y - x}*\dfrac{(\sin(\pi x)*y - \sin(\pi y)*x)}{y - x}$...
0
votes
1answer
46 views

zeros and convergence or divergence in iterations

I'm solving some numerical analysis exercises and I still can not find a way to solve the following Consider the function $f (x) = x^3 - x - 1$. For the equation $f (x) = 0$ answer the following: . ...
1
vote
0answers
35 views

Numerically find the function that maximise a probability

I have a sample consisting of $N$ data for the function $$g(\nu) = \int\limits_0^{\infty} \cos{\left(\nu x\right)} f(x) \,\mathrm d x$$ and I want to solve the integral equation for $f(x)$ ...
0
votes
1answer
27 views

Pseudoinverse of pseudoinverse of matrix A equals A: ${(A^{+})}^{+}=A$

As you know, a Matrix $A^{+}\in \mathbb{R}^{m\times n}$ is called a a pseudoinverse of $A\in \mathbb{R}^{n\times m}$ if $\Vert b-A A^{+} b \Vert_2\leq\Vert b- A y\Vert_2 \forall b\in \mathbb{R}^{n} \...
0
votes
1answer
26 views

What should be the maximum value of $h$ so that the upper bound of

What should be the maximum value of $h$ so that the upper bound of the error of approximated value of $\int \dfrac {dx}{x^2}$ using Composite Trapezoidal Rule is within $10^{-3}$? The limit of ...
1
vote
1answer
55 views

Simplify this expression with divided differences.

The divided differences are defined as follows $$ f[x_i] := f(x_i), \quad f[x_0, \ldots, x_n] := \frac{f[x_1, \ldots, x_n] - f[x_0, \ldots, x_{n - 1}]}{x_n - x_0} \quad \text{for } n \ge 2 $$ For ...
1
vote
4answers
54 views

Find $x_{50}$ quadratic equation

I don't really know how to title this question You are provided the quadratic equation $ax^2 + x -1 = 0$ with a root $x$, with formula $x= \frac{-1+\sqrt{1+4a}}{2a}$ for each $a = 2^{-p}$,...
0
votes
0answers
23 views

numerical method for no linear problem

can you help me please to program with FreeFem++ the Following non linear problem: $$ \dfrac{\partial u}{\partial t} - \Delta u + F(u)= f(x,t), \ x \in (0,1)^2, t \in [0,T] $$ where $F$ in non linear ...
1
vote
2answers
37 views

Integration of the multiplication of normal cdf and exponential function

I have to find the integral of $$\int_{M_0}^{\infty} q(m, \mu, \sigma) \beta e^{-\beta(m-M_0)}\,\mathrm{d}m,$$ where $q(m, \mu, \sigma)$ is the normal cumulative distribution function, $M_0$ is a ...
1
vote
2answers
62 views

Composite trapezoidal rule's error term representation has $k_1h^2 + k_2 h^4 +… $ to apply Romberg integration

I am trying to apply the Romberg method but when trying to evaluate the Error, I can't eliminate the appearance of the term $\frac{1}{12}f^{(3)}(\psi)h^3$, When I wish to get $E = K_1h^2 +K_2h^4 +K_3 ...
0
votes
0answers
37 views

How should I approach this exponential interpolation problem?

Here is the question I am stuck on part b) of this problem from my numerical analysis class. I think I am supposed to construct a matrix and show that it is linearly independent but I am not sure ...
1
vote
1answer
39 views

Approximate $f''(x)$ given $f(x),f(x+h),f(x+3h),f(x-5h)$

Given $f(x),f(x+h),f(x+3h),f(x-5h)$, approximate $f''(x)$. Book's solution: From Taylor' series, $$ \\ f(x+h)=f(x)+f'(x)h+0.5f''(x)h^2+{1\over6}f'''(x)h^3+O(h^4) \\ f(x+3h)=f(x)+3f'(x)h+4.5f''(x)h^2+...
0
votes
0answers
26 views

Matrix Numerov Method in three dimensions

Hi can anybody help me to write the following equation in form of matrix by using Numerov's method. $\left(\frac{d^2}{d x_1^2}+\frac{d^2}{d x_2^2}+\frac{d^2}{d x_3^2}+x^2_1+x^2_2+x^2_3+x_1x_2+x_2x_3+...
1
vote
1answer
29 views

If the initial points for secant iteration method are sufficiently close to the root, the iteration converges to the root

Well I wish to prove that in case I may choose $x_0,x_1$ close enough to the root $a$ of $f(x)$, then the secant method $x_{n+1} = x_n -\frac{x_n -x_{n-1}}{f(x_n)-f(x_{n-1})}f(x_n)$ converges to the ...
1
vote
0answers
59 views

Does Aitken's $\Delta^2$ method asymptotically improve rate of convergence?

Denoting $y_n = x_n-\frac{(x_{n+1}-x_n)^2}{x_{n+2}-2x_{n+1} +x_n}$ when $x_n\rightarrow_{n\rightarrow\infty} a $ with $p$ convergence order. I showed that $\lim_{n\rightarrow\infty} |\frac {y_n-a}{...
0
votes
0answers
29 views

Is the product of two “sample” matrices a sample matrix?

Let $f,g \colon \mathbb R^2 \to \mathbb R$ be two smooth functions. Take a uniform, square grid of the unit cube in $\mathbb R^2$ and let $\{p_{ij}\}_{i,j=1, \ldots, L} \subset \mathbb R^2$ be the ...
0
votes
1answer
24 views

Is a function with these conditions both convex and concave?

Let $f : [a,b] \to \mathbb{R}, f‘(x)>0, f‘‘(x)<=0, f(a)<0<f(b)$, so f is strictly monotonous increasing and concave. Also let f satisfy $b-\frac{f(b)}{f‘(b)} >= a$. Is f a straight ...
0
votes
0answers
33 views

Romberg-Integration relative error

How can I check if the relative error of two successive diagonal elements is smaller than e.g. $10^{-3}$? $\left\vert \frac{T_{1,2}-T_{1,3}}{T_{1,3}}\right\vert<0.001$ for a Romberg Tableau of ...
0
votes
0answers
132 views

Advantages and disadvantages of the Golden-section search method

As I understand that the golden-section search is a zero-order line search method so it is a global method so in comparison with Newton's and the secant's method this is an advantage. But it has a ...
1
vote
1answer
43 views

First derivative approximation using function values in equidistant points

Given a function $f: [x_0,x_4] → \Bbb R$ and equidistant points $x_0, x_1, x_2, x_3, x_4$ so that $h=x_{i+1} - x_i > 0$. Normally I would do, $f'(x) \approx \dfrac{f(x+h)-f(x)}{h}$, but here I ...
0
votes
1answer
29 views

On highest degree of precision of numerical integration scheme that comes from interpolating polynomial

Let $x_1,...,x_n$ be distinct points in $[a,b]$ and $l_i(x):=\prod_{k\ne i}\dfrac {x-x_k}{x_i-x_k} $. Let $w_i=\int_a^b l_i(x)dx$. For every $f \in C[a,b]$, let $I_n(f):=\sum_{i=1}^n w_i f(x_i)$. ...
2
votes
0answers
58 views

How to improve the convergence of a stochastic differential equation?

I have a stochastic differential equation, i.e, $$ d\rho_t= \hat{A} \rho_s dt + \hat{B} \rho_s \nu dt + \hat{C}\rho_s\omega_{1t} dt + \hat{D}\rho_s \omega_{2t}dt \quad , \quad t>s $$ Here A, ...
2
votes
4answers
149 views

Finding general solution to DE subject to initial condition

How do we solve the following Differential Equation? $$2 x''' + xx'' =0$$ Subject to conditions: $$ x(0)=0$$ $$ x'(0)=0$$ $$ x'(\infty)=1$$ Is there any numerical method to solve it or some ...
0
votes
0answers
12 views

Solution of Transcendental equations, trigonometric ones

I am studying vibration of beams, with continuous properties; and I arrived to some kind of trascendental equations. The book I am using, (Chopra, 2014), says that one of the solution is the numerical ...
0
votes
0answers
32 views

backward propagation of errors

Suppose we have $L-1$ time intervals between $t_0$ and $t_{L}=T,$ i.e., $t_0<\ldots<t_l<\ldots<t_{L}=T.$ We have an error $e_{t_l}$ describing the absolute error difference between a real ...
1
vote
1answer
21 views

Bounding at Newton Divided Difference Formula

Let $a=x_0,x_1,...,x_n=b$ are $n+1$ points which are equally spaced in $[a,b]$. The distance between consecutive terms is $h= \frac{b-a}{n}$ and $x \in [a,b]$ Show that $ \biggr|\prod_{i=}^n (x-x_i) \...
0
votes
0answers
14 views

propagating error analysis

Tutor asked me a question about propagating error analysis: Here is the question: if for $t_0<t_1<\ldots<t_{l}<\ldots<T,$ $$e_{t_1}\leq e_1+e_2e_{t_{l+1}}+e_3,$$ and $$e_{T}\leq e_1+...
1
vote
0answers
47 views

How to program numerical integration $\int_t^{\infty}\frac{1}{(u+1)^2}du$?

I'm facing a problem when program the numerical integration of $\int_t^{\infty}\frac{1}{(u+1)^2}du$, I know that the true value is $\frac{1}{1+t}$, however, when I want to calculate the definite ...
0
votes
2answers
31 views

Obtaining expression for recursive sequence

Can someone suggest how to obtain an expression for $S[i]$ given that S[0] = 0, $S[i]=S[i-1]*(1-\gamma_i)^2 + \gamma_i^2$ where $\gamma_i = \frac{g+1}{g+i}$ EDIT: $g>0$ and $g$ can be assumed to ...
0
votes
1answer
19 views

Numerical Change of Variables

If I have $f(x)$ represented by 2 arrays. One array is the arrays of $x$ while the other is output from $f(x)$. So basically a numerical representation of the function. If I don't know what $f(x)$ is, ...
0
votes
1answer
32 views

Newton-Raphson on strictly convex function

Maybe someone can give me a hint here: question 1: Given a sequence {$x_n$} which is the Newton-Raphson sequence on some $f(x)$ s.t. $f(x)$ is strictly convex and $f'>0$. Let $\alpha$ be the ...
0
votes
1answer
24 views

Is it possible to evaluate error of numeric schemes by using integrals?

I'd just like to know if it is possible to evaluate the error of a numerical scheme by using it's solutions integral? To elaborate this. I have long transmission line, which I evaluate over time ...
6
votes
2answers
177 views

(Why) can we treat a function of a variable as another independent variable?

I'm currently reading my numerical analysis textbook and something's bugging me. To get into it, let's take a look at the following differential equation; $$u'(x) = f(x, u(x))$$ In order to ...
1
vote
0answers
54 views

Using the Newton's method to find the global minimum of a 2D problem with a constraint

I am solving an optimization problem $$\min f(x_1,x_2)\\ \text{s.t.}~~~~ c(x_1,x_2)\leq 0$$ In my problem, there are two min and two max and I am looking for the global min. I know that with the ...
0
votes
0answers
29 views

limit of the ratio of two divergent integrals

I have to calculate two ratios of two pairs of proper integrals, for a range of parameters. I am stuck when it comes to calculating these ratios when the parameters are such that the integrands start ...
-1
votes
1answer
30 views

How I can to prove the succession $x_n$ converge to 1? [duplicate]

Let $0<x_0<1$ if $x_{n+1} = sin(x_n)$ show that $\lim_{n\to\infty} \frac{x_n}{\sqrt{3}/n} = 1$