Questions tagged [approximation]

Questions on approximating functions (e.g. PadeApproximant), approximating integrals, working with approximate values (e.g. RootApproximant) etc.

Filter by
Sorted by
Tagged with
0
votes
1answer
63 views

Why do these two methods give different answers for this simple approximation?

I tried to find Padé approximant of the function below using two different methods, but the results were not equal. $f(x)=1+x+x^2+x^3+\cdots$ Method 1: Using the direct built in function of Padé ...
0
votes
0answers
75 views

Multivariate Pade approximant

Does Mathematica generate multivariate or just two-variate Pade approximant? If so, what is the generating command?
2
votes
1answer
95 views

Setting Precision in For

How do you set the precision for a function where you substitute a number in a For loop? I mean I code something like this and I want Mathematica to set the precision for all the values ...
1
vote
0answers
52 views

What Algorithm Does EconomizedRationalApproximation Use?

I'm very interested in Approximation Theory, especially with Continued Fractions and Rational Functions. I really like the approximations that Mathimatica gives with EconomizedRationalApproximation[]...
0
votes
2answers
89 views

Nested NIntegrate over a region: Numerical Integration not converging

I need to computed two double nested numerical integrals, of which one is defined over a specific region (e.g. a pentagon). I've tried to use a single NIntegrate with four variables, but the result is ...
-1
votes
1answer
61 views

Series expansion of a function up to linear terms [duplicate]

I have the following: \[CapitalSigma] = r^2 + a^2 Cos[\[Theta]]^2; \[CapitalDelta] = r^2 - 2 M r + a^2 - k/3 r^2 (r^2 + a^2); grr = \[CapitalSigma]/\[CapitalDelta]; ...
0
votes
0answers
105 views

Inverse Functions

I'm new to Mathematica, so I fell sorry for posting relativily naive/dumb questions. I have these two functions that represent X coordinate distortion of an SLA 3D printer. ...
0
votes
0answers
23 views

Numerical Integration of Data in Sensitivity Analysis

I'm attempting to do some Sensitivity Analysis on the following function of interest $f(\pmb x) = x_1 + x_2 x_3^2 $. The variables have the ranges of {1,1000}, {1,100}, {1,10}. The first step is to ...
0
votes
2answers
52 views

Approximating giant polynomial expression

Suppose I have a giant polynomial expression analogous to $$ F=a_1xX^6+a_2x^2X^5+a_3x^3X^4+a_4x^4X^3+a_5x^5X^2+a_6x^6X $$ and it is true that $X \gg x$. Let it be enough for me to approximate this ...
2
votes
2answers
261 views

Two-Points Padé Approximant

My Question is about two points Pade approximant From Mathematica References. I just find the Pade approximant for a real function in one point Example : ...
1
vote
2answers
75 views

Function decomposition to Fourier series using first impulse function

I have periodic function with certain first impulse function and period value. My task is to decompose it to approximate Fourier series (k_max = 10) using Laplace transform of first impulse function: ...
2
votes
1answer
113 views

Comparing the plots of two functions in number theory

Definition. For $x>1$, let $$R(x):=\sum_{n\ge1}\frac{\mu(n)}{n}\,\operatorname{li}(x^{1/n})$$ denote the Riemann prime counting function. If you are not familiar with the mathematical expressions ...
4
votes
2answers
341 views

Suggest an irrational number from decimal one

I want to know is there any function in Mathematica that suggests a simple irrational number combination for decimal one? For example, if I give 0.804738 then I get ...
0
votes
1answer
48 views

3D plot using Table & FindRoot

I have two expressions involving terms $S_1$ and $S_2$, call the expressions $F1, F2$. I cannot solve $F_i=1$ for $S_i$ so instead I numerically approximate using ...
2
votes
3answers
164 views

How to approximate the harmonic sum $\sum_{n=1}^\infty\frac{{4n\choose 2n}\overline{H}_{2n}}{n 2^{4n}} ?$

How to approximate $$\sum_{n=1}^\infty\frac{{4n\choose 2n}\overline{H}_{2n}}{n 2^{4n}} ?$$ Where $\overline{H}_n=\sum_{k=1}^n \frac{(-1)^{k-1}}{k}$ is the skew harmonic number. The mathematica ...
-1
votes
1answer
81 views

Numerically Approximating Solutions to Differential Equation

