Intereting Posts

Does convergence in H1 imply pointwise convergence?
Circle on sphere
Integrating $\int\frac{xe^{2x}}{(1+2x)^2} dx$
How can I use residue theory to verify this integral formula?
presentation of the direct sum of commutative rings / algebras
Compute: $\int_{0}^{1}\frac{x^4+1}{x^6+1} dx$
Does an equivalence of $G$-sets and $H$-sets imply an isomorphism of $G$ and $H$?
Extinction probabilities of binomial tends to Poisson distribution
Prove that $f′(x)=f′(0)f(x)$ derivatives
For fixed $z_i$s inside the unit disc, can we always choose $a_i$s such that $\left|\sum_{i=1}^n a_iz_i\right|<\sqrt3$?
Find the Area of the ellipse
Eigenvalues of matrix with entries that are continuous functions
Non-orthogonal projections summing to 1 in infinite-dimensional space
How can I deduce $\cos\pi z=\prod_{n=0}^{\infty}(1-4z^2/(2n+1)^2)$?
Inertia group modulo $Q^2$

This is what I worked out:

Let $y = (1 + x^2)^x$ and let $a = 1 + x^2$

Then, by the chain rule of differentiation:

- Determine whether $\sum_{n=1}^\infty \frac {(-1)^n|\sin(n)|}{n}$ converges
- Let $f(x)$ be differentiable at $\mathbb R$, s.t $|f^\prime (x)| \le 6$ . Its given that $f(1)=20$, and $f(9)=68$ , prove that $f(7)=56$.
- Calculating $\lim_{x\to-\infty}\left(\sqrt{4x^2-6}-\sqrt{4x^2+x}\right)$
- Does $\sum_{n\ge1} \sin (\pi \sqrt{n^2+1}) $ converge/diverge?
- Why is the composition of smooth multivariable functions smooth?
- What is the average length of 2 points on a circle, with generalizations

$\frac{dy}{dx} = \frac{dy}{da}\cdot\frac{da}{dx} = a^x\cdot ln(a) \cdot 2x$

$\frac{dy}{dx} = (1 + x^2)^x \cdot ln(1 + x^2) \cdot 2x $

But when I try to verify the result on WolframAlpha, I get this.

What have I done wrong?

- Does the series $\sum_{n = 1}^{\infty}\left(2^{1/n} - 1\right)\,$ converge?
- What is the minimum value of $(1 + a_1)(1 + a_2). . .(1 + a_n)$?
- Calculate integrals involving gamma function
- Different definitions of trigonometric functions
- Understanding the relationship between differentiation and integration
- Does $\sqrt{x}$ have a limit for $x \to 0$?
- Proof of Dirac Delta's sifting property
- Interesting closed form for $\int_0^{\frac{\pi}{2}}\frac{1}{\left(\frac{1}{3}+\sin^2{\theta}\right)^{\frac{1}{3}}}\;d\theta$
- $\int_{-\infty}^{+\infty}\frac1{1+x^2}\left(\frac{\mathrm d^n}{\mathrm dx^n}e^{-x^2}\right)\mathrm dx$ Evaluate
- A sufficient condition for differentiability of a function of several variables in terms of differentiability along paths.

The problem is, that $y$ does not only depend on $a$, but also on $x$. Note that you have $y = a^x = g(a,x)$, that is $y$ is not a function of $a$, you have $g(a(x), x)$, not $g(a(x))$, as you must have for an application of the one variable chain rule.

What you can do are two different things:

(1) If you know the multivariable chain rule, you can use it, giving

$$ \frac{dy}{dx} = \frac{\partial y}{\partial a}\frac{da}{dx} + \frac{\partial y}{\partial x} $$

(2) If you do not know it (or are not allowed to use it anyway), then look at $\log y = x\log(1+x^2)$. By the (single-variable) chain and the product rule, you get

$$ \frac{y’}y = (\log y)’ = \bigl(x\log(1+x^2)\bigr)’ = \log(1 + x^2) + \frac x{1+x^2} \cdot 2x $$

Your mistake here is that you have used a formula where $a$ is taken to be a constant. So if $a$ is a variable like your case, you cannot use that formula anymore.

Better use this:

$$y=(1+x^2)^x$$

$$\ln y=\ln (1+x^2)^x$$

$$\ln y=x\ln (1+x^2)$$

$$\frac{y’}{y}=\ln (1+x^2)+\frac{2x^2}{1+x^2}$$

$$y’=(1+x^2)^x\left(\ln (1+x^2)+\frac{2x^2}{1+x^2}\right)$$

In case you still want to substitute, use the multivariable chain rule as mentioned by martini.

I think you have a wrong thought about the composition you made! 🙂 A more general form of your function is

$$y = {\left[ {f(x)} \right]^x}$$

Can you write this in form of a composition? I don’t think so! The only way is to take the derivative directly! Hence you can get

$$\eqalign{

& \ln y = x\ln f(x) \cr

& {{y’} \over y} = \ln f(x) + x{{f'(x)} \over {f(x)}} \cr

& y’ = \left( {\ln f(x) + x{{f'(x)} \over {f(x)}}} \right)y \cr

& \,\,\,\,\,\, = \left( {\ln f(x) + x{{f'(x)} \over {f(x)}}} \right){\left[ {f(x)} \right]^x} \cr} $$

In order to calculate $\frac{d}{dx}\left(\left(1+x^2\right)^x\right)$ then this expression can be placed into the form

\begin{align}

\frac{d}{dx} \left(\left(1+x^2\right)^x\right) &= \frac{d}{dx}\left[ e^{x \, \ln(1+x^2)} \right] \\

&= e^{x \, \ln(1+x^2)} \, \left[ x \, \frac{d}{dx} \ln(1+x^2) + \ln(1+x^2) \right] \\

&= (1+x^2)^{x} \, \left[ \frac{2 \, x^2}{1+x^2} + \ln(1+x^2) \right]

\end{align}

The rule you are using is only valid for *constant* $a$.

It is generally true for functions $f$ and $g$ of $x$ that

$$\left(f^g\right)’ = gf^{g-1}\cdot f’ + f^g\log f\cdot g’$$

(you can derive this by taking logs and then differentiating, and rearranging the result).

**Addendum:** I would always encourage my students to memorize this. It’s actually quite easy, if you look at the two pieces being added up. The first piece $$\underbrace{gf^{g-1}}\cdot f’$$ is like the rule for constant exponents, and the second piece $$\underbrace{f^g\log f}\cdot g’$$ is like the rule for constant bases. If either $f$ or $g$ is really constant, then the corresponding $f’$ or $g’$ is zero and so one of the terms disappears, leaving you with the classical formula for constant base or constant exponent.

**Addendum 2:** Here is the simple derivation. We seek $y’$, given that $y=f^g$ (here $f$ and $g$ are functions of $x$ and the “prime” denotes differentiation with respect to $x$).

$$y=f^g$$

$$\log y = g\cdot\log f\tag{take logs}$$

$$(\log y)’ = (g\cdot\log f)’\tag{take deriv.}$$

$$\frac{y’}y = (g\cdot\log f)’\tag{deriv. of $\log y$}$$

$$\frac{y’}y = g\cdot(\log f)’ + g’\cdot\log f\tag{product rule}$$

$$\frac{y’}y = g\cdot\left(\frac{f’}f\right) + g’\cdot\log f\tag{deriv. of $\log f$}$$

$$y’ = \frac{gy}f \cdot f’ + y\log f\cdot g’\tag{mult. by $y$, rearrange}$$

$$y’ = \frac{gf^g}f\cdot f’ + f^g\log f\cdot g’\tag{defn. of $y$}$$

$$y’ = \boxed{gf^{g-1}\cdot f’ + f^g\log f\cdot g’}\tag{combine powers of $f$}$$

- Prove $e^x, e^{2x}…, e^{nx}$ is linear independent on the vector space of $\mathbb{R} \to \mathbb{R}$
- On sort-of-linear functions
- If and only if, which direction is which?
- Duality of $L^p$ and $L^q$
- Combinatorial Identity $(n-r) \binom{n+r-1}{r} \binom{n}{r} = n \binom{n+r-1}{2r} \binom{2r}{r}$
- $\arcsin$ written as $\sin^{-1}(x)$
- Divisibility of $2^n – 1$ by $2^{m+n} – 3^m$.
- Why is a projection matrix symmetric?
- If I generate a random matrix what is the probability of it to be singular?
- Disjoint Refinement
- On the Cayley (conformal) transform
- How do I show that a holomorphic function which satisfies this bound on reciprocals of integers is identically zero?
- Diagonal $\Delta = \{x \times x : x \in X \}$ closed in $X \times X$ implies that $X$ is Hausdorff
- Can anyone explain the intuitive meaning of 'integrating on both sides of the equation' when solving differential equations?
- Higher order corrections to saddle point approximation