# Another non-hom. diffeq

1. Jul 15, 2011

Is there an analytic solution for:

y"(c+dx+ex^2) + ay + b = 0,

y (x=0) = Ts
y'(x=L) = 0

where a,b,c,d,e are all constants?

2. Jul 15, 2011

### pmsrw3

I don't understand this DE. Are you saying that the second derivative of y, evaluated at c+dx+ex^2, is equal to -ay(x) - b, where y is now evaluated at x? What physical mechanism could give such a remote relationship? What about the domain? Over what range of x is this equation supposed to hold? Are c, d, and e such that c + dx + ex^2 precisely maps this range to itself? If not, how do we deal with the regions where y''(c+dx+ex^2) is defined but y(x) isn't, or vice versa?

3. Jul 15, 2011

Good questions.

I am investigating the properties of a sensor I am making, which involves the simultaneous interactions of convective heat transfer, joule heating, and potential theory. I am trying to build an analytic model that approximates all of these physics for simple geometries, namely a pipe with a pipe thickness. The major contributing factor is that the pipe material's resistance changes with temperature.

Basically here is what happens for the simple geometry of a coaxial setup:
1. Inside pipe surface is connected to ground, outside pipe surface is given a voltage.
2. Fluid goes through pipe.
3. Current flows from the outer pipe surface to the inner surface.
4. The pipe heats up.
5. The fluid advects some heat downstream.
6. A downstream section of pipe touches sligtly hotter fluid because of the advection.
7. This downstream section of pipe heats up a little bit more.
8. The resistance of the downstream pipe section increases.
9. The current in the downstream section is reduced.
10. Less heat is produced in the downstream section.
11. Less heat is conducted into the fluid...
12. Less heat is advected...
etc...

So there is some balance that exists between all of this. I've already solved the heat transfer math; all it needs is heat flux as a function of the inner pipe temperature. This looks like

q"(Ts) = A*Ts + B

making the simplification that the resistance changes linearly with temperature.

