Questions on numerical analysis/numerical methods; methods for approximately solving various problems that often do not admit exact solutions.

learn more… | top users | synonyms (2)

2
votes
2answers
83 views

For what values of $x$ is the assignment $y=1-\cos x$ problematic, and why? [closed]

So I'm kind of stuck on this question and I don't exactly know how to describe this on the title header and I apologize... For some values of $x$, the assignment statement $y := 1-\cos(x)$ ...
2
votes
1answer
146 views

Understand a weird method of calculus

I see this method of calculus on youtube and my question: is this method valid? How we can understand it? Thanks.
14
votes
3answers
296 views

How could I improve this approximation?

In a computer application, I need to solve trillions of times an equation which can be reduced to $$f(x)=\sin(x)-a x=0$$ Newton methods (quadratic and higher orders) are used for the solution. ...
10
votes
1answer
648 views

Bounding the basins of attraction of Newton's method

In general, Newton's method for root finding has a "bubbly" boundary between basins of convergence for different roots. This is where fractals are usually created from. But outside these "bubbly" ...
7
votes
3answers
133 views

Parallel lines divide a circle's area into thirds

When I was young I came up with a geometry problem and drew it in a notebook: Suppose we have a circle with radius $r$ and area $A$. Let two parallel lines be equidistant from the center of the ...
7
votes
1answer
2k views

Restricted Three-Body Problem

The movement of a spacecraft between Earth and the Moon is an example of the infamous Three Body Problem. It is said that a general analytical solution for TBP is not known because of the complexity ...
6
votes
1answer
638 views

Finding all roots of polynomial system (numerically)

I want to numerically find all the roots of a system of polynomials (n equations in n variables). Since I can compute the Jacobian for the system (analytically or otherwise), I can use the Newton ...
5
votes
1answer
484 views

How should a numerical solver treat conserved quantities?

Since the good old Noether Theorem ultimately states that any physical system will exhibit conserved quantities, how should they be treated best in numerical solvers? On the one hand, one can observe ...
5
votes
1answer
431 views

How to use FEM to solve a PDE

I come from a Computer Science background and I've been around searching for a concise tutorial that tells me how Finite Element Method is used to solve a certain partial differential equation. ...
5
votes
1answer
2k views

how to diagonalize a large sparse symmetric matrix, to get the eigenvalues and eigenvectors

How does one diagonalize a large sparse symmetric matrix to get the eigenvalues and the eigenvectors? The problem is the matrix could be very large (though it is sparse), at most 2500*2500. Is there ...
4
votes
4answers
178 views

How to compute a lot of digits of $\sqrt{2}$ manually and quickly?

After having read the answers to calculating $\pi$ manually, I realised that the two fast methods (Ramanujan and Gauss–Legendre) used $\sqrt{2}$. So, I wondered how to calculate $\sqrt{2}$ manually in ...
4
votes
2answers
110 views

What is the difference between Hensel lifting and the Newton-Raphson method?

So in the Newton-Raphson method to iteratively approximate a root of a real polynomial, we start with a crude approximation $x_0 \in \mathbb{R}$ for $f(x)=0$ where $f(x) \in \mathbb{R}[x]$. For the ...
4
votes
1answer
201 views

Conjugate Gradient Method and Sparse Systems

What is it about conjugate gradient that makes it useful for attacking sparse linear systems. Why would steepest descent be significantly worse? Please keep in mind that I am still trying to fully ...
4
votes
1answer
2k views

How to compute elliptic integrals in MATLAB

I need to calculate the complete elliptic integrals of the first and second kind , the incomplete elliptic integral of the first kind, and the incomplete elliptic integral of the second kind in ...
4
votes
1answer
133 views

What's the fastest way to get an exact value for a product of (powers of polynomials)?

Suppose we have two integers $a$ and $b$. Also, suppose we have polynomials in $x$, $p_k(x)$. Finally, suppose we have a sequence of integers, where an integer in the sequence is denoted by $c_k$. ...
4
votes
1answer
594 views

Efficiently calculating the logarithmic integral with complex argument

My number theory library of choice doesn't implement the logarithmic integral for complex values. I thought that I might take a crack at coding it, but I thought I'd ask here first for algorithmic ...
3
votes
1answer
59 views

Need help to simplify an equation

I am computing an error estimate where at the end I got the following term $\|X_{k} - G\|\leq (q^{2^{k+2}} + q^{2^{k+3}}+ q^{2^{k+4}}....)q^{-3}\|Y_{0}\| + q^{2^{k+1}}.q^{-2}\|X_0\|$ , where $X_k$ ...
3
votes
1answer
503 views

Explain the error term in Euler method

