Questions related to the calculus and analysis branches of Mathematica, including, but not limited to, limits, derivatives, integrals, series, and residues.
6
votes
3answers
963 views
How to find the nth derivative?
This question is not the same as my last one. How do you find the $n$-th derivative where $n$ is a variable?
For example, you can find the nth derivative for a specific $n = 3$
...
1
vote
2answers
263 views
How to draw a tangent to a surface in a given direction?
It seems quite embarrassing for me, but somehow I can't draw a tangent line to a surface in a given direction. Assume that I want to visualize directional derivative of the function, say, ...
1
vote
2answers
566 views
Find the dimensions of a cylindrical can that will minimize the cost of the material
A cylindrical can is to be made to hold 1 L of oil. Find the dimensions
that will minimize the cost of the metal to manufacture the can.
This is a standard calculus problem.
The volume of the ...
4
votes
2answers
376 views
Chain rule while differentiating
I am trying to find the derivative of a function defined in polar coordinates with respect to $x$ and $y$. My function is defined as follows:
$ v_x(r, \theta ) = v_r \cos (\theta ) - v_{\theta }\sin ...
3
votes
2answers
1k views
How to convert a system of parametric equations to a normal equation?
For example, I have a system of parametric equations (R is a constant number) :
...
12
votes
1answer
236 views
Extra factors appear when evaluating Euler integrals
When I perform the double integral in Mathematica,
Integrate[(x (1 - x))^z (y (1 - y))^z, {x, 0, 1}, {y, 0, 1}]
which should give
$$B(z+1,z+1)^2 = ...
25
votes
4answers
925 views
Generating evenly spaced points on a curve
In the KnotData package a simple command such as
points = Table[KnotData[{3, 1}, "SpaceCurve"][t], {t, 0, 2 Pi, 0.1}];
will ...
7
votes
2answers
383 views
Why aren't these additions of integrals and summations equal?
I have the following code:
Simplify[Integrate[f[x] + g[x], x] == Integrate[f[x], x] + Integrate[g[x], x]]
To test:
$$\int{\left(f(x) + ...
7
votes
2answers
362 views
Simplifying the derivative of $|x|$
Context
In[855]:= D[Abs[x], x] /. x -> 1
Out[855]= Derivative[1][Abs][1]
In[856]:= D[x, x] /. x -> 1
Out[856]= 1
Question
Why is ...
4
votes
4answers
542 views
Mathematica gives wrong answer for integral
When I execute the following,
Integrate[Exp[-w^2 + I w^3], {w, -\[Infinity], \[Infinity]}]
I get
...
10
votes
4answers
2k views
How to find the domain and range of a function with Mathematica?
I'm studying calculus and in some exercises I am asked to find the domain and range of a function. Does Mathematica have already a built-in function for this?
I can imagine some ways of doing so, ...
2
votes
1answer
103 views
Assumptions with D
I want to give assumptions for the D function. Say I want to calculate $\frac{d|x|}{dx}$ for $x>0$, which is 1.
I write ...
3
votes
2answers
215 views
5
votes
1answer
377 views
Getting an InterpolatingFunction from a ContourPlot
I have a function, say
minimizeme[Ω_][β_][ϵ_] = ϵ^2 Ω - Log[2 (Cosh[2 β] + Cosh[2 β ϵ])]/(2 β);
I want to find its critical points in $\epsilon$ for a given ...
5
votes
3answers
433 views
Can't compute definite integral
Consider a scalar field (in polar co-ordinates), $f(r) = l-r$.
Now I want to evaluate the field integral over a circular region of radius $b$, centered at a distance of $x$ from the origin. According ...
5
votes
0answers
88 views
Calculating a limit with a result that is discontinuous in the parameters
The following limit is left unevaluated (Edit: added the assumption that $\epsilon$ is real thanks to the comment below):
...
10
votes
1answer
631 views
How to deal with complicated gaussian integrals in Mathematica?
As we know, for most Gaussian integrals, we can get the analytical
result. Now I have many Gaussian integrals to treat, which have the
following general form,
...
3
votes
2answers
561 views
How to substitute numeric values in a symbolic Jacobian matrix?
I have a multi-variate function from $\mathbb{R}^n\to\mathbb{R}^n$. Choosing any desired initial vector, we can produce the corresponding function value, which is a vector as follows. The main problem ...
11
votes
1answer
665 views
How does Mathematica integrate?
Basically, this question can be considered to be an extenstion to my other question.
What I wanted to do was this integral as homework (it is indefinite BTW so no approximations using Simpson's Rule ...
1
vote
2answers
180 views
Quickly differentiate and evaluate a function of several variables
How can I differentiate a function with respect to several variables and evaluate it at the same time ? I want to specify also the variable index that I want to differentiate and the number of times I ...
5
votes
1answer
217 views
Check homework integration in Mathematica
Given in my homework I have to compute (by hand)
$$\iint\limits_{x^2+y^2\leq 1}(x^2+y^2)\,\mathrm dx\,\,\mathrm dy.$$
My solution so far:
Let $f(x,y)=x^2+y^2$ and $K=\{(x,y)\in\mathbb{R}^2:x^2+y^2\leq ...
9
votes
2answers
284 views
Derivative from the left and right
I am currently trying to write a script that takes a curve $C$, a starting point $p$ and a direction vector $\vec{v}$ and calculates the path of a beam starting at $p$ in direction $\vec{v}$ when it ...
5
votes
1answer
137 views
Finding ranges of a parameter for which a function is always positive
I have a complex function of a single variable expressed in analytical form, which also depends on a parameter. I would like to have Mathematica show me for which values of the parameter the real part ...
21
votes
3answers
1k views
How to find the period of an arbitrary mathematical function?
Is there a function to find the period of an arbitrary (possibly complex) function in Mathematica?
7
votes
1answer
247 views
6
votes
3answers
524 views
6
votes
3answers
464 views
Using D to find a symbolic derivative
I need to do the following:
Define a function
Take the derivative of this function and have a look at the symoblic representation
Substitute in some values
With the bonus that I want to use the ...
7
votes
1answer
436 views
How to find the smallest root
I have a continuous, differentiable, monotonic, bounded function called F[t]. If t -> Infinity then ...
11
votes
1answer
435 views
Incorrect results for elementary integrals when using Integrate
There is a rather simple integral ($K_0$ is the 0-th order MacDonald function)
$$\int_0^\infty e^{-x \cosh\xi}\, d\xi = K_0(x)$$
which mathematica cannot solve. This even though the documentation ...
9
votes
2answers
389 views
Maximizing a function with assumptions
Using
f[s_] := Log[(s/r)^α ((α - 2) n0 r^α + 2 π Pmax ρ r^2)
/((α - 2) n0 s^α + 2 π Pmax ρ s^2)]/s
When I run the following line:
...
7
votes
2answers
398 views
Integration with vector coefficients
I asked this same question in Mathematics, and it was suggested I might try here. I'm more comfortable with Maple, but if I can get Mathematica to do what I'm after, so much the better.
Basically ...
4
votes
3answers
305 views
Integrating with multiple indicator functions
I am trying to calculate an integral involving multiple indicator functions, such as:
$$ h(u,v,w) = -\int_0^1 J^{\prime\prime}(s) (I_{(0,s]}(u) - s)(I_{(0,s]}(v) - s)(I_{(0,s]}(w) - s)\, ...
7
votes
3answers
1k views
Derivative of real functions including Re and Im
When deriving functions using Re, Im or Arg (and probably some other functions as well), ...
13
votes
3answers
604 views
How to evaluate the 0/0 type limit in Mathematica?
When I use Limit to evaluate the $k \to 0$ limit of
((k + 2) (α^2 - Sqrt[α^4 + k]) + k)/(α^2 - Sqrt[α^4 + k] + 2 k)
If ...
6
votes
5answers
561 views
Trying to prove that $x\sin(\frac{\pi}{x})\ge\pi \cos(\frac{\pi}{x})$ for $x\ge 1$
Consider the function
f[x_] := x Sin[Pi/x]
I want to prove that this function is increasing for $x\ge 1$. This can be done with the first derivative. We have to ...
8
votes
2answers
658 views
13
votes
5answers
626 views
Does $x>0$ imply that $x\in\mathbb{R}$?
Let’s assume I input
Assuming[x > 0, expression]
Is it assumed by Mathematica that $x$ is a real number? Or that the real part of $x$ is positive? Something ...
8
votes
5answers
377 views
simplifying $\frac{\log x^a}{a} = \log x$
If one makes the assumptions $x>0,a>0$, then $\frac{1}{a}\log x^a = \log x$. Thus, in Mathematica, Simplify[1/a*Log[x^a], {a > 0, x > 0}] returns ...
2
votes
1answer
143 views
Checking if first derivative is zero at a given point
I have a function
V[a_, h_, tau_] := (Sqrt[3]/2) h (Sqrt[3] a + h/3 tau)^2
now I want to check, whether its first derivative is zero in a given point. Say for ...
2
votes
1answer
185 views
Integral not simplifying
I specify a function in terms of an integral and then try to evaluate it with Simplify. However, the answer is not really simplified to what it should be.
...
10
votes
5answers
996 views
How can you compute Itō Integrals with Mathematica?
How can you compute Itō Integrals with Mathematica? I tried searching through the documentations but I didn't find anything.
P.S. I was not at all sure how to tag this question. I had to put in at ...
17
votes
1answer
528 views
How can the {x,y,z} points that fall on the outer boundary of a set of values be selected and smoothly surfaced?
For a given set of x,y,z values, that may, or may not form a uniform shape, how can the center of the data cloud be found, and the surface points be located and a solid smooth surface created from ...
2
votes
1answer
340 views
Speeding up a slow indefinite integral
I have found an alternative way to express an old solution:
...
8
votes
4answers
2k views
Finding critical points of a function
Let's say we'd like to find the critical points of the function $f(x)=\sqrt{x-x^2}$. Finding out where the derivative is 0 is straightforward with Reduce:
...
9
votes
2answers
1k views
How to specify assumptions before evaluation?
If I request mathematica evaluate an integral for me, I'll often get a more general ConditionalExpression than I want. Example :
...
3
votes
1answer
390 views
Definite and Indefinite integral give different results for piecewise function
I have the following function:
$$
f(q,y)=
\begin{cases}
\tfrac{11720+p}{37791360} & -11720<p<-7720 \\
0 & \text{True}
\end{cases}
$$
where $p = 443\ y-777600\ \sin^{-1}\left(\frac{q ...
5
votes
3answers
442 views
recursive integration
I am trying to do multiple integrations recursively. For instance, I would like to do the following equation for arbitrary integer $n$:
$\displaystyle R_n(t) = \int_0^t \mathrm dt' R_0(t-t') ...
6
votes
1answer
414 views
Hankel Transform integrals won't work in Mathematica
I'm trying to do this integral, which is shown on the Wikipedia page on the Hankel transformation:
$$\int_0^{2\pi}\mathrm d\varphi\;e^{\mathrm im\varphi}e^{\mathrm ikr\cos(\varphi)}$$
The answer is ...
4
votes
5answers
926 views
Using implicit differentiation to find a line that is tangent to a curve at a point
A few days ago I asked about using differentiation to find a line that is tangent to a curve at a given point. J.M. provided a very elegant way to solve these kinds of problems in Mathematica.
Now ...
8
votes
1answer
360 views
Is there any automatic differentiation package?
I'm wondering if an automatic differentiation package exists for Mathematica.
This is what I mean by automatic differentiation.
