Skip to main content
1-Visitor
November 10, 2017
Solved

Segmented Function

  • November 10, 2017
  • 2 replies
  • 2256 views

Is it possible to define a single function (for example a cam) in segments and then show it in one continuous graph? See the attached example. The reason that I would like to do this as a function rather than an array is that I wish to subsequently repeatedly differentiate it to get from displacement to velocity, acceleration and jerk. Thanks, Karl.

Best answer by Fred_Kohlhepp

you're missing two pieces, look for the yellow highlight.

2 replies

23-Emerald I
November 10, 2017

you're missing two pieces, look for the yellow highlight.

1-Visitor
November 11, 2017

Perfect.Many Thanks, Fred.

25-Diamond I
November 11, 2017

One additional remark, as you are wondering why you don't see a horizontal line at 1.9375 in Segment 5.

You had defined the range theta for the abscissa as 166.5 .. 167.0

If you don't provide a second value, the default step width is 1 and so next value would be 167.5 and is greater than the end value 167. So your "range" consists of one single value (166.5) only. Therefore the plot is a single point at (165.5 // 1.9375). If you look closely (or set the line width at a higher value) you should be able to see that point.

1-Visitor
November 11, 2017
Makes sense. Thanks for clearing that up, Werner. Karl.