Now, finding q"(Ts) for a coaxial setup is easy.
1. The e-field is the same everywhere radially AND axially. The E-field is E(z)=V/(Ro-Ri) where z is the distance in the radial direction from Ri to Ro. Actually, this is a constant, so E=V/(Ro-Ri) (z isn't needed as a variable).

Assuming that the pipe is insulated T'(z=Z)=0 and that T(z=0)=Ts, the diffEQ is the one you helped me solve before:

T" + AT + b = 0. Oh yeah, big Z is equal to Ro-Ri to make things easier.
Anyway, the heat flux turns out to be

q"(Ts) = Aj*Ts + Bj
Aj = k*a/(sqrt(|a|) * tan(h)(sqrt(|a|Z)
Aj = k*b/(sqrt(|a|) * tan(h)(sqrt(|a|Z)
a = alpha/k*E(z)^2
b = beta/k*E(z)^2

where

E(z) = V/(Ro-Ri) const.

and alpha is in [Siemens]/[m*K] and beta is in [Siemens]/[m]

Simple and neat solution.

Now I want to explore the geometry when, instead of there being an inner and outer conductor in the pipe, the pipe is split in half (like a C) and the conductors as placed on the edges of the C. I call this "split". The e-field is only the same axially, no longer radially. Therefore, z must come into play somehow. In this case, E(z)=(pi*V)/(Ri+z*Z) (or something like this, my notes are in my office).

The DiffEQ becomes

T" + a/(c+dz+ez^2)*T + b/(c+dz+ez^2) = 0

because of the squaring action of E(z), or more simply

T"*(c+dz+ez^2) + a*T + b = 0

where I am reusing a through e as dummy variables.

That's where it comes from. How would I go about solving this? The domain of z must be > 0 because it is a real distance (pipe thickness). a can be positive or negative, and b,c,d,e > 0 always. T > 0 [Kelvins]

4. Jul 15, 2011

### pmsrw3

I think what's confusing me is that you never explicitly give the argument of T (or y in the original). Originally you wrote
$$y^{\prime\prime}\left(c+dx+ex^2\right) + ay + b = 0$$

which would ordinarily be understood, not as y'' multiplied by c+dx+ex^2, but y'' evaluated at c+dx+ex^2. But If I understand correctly what you just wrote, your DE is actually

$$(c+dz+ez^2)T^{\prime\prime}\left(x\right) + a*T\left(x\right) + b = 0$$

where x is along the pipe, and z is perpendicular to the pipe (and so would y be -- I'm not sure why it's OK to leave that out).

There are a lot of reasons why this looks wrong to me, so I'm guessing I still don't understand correctly.

5. Jul 15, 2011

it's actually

(c + dz + ez^2)*T"(z) + a*T(z) + b = 0
T(z=0) = Ts
T'(z=Z) = 0

Don't let my explanation confuse you; forget the axial direction x for now; right now I'm solving a one dimensional ODE (radially only) with lots of constants, shown above.

I'm scared of the word "Bessel", but it might have to come into play here. This is where I have no experience.

Last edited: Jul 15, 2011
6. Jul 15, 2011

### pmsrw3

Oh, boy, you're going to love this. No Bessel functions, but -- are you ready?

$$T(z)\to \left((b+a \text{Ts}) \left((a+2 e) (c+Z (d+e Z)) \, _2F_1\left(\frac{7 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(7-\frac{\sqrt{e (e-4 a)}}{e}\right);3;-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}\right)-2 \left(d^2-4 c e\right) \, _2F_1\left(\frac{3 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(3-\frac{\sqrt{e (e-4 a)}}{e}\right);2;-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}\right)\right) G_{2,2}^{2,0}\left(-\frac{4 e (c+z (d+e z))}{d^2-4 c e}| \begin{array}{c} \frac{1}{4} \left(5-\frac{\sqrt{e-4 a}}{\sqrt{e}}\right),\frac{1}{4} \left(\frac{\sqrt{e-4 a}}{\sqrt{e}}+5\right) \\ 0,1 \end{array} \right)+8 e \left((b+a \text{Ts}) (c+z (d+e z)) \, _2F_1\left(\frac{3 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(3-\frac{\sqrt{e (e-4 a)}}{e}\right);2;-\frac{4 e (c+z (d+e z))}{d^2-4 c e}\right)-b c \, _2F_1\left(\frac{3 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(3-\frac{\sqrt{e (e-4 a)}}{e}\right);2;-\frac{4 c e}{d^2-4 c e}\right)\right) G_{2,2}^{2,0}\left(-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}| \begin{array}{c} \frac{1}{4}-\frac{\sqrt{e-4 a}}{4 \sqrt{e}},\frac{1}{4} \left(\frac{\sqrt{e-4 a}}{\sqrt{e}}+1\right) \\ 0,0 \end{array} \right)+b \left(2 \left(d^2-4 c e\right) \, _2F_1\left(\frac{3 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(3-\frac{\sqrt{e (e-4 a)}}{e}\right);2;-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}\right)-(a+2 e) (c+Z (d+e Z)) \, _2F_1\left(\frac{7 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(7-\frac{\sqrt{e (e-4 a)}}{e}\right);3;-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}\right)\right) G_{2,2}^{2,0}\left(-\frac{4 c e}{d^2-4 c e}| \begin{array}{c} \frac{5}{4}-\frac{\sqrt{e-4 a}}{4 \sqrt{e}},\frac{1}{4} \left(\frac{\sqrt{e-4 a}}{\sqrt{e}}+5\right) \\ 0,1 \end{array} \right)\right)/\left(a \left(8 c e \, _2F_1\left(\frac{3 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(3-\frac{\sqrt{e (e-4 a)}}{e}\right);2;-\frac{4 c e}{d^2-4 c e}\right) G_{2,2}^{2,0}\left(-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}| \begin{array}{c} \frac{1}{4}-\frac{\sqrt{e-4 a}}{4 \sqrt{e}},\frac{1}{4} \left(\frac{\sqrt{e-4 a}}{\sqrt{e}}+1\right) \\ 0,0 \end{array} \right)+\left((a+2 e) (c+Z (d+e Z)) \, _2F_1\left(\frac{7 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(7-\frac{\sqrt{e (e-4 a)}}{e}\right);3;-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}\right)-2 \left(d^2-4 c e\right) \, _2F_1\left(\frac{3 e+\sqrt{e (e-4 a)}}{4 e},\frac{1}{4} \left(3-\frac{\sqrt{e (e-4 a)}}{e}\right);2;-\frac{4 e (c+Z (d+e Z))}{d^2-4 c e}\right)\right) G_{2,2}^{2,0}\left(-\frac{4 c e}{d^2-4 c e}| \begin{array}{c} \frac{5}{4}-\frac{\sqrt{e-4 a}}{4 \sqrt{e}},\frac{1}{4} \left(\frac{\sqrt{e-4 a}}{\sqrt{e}}+5\right) \\ 0,1 \end{array} \right)\right)\right)$$

Here's the same thing in Mathematica's native form (useful because the names identify special functions you've probably never heard of):

$$T[z] -> ((b + a Ts) (-2 (d^2 - 4 c e) Hypergeometric2F1[( 3 e + Sqrt[e (-4 a + e)])/(4 e), 1/4 (3 - Sqrt[e (-4 a + e)]/e), 2, -((4 e (c + Z (d + e Z)))/(d^2 - 4 c e))] + (a + 2 e) (c + Z (d + e Z)) Hypergeometric2F1[(7 e + Sqrt[e (-4 a + e)])/( 4 e), 1/4 (7 - Sqrt[e (-4 a + e)]/e), 3, -((4 e (c + Z (d + e Z)))/( d^2 - 4 c e))]) MeijerG[{{}, {1/ 4 (5 - Sqrt[-4 a + e]/Sqrt[e]), 1/4 (5 + Sqrt[-4 a + e]/Sqrt[e])}}, {{0, 1}, {}}, -(( 4 e (c + z (d + e z)))/(d^2 - 4 c e))] + 8 e (-b c Hypergeometric2F1[(3 e + Sqrt[e (-4 a + e)])/(4 e), 1/4 (3 - Sqrt[e (-4 a + e)]/e), 2, -((4 c e)/(d^2 - 4 c e))] + (b + a Ts) (c + z (d + e z)) Hypergeometric2F1[(3 e + Sqrt[e (-4 a + e)])/( 4 e), 1/4 (3 - Sqrt[e (-4 a + e)]/e), 2, -((4 e (c + z (d + e z)))/( d^2 - 4 c e))]) MeijerG[{{}, {1/4 - Sqrt[-4 a + e]/( 4 Sqrt[e]), 1/4 (1 + Sqrt[-4 a + e]/Sqrt[e])}}, {{0, 0}, {}}, -((4 e (c + Z (d + e Z)))/(d^2 - 4 c e))] + b (2 (d^2 - 4 c e) Hypergeometric2F1[(3 e + Sqrt[e (-4 a + e)])/( 4 e), 1/4 (3 - Sqrt[e (-4 a + e)]/e), 2, -((4 e (c + Z (d + e Z)))/(d^2 - 4 c e))] - (a + 2 e) (c + Z (d + e Z)) Hypergeometric2F1[(7 e + Sqrt[e (-4 a + e)])/( 4 e), 1/4 (7 - Sqrt[e (-4 a + e)]/e), 3, -((4 e (c + Z (d + e Z)))/( d^2 - 4 c e))]) MeijerG[{{}, {5/4 - Sqrt[-4 a + e]/( 4 Sqrt[e]), 1/4 (5 + Sqrt[-4 a + e]/Sqrt[e])}}, {{0, 1}, {}}, -((4 c e)/( d^2 - 4 c e))])/(a (8 c e Hypergeometric2F1[( 3 e + Sqrt[e (-4 a + e)])/(4 e), 1/4 (3 - Sqrt[e (-4 a + e)]/e), 2, -((4 c e)/( d^2 - 4 c e))] MeijerG[{{}, {1/4 - Sqrt[-4 a + e]/( 4 Sqrt[e]), 1/4 (1 + Sqrt[-4 a + e]/Sqrt[e])}}, {{0, 0}, {}}, -((4 e (c + Z (d + e Z)))/( d^2 - 4 c e))] + (-2 (d^2 - 4 c e) Hypergeometric2F1[( 3 e + Sqrt[e (-4 a + e)])/(4 e), 1/4 (3 - Sqrt[e (-4 a + e)]/e), 2, -((4 e (c + Z (d + e Z)))/(d^2 - 4 c e))] + (a + 2 e) (c + Z (d + e Z)) Hypergeometric2F1[( 7 e + Sqrt[e (-4 a + e)])/(4 e), 1/4 (7 - Sqrt[e (-4 a + e)]/e), 3, -((4 e (c + Z (d + e Z)))/(d^2 - 4 c e))]) MeijerG[{{}, {5/4 - Sqrt[-4 a + e]/(4 Sqrt[e]), 1/4 (5 + Sqrt[-4 a + e]/Sqrt[e])}}, {{0, 1}, {}}, -(( 4 c e)/(d^2 - 4 c e))]))$$

7. Jul 15, 2011