0

I try to implement a population model with age structure in Mma12 using NDSolve to get a numerical solution for my PDE. However, one boundary condition involves an integral, which gives me problems (using either Integrate or NIntegrate).

NDSolve[{D[n[t, a], t] + D[n[t, a], a] == -0.00002*Exp[0.099*t]*
n[t, a],n[0, a] == 100*Exp[-0.0163*(a - 30.8)^2], n[t, 0] == Integrate[
0.1134*Exp[-0.0163*(a - 30.8)^2]*n[t, a2], {a2, 0, 100}]}, n[t, a], {t, 0, 100}, {a, 0, 100}]

In this post they used a trick to avoid the integral, but I don't think I can use it in my case. Any help is appreciated.

Axel
  • 43
  • 3
  • You might find 84978 or 78493 helpful. – bbgodfrey Sep 14 '20 at 22:39
  • Yes, the BC problem in 78493 is basically identical to my situation! Since Mma seems unable to handle this, I tried to understand the method of lines. But in all examples that I found, the approximation used for discretization is for a 2nd order derivative (e.g. Uxx(x,t)), while I only have a first order derivative. So, I would need a different approximation like (u(x+h)-u(x-h))/2h ?! – Axel Sep 24 '20 at 08:05
  • Okay, I just saw that you used in 84978 this approximation for the first derivative. Sorry that I didn't spot that earlier. – Axel Sep 24 '20 at 09:16

0 Answers0