Calculating the polynomial coefficients and interpolation

The polynomials of the fifth order for determination of the slave position s as a function of the master position t in the ranges of non-constant speed are of the form:

They are defined by six boundary conditions. At the start and end points, the position s and the first (speed v) and second derivations (acceleration a) must agree with the neighbouring intervals. The second derivation, i.e. the acceleration, should be equal to 0 on the left and right.

The figure below shows 3 successive intervals which are used to calculate the polynomial coefficients:

Master-slave intervals of a cam table
Master-slave intervals of a cam table

Below, a camming table of the POLY5-LINE type is calculated as an example and is presented with the position, speed and acceleration in the individual intervals.

Tablename = poly5line_2  # Table name

Table-ID  = 402  # Table-ID

Tabletype = 7  # Table type

Function type = 5  # Interpolation type, 5 = POLY5-LINE

Lines = 10 # Number of lines

Begintable  # Beginning of table

100000 0

200000 400000

400000 1600000

670000 1800000

900000 300000

980000 1700000

1500000 3400000

1800000 2700000

2700000 1700000

3000000 2600000

EndTable

In the first diagram, the intervals with polynomials are shown in red and the intervals with constant speed are shown in blue:

Example of cam with POLY5-LINE
Example of cam with POLY5-LINE