Task: I had to find out some estimates for M and L to make sure the proportional accucrazy is not above $10^{-4}$ in the Euler method with the problem below. I am trying to understand the page 672 on ...
2
votes
0answers
89 views

how to choose point spacing to approximate a parametric curve using line segments?

Suppose I have a parametric equation for a curve $\vec{r} = f(t)$, which I wish to draw using line segments between some set of points at times $t_0, t_1, t_2,$ etc. If I want to achieve a given ...
2
votes
1answer
267 views

How to get the linear equation system for finite element method from the variational formulation

Let the problem be $$-u'' + a(x) u = f , \;x \in \Omega = ]0,1[ , \;u(0) = \alpha ; \;u(1) = \beta,$$ where $f \in L^2(\Omega) , a(x) \geq a_0 > 0 , a(x) \in L^{\infty}(\Omega).$ This problem ...
2
votes
2answers
316 views

resources to study PDE from

I am an undergrad engineering student. I recently completed my second year, with that said, I have taken several calculus courses. Most recently I completed differential equations and multivariable ...
2
votes
1answer
434 views

Derivation of weak form for variational problem

My question is about understanding the derivation of the weak form of a variational problem (to be used for the solution via the finite element method). The problem is as follows (it is an image ...
2
votes
2answers
2k views

Derivative of $f(x,y)$ with respect to another function of two variables $k(x,y)$

Suppose that we have a function $f(x,y)$ of two variables: $$f(x,y) = g(x) + h(y) + 5(x-y) = x^2 + y^2 + 5(x-y)$$ where $g(x) = x^2$ and $h(y) = y^2$ are also functions of $x$ and $y$, respectively. ...
1
vote
2answers
289 views

Is there a general formula for estimating the step size h in numerical differentiation formulas?

Using three-point central-difference formula $$ f^{\prime}(x_0)\approx \frac{f(x_0+h)-f(x_0-h)}{2h} $$ and for $f(x)=\exp(x)$ at $x_0=0$ we have $$ \begin{array}{c, l, r} h & f^{\prime}(0) ...
14
votes
1answer
265 views

Fastest curve from $p_0$ to $p_1$

I'm trying to solve a problem in path planning: Given points $p_0$ and $p_1$ and vectors $v_0$ and $v_1$, find a function $p(t)$ st. $p(0) = p_0$, $p(T) = p_1$, $p'(0) = v_0$ and $p'(T) = ...
6
votes
1answer
42 views

Floating point arithmetic operations when row reducing matrices

A numerical note in my linear algebra text states the following: "In general, the forward phase of row reduction takes much longer than the backward phase. An algorithm for solving a system is usually ...
6
votes
3answers
155 views

Exact result of a series using Euler-Maclaurin expansion.

This is a variant of Exercise 64 in Chapter 9 of concrete mathematics. Prove the following identity \begin{equation} \sum_{n = -\infty}^{\infty}' \frac{1 - \cos( 2\pi n k )}{n^2 } = 2 \pi^2 ( k - ...
5
votes
4answers
2k views

Recommendations for Numerical Analysis texts?

I'm in a numerical analysis course right now and it's pretty rigorous but I'm enjoying it a lot. I took a lower level course before that was more oriented towards implementation of numerical methods, ...
5
votes
2answers
2k views

Fast Matlab Code for hypergeometric function $_2F_1$

I am looking for a good numerical algorithm to evaluate the hypergeometric function $_2F_1$ in Matlab (hypergeom in Matlab is very slow). I looked across the ...
5
votes
1answer
2k views

Natural cubic splines vs. Piecewise Hermite Splines

Recently, I was reading about a "Natural Piecewise Hermite Spline" in Game Programming Gems 5 (under the Spline-Based Time Control for Animation). This particular spline is used for generating a C2 ...
5
votes
2answers
1k views

Symmetrize eigenvectors of degenerate (repeated) eigenvalue

I have the following situation: I have a hermitian Matrix $A$ that satisfies some symmetries which I can express via $AS = SA$ for a unitary matrix $S$. Now I am interested in the eigenvectors of ...
4
votes
3answers
3k views

Gaussian quadrature three-point

Derive the one and two-point Gaussian quadrature formulas for $$I=\int^1_0xf(x)dx\approx \sum_{j=1}^nw_jf(x_j)$$ with weight function $w(x)=x$. Which I know how to do and which I attached below (I ...
4
votes
4answers
990 views

Calculation of Bessel Functions

I want to calculate the Bessel function, given by $$J_\alpha (\beta) = \sum_{m=0}^{\infty}\frac{(-1)^m}{m!\Gamma(m+\alpha +1)} \left(\frac{\beta}{2}\right)^{2m}$$ I know there are some tables that ...
4
votes
2answers
632 views

Numerical analysis textbooks and floating point numbers

What are some recommended numerical analysis books on floating point numbers? I'd like the book to have the following In depth coverage on the representation of floating point numbers on modern ...
4
votes
0answers
876 views

Convergence of Gauss-Newton method for piecewise linear functions

Notation for Gauss-Newton method Non-linear least squares problems are often solved by the Levenberg-Marquardt algorithm, which can be viewed as a Gauss–Newton method using a trust region approach. ...
4
votes
4answers
503 views

Numerical computation of the Rayleigh-Lamb curves

The Rayleigh-Lamb equations: $$\frac{\tan (pd)}{\tan (qd)}=-\left[\frac{4k^2pq}{\left(k^2-q^2\right)^2}\right]^{\pm 1}$$ (two equations, one with the +1 exponent and the other with the -1 exponent) ...
3
votes
2answers
123 views

Bernstein polynomial looks like this: $B_i^n={{n}\choose{i}}x^i(1-x)^{n-i}$.Find it's $r$'th derivative.

Bernstein polynomials are defined like this $B_i^n={{n}\choose{i}}x^i(1-x)^{n-i}$.I need to prove that $r$'th derivative of it is equal to: ...
3
votes
2answers
139 views

Root of the function $f(x)=xe^x-R$

How can we find the root of the function $f(x)=xe^x - R$ for a general R where $R>=-1/e.$ I don't have any idea as to how to even approach this. Came across this problem during my self-study in ...
3
votes
1answer
451 views

Understanding rate of convergence and order of convergence

I am trying to understand what is the difference between 'rate of convergence' and 'order of convergence'. Does anyone know an intuitive explanation of the difference between them? For example, say I ...
3
votes
3answers
127 views

Accuracy from approximating $\zeta(2)$ with a partial sum

This is for an introductory numerical analysis class. The answer shouldn't be too complicated, but if you have one, feel free to post it. Figure out what $n$ should be such that $$\sum_{k=n+1}^\infty ...
3
votes
1answer
4k views

Can QR decomposition be used for matrix inversion?

Is there any simple algorithm for matrix inversion (that can be implemented using C/C++)? Can QR decomposition be used for matrix inversion? How?
2
votes
1answer
67 views

A trigonometric integral identity from Krylov's “Approximate Calculation of Integrals”

In the theory of Fourier series the following expansion is known $$ \operatorname{sign}\left(\sin\left((n + 1) x\right)\right) = \frac{4}{\pi} \sum_{k = 0}^\infty \frac{\sin\left((2k + 1) (n + 1) ...
2
votes
1answer
58 views

Higher order numerical PDE schemes near boundaries, implementation in MATLAB

Followup to my previous question. The first order scheme proved unstable for my pde: $$f_t + A y f_x - B x f_y =0$$ So I'm looking to implement a higher order scheme (using these tables). I was ...
2
votes
1answer
49 views

Strictly diagonal matrix

Suppose that matrix $A$ is strictly diagonally dominant, show that $$\|A^{-1}\|_{\infty}\leq\left[\min_i\left(|a_{ii}|-\left|\sum_{\substack{j\neq i}} a_{ij}\right|\right)\right]^{-1}.$$
2
votes
1answer
2k views

Help with using the Runge-Kutta 4th order method on a system of 2 first order ODE's.

The original ODE I had was $$ \frac{d^2y}{dx^2}+\frac{dy}{dx}-6y=0$$ with $y(0)=3$ and $y'(0)=1$. Now I can solve this by hand and obtain that $y(1) = 14.82789927$. However I wish to use the 4th order ...
2
votes
2answers
12k views

How to solve simultaneous equations using Newton-Raphson's method?

I understand how to find roots of a polynomial equation programmatically using Newton-Raphson method as explained here. How to find the values of $x$ and $y$ from the simultaneous equation given ...
2
votes
2answers
220 views

$\beta_k$ for Conjugate Gradient Method

I followed the derivation for the Conjugate Gradient method from the documents shared below http://en.wikipedia.org/wiki/Conjugate_gradient_method ...
1
vote
1answer
104 views

What is the relation between analytical Fourier transform and DFT?

First of all let me state that I searched for this topic before asking. My question is as follows we have the Analytical Fourier Transform represented with an ...
1
vote
1answer
79 views

MATLAB, 1st order 2d hyperbolic equation, problem with convergence.

Follow up to my previous question: MATLAB: solving 1st order hyperbolic equation in 2 spacial dimensions The equation I'm solving has the form: $$f_t + A y f_x - B x f_y =0$$ I wrote the following ...
1
vote
1answer
62 views

Finite differences coefficients

I'm interested in deriving a forward finite difference approximation for the gradient of a function, $f(x)$, at the point $x = x_i$ using $k+1$ points. If the spatial domain is uniformly discretized, ...