I am trying to take the output from NDSolve
and create a variable equal to the solution except for a certain range of values. Here is the code I am trying to use but it does not work. Can anyone suggest why it is not working or what I need to do to fix it? I could have sworn it worked at one point and the just stopped working.
Test = If[0 <= z < ts, BCr[z], Tbl];
The variables ts
and Tbl
are defined constants. BCr[z]
is found using NDSolve
all of which are good but the new variable Test
will not work. I have tried many different variations of this code and nothing seems to work.
Piecewise
in the documentation. $\endgroup$NDSolve
may not be producing an answer. Alternatively, you may have forgotten to define one of your variables. Check for these, correct any errors, restart Mathematica, and run again. By the way, it is not good practice to begin variable names with capital letters. $\endgroup$Test[z_]:=...
but your code works with no modifications. $\endgroup$