MathGroup Archive 2000

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: want to modify NDSolve--molecular dynamics with mathematica


Hi,

you can write your equation with Mod[x[t],a0]
but it will make the InterpolatingFunction[]s
returned by NDSolve[] unusable. Because
x[t] will jump back to for x>a0 and the
interpolation is useless.

You must write your own initial value solver.

Regards
  Jens


"Toshiyuki (Toshi) Meshii" wrote:
> 
> Hello,
> 
> I was wondering whether I can apply NDSolve to molecular dynamics, on the
> standpoint of periodical boundary condition.
> 
> The eqation I want to solve is the simple Newton equation (Let me simplify
> the problem).
>   m D[x, {x,2}] == F
> However, periodical boundary condition makes it difficult to apply NDSolve.
> That is, once
>   0<x[t]<a0
> is not satisfied (a0 is a constant), I have to move the atom so that this
> condition is satisfied.
> In concrete,
>   if x[t]<0  --->  x[t]=x[t]+a0
>   if x[t]>a0  --->  x[t]=x[t]-a0
> and then restart to solve the equation.
> 
> Is there any way to realize this by directly applying NDSolve?
> If not, how can I modify NDSolve?
> 
> -Toshi


  • Prev by Date: Re: Q: Postscript problem with braces "()"
  • Next by Date: Bug in Package Graphics`Graphics` ?
  • Previous by thread: want to modify NDSolve--molecular dynamics with mathematica
  • Next by thread: Re: Re: want to modify NDSolve--molecular dynamics with mathematica