Skip to main content

All Questions

Filter by
Sorted by
Tagged with
77 votes
6 answers
29k views

Multivariable Taylor expansion does not work as expected

The basic multivariable Taylor expansion formula around a point is as follows: $$ f(\mathbf r + \mathbf a) = f(\mathbf r) + (\mathbf a \cdot \nabla )f(\mathbf r) + \frac{1}{2!}(\mathbf a \cdot \nabla)...
matheorem's user avatar
  • 17.4k
30 votes
2 answers
6k views

How does Mathematica understand branchcuts of the complex logarithm?

Say I have the function $f(x) = x \tanh(\pi x) \log (x^2 +a^2)$ where $a$ is some positive real number. Then it seems to be me that Mathematica when given such a ...
user6818's user avatar
  • 1,191
16 votes
3 answers
2k views

How can I obtain an asymptotic integral expansion at infinity?

I want to find the asymptotic expansion at $x \to \infty$ of the following function: $$ I(x) \equiv \int_0^{\pi/2} e^{-xt^3 \cos(t)} dt.$$ To do this, I defined ...
glS's user avatar
  • 7,753
15 votes
1 answer
318 views

Why do big-O terms disappear in definite integrals since Mathematica 9?

In Mathematica 8, when I computed the following input: Integrate[Series[Cos[x], {x, 0, 2}], {x, 0, a}] Mathematica returned an expression that had a O[a^4] in ...
Martin J.H.'s user avatar
13 votes
3 answers
544 views

Find asymptotics of $\sum\limits_{i=0}^{n/3} 2^i \binom{n-i-1}{\frac{2n}{3}-1}$

I have an expression 2^n / Sum[ 2^i Binomial[ n - i - 1, 2n/3 - 1], { i, 0, n/3}] ...
Simd's user avatar
  • 1,119
13 votes
1 answer
1k views

Why is this infinite series wrongly computed by Mathematica?

Bug introduced in 7.0 and fixed in 10.0 Could you let me know if Mathematica (newer versions) is able to correctly compute this one? ...
user 1357113's user avatar
  • 1,415
13 votes
2 answers
865 views

How to compute the residue of $e^{z-\frac{1}{z}}$ at z=0?

I've tried the following but it didn't work: Residue[Exp[z - 1/z], {z, 0}] not even this: Residue[Exp[1/z], {z, 0}] ...
User's user avatar
  • 295
13 votes
2 answers
348 views

Differentiation and series expansion of dot product - inconsistent results

Bug introduced in 9.0 or earlier and persisting through 11.3 or later Bug resolved in 12.0 As of 12.0, we have an unevaluated result - inconsistent with the differentiation result, but not invalid. ...
mikado's user avatar
  • 17.1k
13 votes
1 answer
390 views

Series with ArcTan gives wrong symbolic answer in Wolfram Language

Bug introduced after 9 and persisting through 13.1. Resolved in 13.2 Recently, I have found a very bad problem with Wolfram Language. It gives the wrong answer for a quite simple expression! When ...
Chaosor's user avatar
  • 231
12 votes
3 answers
8k views

Laurent series expansion

Can someone share how to find the Laurent series expansion of $$f(z)=\frac{1}{(z^2-1)(z^2-4)}$$ centered at $0$ on the annulus $1<|z|<2$?
David's user avatar
  • 15k
12 votes
2 answers
498 views

Why do I get a wrong result from SeriesCoefficient?

Bug introduced in 7.0.1 or earlier and fixed in 13.3 Consider the following code: func[x_] = Sin[x^3]/(x - 1/3); c[n_] = SeriesCoefficient[func[x], {x, 0, n}] <...
Ruslan's user avatar
  • 7,182
12 votes
1 answer
540 views

Dirichlet coefficients as limits: wrong

Perhaps I should have included the word "bug" in my question. Here we go There is a bug in this Limit Limit[3^s (-1 - 2^-s + Zeta[s]), s -> ∞] (* 0 *) which ...
Dr. Wolfgang Hintze's user avatar
12 votes
1 answer
1k views

Contour Integration along a contour containing two branch points

I need to compute following contour integrations: $$f(u)=\oint_\alpha dz \sqrt{z^3+z+u} \qquad ; \qquad g(u)=\oint_\beta dz \sqrt{z^3+z+u}$$ In which $\alpha$ and $\beta$ are two contours in ...
QGravity's user avatar
  • 221
11 votes
2 answers
1k views

Series expansion of an inverse

I have to find the series expansion of the inverse function of : $\arctan\left(\frac{\ln(1+x)}{1+x}\right)$ How do I find out the series expansion of any inverse ? Note: The inverse of a function $f$...
Cydonia7's user avatar
  • 2,549
11 votes
2 answers
2k views

Find closed form expression for series expansion coefficients [duplicate]

Is there a built-in function that will find a general expression for the coefficient of the series expansion of a function? Series will only give the explicit ...
Szabolcs's user avatar
  • 236k
11 votes
2 answers
305 views

Is it possible to circumvent a bug inside SeriesCoefficient?

