Advertisement
Guest User

Untitled

a guest
Jul 25th, 2016
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. f[x_] = Piecewise[{
  2. {1/2 x, 0 <= x <= 2},
  3. {-5 x^2 + 31 x - 41, 2 <= x <= 4},
  4. {-3/2 x + 9, 4 <= x <= 6},
  5. {3 x - 18, 6 <= x <= 8},
  6. {-3/2 x + 18, 8 <= x <= 10}}];
  7.  
  8. g[x_] = Piecewise[{
  9. {f[x - 1/5], f'[x] < 0},
  10. {f[x + 1/5], f'[x] > 0}}];
  11.  
  12. Plot[
  13. {f[x], g[x]},
  14. {x, 0, 10},
  15. AxesLabel -> {x, y},
  16. PlotStyle -> {Dashed, Thick}]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement