Advertisement
Guest User

Untitled

a guest
Jul 25th, 2014
208
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. NDSolve[
  2. {y''[t] == 10, y[0] == 0, y'[0] == 0},
  3. {y},
  4. {t, 0, 1},
  5. Method -> {"EventLocator",
  6. "Event" :> {y[t] - 2, y[t] - 1},
  7. "EventAction" :>(*{Throw[Print["i=",1],"StopIntegration"],Throw[
  8. Print["i=",2],"StopIntegration"]}*)
  9. Table[Throw[Print["i=", i], "StopIntegration"], {i, 3}]
  10. }
  11. ];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement