Click here to Skip to main content
15,888,461 members
Home / Discussions / Algorithms
   

Algorithms

 
AnswerRe: Trapezoid interpolation Pin
Ralf Meier7-Feb-17 0:00
mveRalf Meier7-Feb-17 0:00 
GeneralRe: Trapezoid interpolation Pin
Joan M7-Feb-17 0:54
professionalJoan M7-Feb-17 0:54 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier7-Feb-17 1:25
mveRalf Meier7-Feb-17 1:25 
GeneralRe: Trapezoid interpolation Pin
Joan M7-Feb-17 3:10
professionalJoan M7-Feb-17 3:10 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier7-Feb-17 6:57
mveRalf Meier7-Feb-17 6:57 
GeneralRe: Trapezoid interpolation Pin
Joan M7-Feb-17 10:13
professionalJoan M7-Feb-17 10:13 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier7-Feb-17 20:21
mveRalf Meier7-Feb-17 20:21 
GeneralRe: Trapezoid interpolation Pin
Joan M7-Feb-17 20:45
professionalJoan M7-Feb-17 20:45 
Hi again Ralf,

Thank you.

Yes and no, a normal movement will be from x0 (at v0) to xf (at vf) (usually both speeds will be 0).

But, Imagine that while on the path to x0 to xf the user press stop and the motor must stop as soon as possible.
Then I'll have to send the motor at it's nearest possible position and therefore the v0 will be the one it was used at the moment the user pressed the stop button. So a normal movement but with a v0 > 0.

The machine I want to control is a special prototype for cutting and pile paper sheets at a very fast rate, but the worst part here is that the customer has decided to use asynchronous motors and drives to move the axis on the part of the machine I'm in charge... with servomotors this would be super-easy... drives and asynchronous motors offer some problems due to accelerations, inertia... and of course the position, speed, torque loops must be created from scratch as the CNC can't handle them... (well, it could using a virtual axis and using that virtual axis as the master of the asynchronous drive, but the customer doesn't want it).

PS: the strange formula just before the ugly code comes from this page: Help w/ acceleration formula | Physics Forums - The Fusion of Science and Community[^] :

a = Vc/t
a = (Ve-Vo)/t
a = ( (Vo^2 + 2ad)^(1/2) - Vo )/t
at = ( (Vo^2 + 2ad)^(1/2) - Vo )
t = ( (Vo^2 + 2ad)^(1/2) - Vo )/a


You are right so far...

PS2: And a little bit more of information:

This:
taux = (Sqr((2 * a * da) + (v0 * v0)) - v0) / a
      vmax = v0 + (a * taux)
Gives exactly the same than this:
vmax = Sqr((v0 * v0) + 2 * a * (da))


which is wrong...


Joan.

modified 8-Feb-17 3:29am.

GeneralRe: Trapezoid interpolation Pin
Ralf Meier7-Feb-17 21:34
mveRalf Meier7-Feb-17 21:34 
GeneralRe: Trapezoid interpolation Pin
Joan M7-Feb-17 21:46
professionalJoan M7-Feb-17 21:46 
AnswerRe: Trapezoid interpolation Pin
Ralf Meier8-Feb-17 0:33
mveRalf Meier8-Feb-17 0:33 
GeneralRe: Trapezoid interpolation Pin
Joan M8-Feb-17 1:07
professionalJoan M8-Feb-17 1:07 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier8-Feb-17 2:01
mveRalf Meier8-Feb-17 2:01 
GeneralRe: Trapezoid interpolation Pin
Joan M8-Feb-17 8:59
professionalJoan M8-Feb-17 8:59 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier8-Feb-17 10:05
mveRalf Meier8-Feb-17 10:05 
GeneralRe: Trapezoid interpolation Pin
Joan M9-Feb-17 4:26
professionalJoan M9-Feb-17 4:26 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier9-Feb-17 5:32
mveRalf Meier9-Feb-17 5:32 
GeneralRe: Trapezoid interpolation Pin
Joan M9-Feb-17 8:59
professionalJoan M9-Feb-17 8:59 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier9-Feb-17 9:35
mveRalf Meier9-Feb-17 9:35 
AnswerRe: Trapezoid interpolation Pin
Ralf Meier9-Feb-17 20:02
mveRalf Meier9-Feb-17 20:02 
GeneralRe: Trapezoid interpolation Pin
Joan M9-Feb-17 21:49
professionalJoan M9-Feb-17 21:49 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier10-Feb-17 0:06
mveRalf Meier10-Feb-17 0:06 
GeneralRe: Trapezoid interpolation Pin
Joan M10-Feb-17 0:11
professionalJoan M10-Feb-17 0:11 
GeneralRe: Trapezoid interpolation Pin
Ralf Meier10-Feb-17 0:29
mveRalf Meier10-Feb-17 0:29 
QuestionRe: Trapezoid interpolation Pin
Ralf Meier9-Feb-17 20:08
mveRalf Meier9-Feb-17 20:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.