Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I recall that it is possible to specify which independent variable is the "time" variable in NDSolve, but I can't find it documented anywhere. Does anyone recall how it works?

I'm getting the following error because (I believe) NDSolve is confused about which is the time variable:

NDSolve::bcedge: Boundary condition [...] is not specified on a single edge 
of the boundary of the computational domain.

I think this is because my initial condition is inside (not an extremum of) the (time) domain of the interpolating function that specifies it.

Update:

TemporalVariable is an option of NDSolve`MethodOfLines. Therefore, it does not work directly as an option in NDSolve, and should be called in the following manner:

Method ->
  {
    "MethodOfLines",
    "TemporalVariable" -> t
  }

However, this did not solve my problem (see the comments).

share|improve this question
3  
It will increase your chances for getting an answer if you post an example differential equation that has this problem. I don't recall how to do this, but I might try to figure out if there's an equation to test on. Otherwise this is the place to search for advanced NDSolve functionality like this. –  Szabolcs Jun 27 at 3:41
1  
It looks like it's a sub-option called TemporalVariable, check the link from my previous comment, I found it there. Based on it you should be able to figure out how to use it precisely (I'm not sure). –  Szabolcs Jun 27 at 3:45
    
@Szabolcs, thanks. I will edit and show how TemporalVariable is used. However, it didn't fix my problem. I'm trying to figure out how to post it, but has six coupled pdes, boundary conditions, and initial conditions that are large InterpolatingFunctions. I saved the equations to an m-file that was nearly 50 MB. Maybe I'll be able to find a more minimal MWE. –  Rico Picone Jun 27 at 15:21
2  
Just a suggestion: how to specify the temporal variable is a good question and it is not that easy to find in the documentation. If you are willing to edit this question and make it clearly about this topic, then post an answer yourself with a short example, people will definitely appreciate it. There will be people searching for this. You can still ask another question about your actual practical problem. Of course you don't have to do this, but if you do, future visitors will definitely find it useful ;) –  Szabolcs Jun 27 at 15:45
    
Thanks for the edit, @Szabolcs. If I get some more time I'll do what you suggest. –  Rico Picone Jun 30 at 2:18

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.