Consider some function
function[mass_,lifetime_]:=NDSolve[{equations[mass,lifetime], initialconditions},functions,{t,t0,tmax}]
Let us assume that there is some kind of numeric instability in this function related to the syntax I used. Namely, for some values of parameters (like mass = 0.05, lifetime = 0.03), it is evaluated without any problems (apart from some warnings which may be neglected), but for some very similar values (like mass = 0.05, lifetime = 0.0301) it returns an error like
NDSolve::mxst: Maximum number of 50000 steps reached at the point t ==
0.00521324.
I need to make a table
table = Flatten[Table[{mass,lifetime,function[mass,lifetime]},{mass,massvalues},{lifetime,lifetimevalues}],{2,1}]
Is it possible to re-define the table such that rows with the error will be marked somehow?
Like
tableModified = Flatten[Table[{mass,lifetime,label,function[mass,lifetime]},{mass,massvalues},{lifetime,lifetimevalues}],{2,1}]
for which label = 1
if the mentioned error has not occurred and label = 0
if the error has occurred?