Bug introduced in 9.0.1 or earlier and fixed in 13.3. As far as I can tell, there seems to be a bug in SeriesCoefficient: ...
Raphael's user avatar
  • 559
10 votes
1 answer
842 views

Expansion for Modified Bessel Function Around Infinity

I'm somewhat new to Mathematica, and I don't understand why I'm getting inconsistent series expansions for the modified Bessel Function of first kind near $x=\infty$. First problem: I get different ...
jornada's user avatar
  • 101
10 votes
1 answer
247 views

How to predict the degree of the first series coefficient?

Given an expression f that is a function of x and a number x0, what is the least integer <...
Michael E2's user avatar
  • 245k
9 votes
2 answers
877 views

Analytical approximation of indefinite integral on a given interval to a given precision

I'm looking for an analytical approximation of $\int_a^b e^{-x^2}\mathrm{erf}(x+c) dx$ that would be accurate to precision $\varepsilon$ for $a,b,c$ within a certain range. How do I ask Mathematica ...
Michael's user avatar
  • 767
9 votes
1 answer
464 views

Calculating relative error of Ramanujan formula for ellipse perimeter

On this page, they present the Ramajujan's second formula for the perimeter of an ellipse: $$P \approx \pi (a+b) \left(1+ \frac{3 h}{\sqrt{4-3 h}+10}\right),$$ where $h=(a-b)^2/(a+b)^2$. They expand ...
Ytrewq's user avatar
  • 179
8 votes
1 answer
2k views

Series expansion for small ratio of variables

I have a messy expression of variables that I would like to simplify under the assumption that certain ratios of the variables are small. For example, consider $\sqrt{x+y}\;$ expanded for small $\...
mcFreid's user avatar
  • 183
6 votes
2 answers
2k views

Why can’t mathematica find this residue?

I am trying to find the residue of the function $$f(z)=(z+1)^2e^{3/z^2}$$ at $z=0$. I tried the following in Mathematica Residue[(z+1)^2*Exp[3/z^2],{z,0}] which ...
DMH16's user avatar
  • 409
6 votes
1 answer
3k views

How to expand a function into a power series with negative powers?