I'm trying to numerically approximate solutions to a messy differential equation, given below $$(1-\alpha \frac{1}{\pi^{'}(s_2)})(s_2-\pi(s_2)+\frac{\beta}{2}\pi(s_2)-\frac{\alpha\beta}{2}s_2)+(p-\...
7
votes
3answers
237 views

How to approximate $PV\int_0^\infty \frac{\tan x}{x}\text{d}x?$

What's the mathematica command to get the numerical value of : $$PV\int_0^\infty \frac{\tan x}{x}\text{d}x?$$ where $PV$ is the principal value.
0
votes
1answer
64 views

Plotting function and its approximation function

I have a problem which I have not been able to solve. I want to plot a function and and operator which approximates it when you let w to infinity. I will give all ...
0
votes
1answer
74 views

Finding an approximate solution to this integral: $\alpha(\phi,r,p,d)=\int_0^\infty w(z,r,p,d)Q(z,r,\phi)dz$

I'm working on a physics problem and encountered a rather complex integral for which I'm trying to find an approximate solution. The integral is of the following form: $\alpha(\phi,r,p,d)=\int_0^\...
3
votes
4answers
425 views

Nested optimization problem - Function approximation

I need to maximize the following function (the input to NMaximize below) ...
1
vote
1answer
107 views

Optimizing my code for Broyden's method

The following code is my attempt of employing Broyden's method for root finding on the function $f(x,y)=(e^{xy}-y^2-2,\cos(x+y)+\frac{1}{2})$. Where the first matrix is the Jacobian, then it gets ...
1
vote
2answers
176 views

Minimizing simple function of three variables fails

I need to minimize simple function with all variables are positive integers, but the out is the same as the input. No solution ...
0
votes
1answer
54 views

Expansion of nonlinear functions with damping properties in exponential series

I am working on solving nonlinear differential equations and found such a solution with exponential properties. $\frac{dx}{dt}=\frac{d}{dx}(sech(x)^2)$ The solution of which is: $x(t) = \sinh ^{-1}\...
5
votes
3answers
181 views

Higher order Around, for large error propagation

TLDR question: How to redefine Around to work with higher order approximation. Motivation From the documentation Around ...
8
votes
1answer
171 views

How to find a numerical antiderivative with NIntegrate methods?

@JimBelk asked in Interpolating an Antiderivative how to find a numerical antiderivative. I gave an answer that uses NDSolve with the default method for integrating ...
1
vote
2answers
116 views

Evaluate function at "good" points used by Plot in numerical problems

Plot function with option Mesh->All shows how mathematica evaluates function to make it most optimal for plotting. I'd like to evaluate some physical function in ...
4
votes
1answer
112 views

Series function not expanding an expression

I have the following code: FDE[d_, η_] := η^(d + 1)/Gamma[d + 2] + π^2/(6*Gamma[d])*η^(d - 1); Series[FDE[d/t, 1/η]/FDE[d/t - 1, 1/η], {η, 0, 3}] The series ...
2
votes
1answer
81 views

FindFit low speed when fitting polynomial coefficients: is it possible to significantly increase the speed?

I work in Mathematica with a Butterworth filter, the transfer function of which depends on the selected order and cutoff frequency. I want to evaluate the change in the location of the roots on the ...
1
vote
0answers
109 views

Approximation of a function by a polynomial (Chebyshev First Kind, Bernstein, etc...) containing only even degrees and constants in a given Range[a,b]

In Mathematica, how can I create a polynomial function containing only even degrees and constants? That is, I have a function: $f(x)=\frac{\pi ^2}{\left(\frac{\pi }{2}-\tan ^{-1}(k (x-1))\right)^2}$ ...
2
votes
0answers
53 views

Approximation of roots using Series

I am solving a fifth degree polynomial using Series. My equation looks like ...
0
votes
0answers
41 views

Nintegrate providing results much smaller than what is expected

This is the first time I am posting something here. So, apologies if I make any mistake. I am dealing with a numerical integration in Mathematica-11.0 that has a Bessel function in it. In order to ...
7
votes
3answers
660 views

Extracting a function from a Contour Plot

Context to understand the question Suppose that I have the next equation sol = ParametricNDSolve[{y'[t] == a y[t], y[0] == 1}, y, {t, 0, 10}, {a}] And I make a ...
1
vote
1answer
140 views

How do you find the Inverse of Elliptic Integral of Second Kind when modulus is large

So I tried to take the inverse of EllipticE when modulus is large, in Mathematica, but the solution gives wrong answer. ...
2
votes
0answers
34 views

Setting the tolerance for `Equal[]` [duplicate]

I would like to control how Equal[] works and allow a certain error associated with it. I would like numerical values which are, say, within one-thousandth of one ...
3
votes
1answer
34 views

Estimating the range of values of x for which the absolute error in the approximation of $\cos[x]$ is accurate to within 0.08

The approximation is for $\cos[x] \approx 1 - \frac{x^2}{2}+ \frac{x^4}{24}$. I've tried a combination of many different things, but can't figure it out. My error always ends up as {0.00136436}. Any ...
1
vote
1answer
43 views

How does the Bias parameter adjusts Chebyshev nodes in RationalInterpolation of the Function Approximation Package?

How does the Bias parameter adjusts Chebyshev nodes in RationalInterpolation of the Function Approximation Package? What is the mathematical mapping/formula applied in the Bias adjustment from -1 1 ...
2
votes
1answer
66 views

Numerical solution of a differential equation with a condition on a parameter

I'm considering the Mazenko equation as it's written in https://doi.org/10.1103/PhysRevB.46.10594 (eq. 7) \begin{equation} f''+\left(\frac{1}{x}+\frac x 4 \right)f'+\frac \lambda \pi \,\tan\left(\...
0
votes
1answer
73 views

QR-Decomposition [closed]

I should make a program in which with help of QR-decomposition find approximation of x^sinx shaped a+bLnx+c*e^x for a values x € ...
1
vote
1answer
132 views

Is it feasible to curve fit to a staircase function? [closed]

Taking as a starting point the advice given in this post I am trying to fit data to a staircase function as follows: ...
0
votes
0answers
42 views

What is the limit of digits to show in the conversion of an exact number to an Arbitrary Precision Number?

By executing something like N[π, c] what is the maximum positive integer value c can have until the output is compromised by ...
0
votes
0answers
71 views

Smooth approximation near a non differentiable point

Let $f:\mathbb{R}_+\rightarrow \mathbb{R}$ be a function differentiable for $x>0$ but non differentiable at $x=0$ (for instance $f=\sqrt{\cdot}$) and $g$ be a polynomial function. I know how to ...
4
votes
0answers
127 views

How does Mathematica evaluate N[π, 30] == π?

I want to know how N[π, 30] == π works. The result is True. I wonder whether the exact number ...
3
votes
1answer
72 views

How I can plot the first terms of Taylor series arround $x=0$ of the below given function in the form of integrand?

I have tried to plot the first term of taylor expansion of the below function but I didn't come up to the plot . Any help , Where is the problem in my code ? The Function is : $$I(x)=\int_{-\infty}^{...
0
votes
0answers
37 views

Fitting special data

I have the following file which contains data, regarding the time evolution of the composition of a star. We are only interested in the first (time) and fourth column (mass). Let's make the ...
0
votes
2answers
78 views

Find best fitted approximated parameters

I want to find the best fitted approximated parameters for the following case: $$\begin{align*} 2a + 3b &= 5\\ a + b &= 4\\ a + b &= 3.9\\ 2a + 3b &= 5.1 \end{align*}$$ When I use <...
0
votes
1answer
170 views

Approximating missing data points in a list using fit models [closed]

Suppose I have the following list: l={0, 76, 413, 942, 1344, 1651, 1486, 1013, 581, 237, 65, 17, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0} I want to find a fit ...
5
votes
1answer
112 views

Speeding up Probability using Monte Carlo

I have a recipe for generating custom distributions, which I want to use Probability[...] on, but am finding that with more than a few variables it very quickly becomes intractable (it runs for hours)....
1
vote
1answer
93 views

Making a List of FindRoot approximations

I have the following function. c[n_, k_, z_] := Sum[(-1)^j*(z^(n*j + k)/(n*j + k)!), {j, 0, Infinity}] I'd like to find roots of the equation ...
4
votes
3answers
302 views

Numerical solution of a singular integral equation

I am looking to approximate the solution u of the following equation using discretization method or any other idea. Is there any way on how to find a numerical ...
0
votes
1answer
665 views

Approximating expression where one variable is much bigger than another one

I'm trying to approximate a generic function F[a,b,c], such as (a + b) (b + c) (a + c) or ...