Is there any way to expand this expression a+b(1-Exp[-T/(b c)]/(z-Exp[-T/ (b c)]) (where a, ...
Mag Num's user avatar
  • 71
6 votes
3 answers
417 views

Neglecting higher order terms in a Lagrangian

I have a lagrangian which is modified by variable change. I want to neglect all the 4th order and higher terms in the new lagrangian. The code being used is given below: ...
codebpr's user avatar
  • 2,963
6 votes
1 answer
221 views

Getting terms and only evaluate specific parts of a series

How to write the first five terms of this series in the following form by MMA code? $\sum_{n=1}^{\infty} \frac{1 \cdot 3 \cdot \cdots \cdot(2 n-1)}{2 \cdot 4 \cdot \cdots \cdot 2 n}= \frac{1}{2}+\frac{...
lotus2019's user avatar
  • 2,425
6 votes
1 answer
699 views

Find exponential generating function from the first few terms

The function FindGeneratingFunction computes the ordinary generating function of a sequence, given a sufficient number of initial terms. I have two questions in ...
Manolito Pérez's user avatar
6 votes
2 answers
273 views

Problem with `Derivative`/`Series` and `InverseFunction`

Here is the Mathematica code I'm asking about: ...
user202729's user avatar
6 votes
1 answer
425 views

Is it possible to find a function from first few terms in the expansion

Is it possible to find a function if first few terms of the expansion is known. For example if I have this series $f(x)=\frac{k^3 x^2}{6}-\frac{k^5 x^4}{120}+\frac{k^7 x^6}{5040}-\frac{k^9 x^8}{...
Sumit's user avatar
  • 16k
6 votes
3 answers
196 views

Extracting a logarithmic divergence of an expression using Series

Consider the following expression: ...
Patrick.B's user avatar
  • 1,553
6 votes
1 answer
233 views

Using Integrate and then Series seem to produce a wrong result

Bug introduced in 11.1.0.0 or earlier and persisting through 14.0 or later Run this: ...
Konstantin Konstantinov's user avatar
5 votes
6 answers
429 views

How to find the derivative value at $(\pi,0)$ for this implicit function $n$ times?

I am trying to take the implicit derivative at $\sin(x+y)+\sin(x)=y$ and substitute $x=\pi$ and $y=0$ at least 6-7 times since I need to find the Taylor series for this function. Since I barely ...
Arbuja's user avatar
  • 121
5 votes
2 answers
327 views

Calculating the n-th term of the series expansion of a special function [closed]

I am trying to calculate the $n^{\text{th}}$ term of the following polynomial: $$\, _2F_1\left(-n,n+3;\frac{3}{2};x\right)$$ To do this I calculate: ...
Clerk's user avatar
  • 65
5 votes
1 answer
2k views

Asymptotic expansion

I wanted to expand a function of $x$ about $x=\infty$ and see its coefficients as a function of the parameters $m,n,q,y$ and I wrote this - but it didn't work! It gave me back a very complicated ...
user6818's user avatar
  • 1,191
5 votes
2 answers
214 views

Assumptions for FourierSeries

I want to calculate the Fourier series of the following function. $u(t)=\left\{\begin{array}{lc}0, & -\frac{T}{2} \leqslant t<-\frac{\tau}{2} \\ h, & -\frac{\tau}{2} \leqslant t<\frac{\...
lotus2019's user avatar
  • 2,425
5 votes
3 answers
125 views

Why earlier terms generated from AsymptoticDSolveValue change when increasing the order?

I was comparing my hand solution with Mathematica's. I noticed the particular solution terms generated for a Frobenius series solution change depending on the order. This should not happen. As when ...
Nasser's user avatar
  • 151k
5 votes
2 answers
917 views

Fast way to the Taylor series expansion coefficients of multivariable function?

Is there a fast method to get the coefficients of a Taylor series expansion of the function $f(x_1,x_2,...,x_d)$ with maximal summed partial derivative up to $n$, where $d,n$ can be relatively large (...
hlren's user avatar
  • 117
5 votes
2 answers
754 views

Expansion of the Meijer G Function

I'm trying to do the integral Integrate[ B^2*BesselK[0, ko*ρ]^2*2 π*ρ, {ρ, a, ∞}] which I figured should be relatively simple as the integral of a Bessel ...
Brandon's user avatar
  • 105
5 votes
2 answers
340 views

Series expansion of a certain infinite product

I wanted to find Series[Product[Cos[t/n], {n, 1, Infinity}], {t, 0, 5}] but failed. Then, I tried ...
Aster's user avatar
  • 3,896
5 votes
1 answer
134 views

Why the coefficient function is very fast

When looking for the coefficients of an desired series, I found that the Coefficient function is very fast compared to other functions and methods. In the following summary, we find the different ...
Tag Mohamed Amine's user avatar
5 votes
4 answers
463 views

`Series` with non-analytic terms

I have a function which has a smooth non-analytic term, a simplified version of which is $$ f(\lambda) = \frac{1}{1 + k \lambda + e^{-1/\lambda}}. $$ I want a series expansion of this, in Mathematica, ...
Timo's user avatar
  • 235
5 votes
1 answer
207 views

How to Approximate at Non-differentiable Point (forced Series Expansion around Branch Cut)

I need a numerical approximation around some functions at $x = 0^{-}$ from the left side, where $x = 0$ is unfortunately the right end of the domain (in the reals) so the functions are not ...
Lee David Chung Lin's user avatar
4 votes
1 answer
1k views

How to get the Taylor series of implicit functions

Given that the equation $x+\frac{1}{2} y^{2} +\frac{1}{2} z+\sin (z)=0$ can determine an implicit function $z(x,y)$ at {0, 0}, I now need to expand the implicit function $z(x,y)$ to a fourth-order ...
A little mouse on the pampas's user avatar
4 votes
1 answer
409 views

Taylor series of functions with defined derivatives?

Suppose that I have the following equations $$\dot{x}(t) = p(t),$$ $$\dot{p}(t) = -V'(x(t)).$$ I am trying to compute the Taylor series of $p(t)$ at $t=0$. Here are the codes I use: ...
Chichipingguo's user avatar
4 votes
1 answer
2k views

Series approximation to integral

I would like to approximate the integral $$ \int_0^\infty dy\,\frac{1}{\sqrt{2\pi y\sigma^2}}\exp\left(-\frac{(x-y)^2}{2y\sigma^2}\right)f(y), $$ as a series expansion in the limit $\sigma\rightarrow ...
Till Hoffmann's user avatar
4 votes
1 answer
368 views

Finding periodic ODE solution via small parameter method

I want to figure out how to find periodic solutions of ODE via the small parameter method. I will provide couple of examples of what I mean. Consider equation $\ddot x + 3x = 2 \sin t + \mu \dot x^2$....
Hedgehog's user avatar
  • 293
4 votes
2 answers
147 views

Mathematica flips the sign of a Maclaurin series

I have the following Mathematica code: ...
codebpr's user avatar
  • 2,963
4 votes
1 answer
157 views

How to expand Lie characters?

The following involves characters of affine Lie algebras, and I will be using as reference the book on CFT by Francesco et at (here are some screenshots if useful). But hopefully the post will be self-...
AccidentalFourierTransform's user avatar
4 votes
2 answers
2k views

Radius of Convergence when using Series[]

I want to write function expand[f] which gives the Taylor series expansion of $f(x)$ up to $O(x^4)$ in $\TeX$ form, as well as return the radius of convergence. I ...
Luke Collins's user avatar
4 votes
1 answer
546 views

Problem with series expansion and integrate

I have the following very simple code. A power series in a-parameter, function f[x], is integrated with respect to x, and the ...
KDH's user avatar
  • 101
4 votes
1 answer
144 views

Workaround for Series messing up Inactive[Integrate]

Bug introduced in 10.0 Series does not correctly construct expansions of inactive Integrate: ...
QuantumDot's user avatar
  • 19.8k