# Blending function

Hi friends
We have the portal robot with two axis X and Y. For each axis we have the servo drive that we can write in the trajectory values every 2
msec.
From this trajectory the drive will calculate the velocity and acceleration. If we have two points P1 with coordinates X1 and Y1 and P2 with coordinates X2 and Y2 we have to find the blendig function between these two points. It would be the function P(t) which is a polynom of the 5th order with coeficients C0, C1, C2, C3 and C4. The coeficients are known if we know the velocity, acceleration and coordinates of the points P1 and P2.
My question is: How can I get values X(t) and Y(t) at the moment t if I have the function P(t).
For example at the moment t=2msec the value of the polynom would be:
P(2msec) = C0 + C1*2msec + C2*(2msec)^2 + C3*(2msec)^3 + C4 * (2msec)^4 + C5 * (2msec)^5
How can I get values X(2msec) and Y(2msec)?
Thanks.
Leo
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

This isn't clear. What does P(t) represent? A position in one dimension? Is P(t) supposed to return a x(t) and y(t)? If so then why mess with P(t) and just figure out how to get from x0,y0 to x1,y1 in a given amount of time?
x(t)=A0+A1*t+A2*t^2+A3*t^3+A4*t^4+A5*t^5 y(t)=B0+B1*t+B2*t^2+B3*T^3+B4*t^4+B5*t^5
calculating a motion profile from x(0), y(0) to x(T),y(T) is easy if you know T. You know the inital conditions for the two polynomials and you know the final conditions, the problem is what should T be to keep from exceeding velocity, acceleration and jerk limts. That requires a little math. That is also why not many people use 5th or 7th order controllers. If you have a graphical tool then you can adjust the time and check the speeds, accelerations etc. but this requires everything be worked out ahead of time. This works for many robotic applications because everything is known ahead of time.
I am assuming you are still working on your x, y robot. I have seen your posts on other forums.
Peter Nachtwey
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

Hi Peter
http://www.cim.mcgill.ca/~haptic/publications.html#Y1993
this publication: Lloyd, J. E and Hayward, V. 1991. Real-Time Trajectory Generation Using Blend Functions
Can you explain me on page 2 (785) what is X(t) on the graph? You can read path displacemant. I think this is vector distance. And how can I calculate for every axis distance if I have distance for vector?(in time)
Regards
Leo
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

That depends on a lot of things. If your system has two independent axis, then you might just work out the x and y velocities needed to be in the right place on each axis at the right time. Basically, you just figure out how long the movement should take, and the velocity in each direction is simply the change in location divided by time.
If your system is a more complex system with interdependent axis, then you should probably work out the model for the system, and base your movements on that.
If you assume that you will have upper level controls which will tell the system where to go, then lower level controls can take over with working out where the robot should be every few milliseconds, and reading its location. It then would use a PID or similar control to adjust itself so that it arrived at the right spot at the right time. Note that reading the location of the robot may take more than 2 ms.
You can use servo or stepper motors with feedback in order to control the movement and position fairly accurately.
Michael
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
On 22 Mai, 05:46, "Herman Family"

I know how to make this with software and hardware. We use 1 industrial PC, Ethercat and servo drives. I don't have any problem with software and hardware. I have problem with algorithm.
Regards Leo
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

Why not the obvious? theta=arctan((y1-y0)(/x1-x0)) x(t)=cos(theta)*p(t); y(t)=sin(theta)*p(t);
Peter Nachtwey
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

Are you sure that theta is constant? I am not sure.
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

HOW AM I SUPPOSED TO KNOW. YOU ARE THE ONE ASKING THE QUESTIONS. WHAT DO YOU MEAN YOU AREN'T SURE? That is the problem I have with your posting. You don't know enough to ask the right questions or provide the right data for us to provide an intelligent answer. Is the path between point x0,x0 and x1,x1 a straight line or not? Don't you think this makes a difference to the answer? If the path is a straight line then the answer is as simple as what I provided. If the path is a curve then the calculations get difficult quickly. Since you don't understand the question I doubt you would understand the answer. It looks like you are having problems with grasping the basics like point to point moves using 5th order polynomials.
I have seen the posts on sci.math. There you say you have a problem with acceleration. Limiting acceleration while using 5th order polynomials is a problem but if you are accelerating from one constand speed to another the peak acceleration will be 1.5 times the average acceleration. You can calculate the average acceleration using simple second order math.
Peter Nachtwey
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

I wrote:
It would be the function P(t) which is a polynom of the 5th order with coeficients C0, C1, C2, C3 and C4
I think, my question is very clear.
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

So how does one get a x and y component from your function of P(t)? P(t) says nothing about direction. So it isn't clear and if you don't understand that you will not understand the answer just like you didn't understand my answer about superimposed moves earlier this year.
Peter Nachtwey
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

I got a .pdf in the mail from leo that describe what I think he wants to do. P(t) describe the motion of a part on a conveyor. Assume the conveyor moves at a constant speed. There is a 4 axis robot that must make contact and follow the position of the part on the conveyor. The robot has a rotate, a shoulder, a fore arm for placement and a wrist to keep the tool vertical. I think leo wants to know how the robot can match the position of the part while moving. This isn't what I had imagined the math is still complicated. The .pdf leo sent me is very old and uses a technique called blending to blend the transition between one motion path and another motion path. The blending function is a 5th or hermite blending function that returns values from 0 to 1 over the period of the blending period. The blending function is a 5th order so the function will be continuous after taking the derivative twice so there will be a smooth transition for the velocity and acceleration as well as the position. There is some formulas about mapping the linear position of the part to the rotational positions of the robot but this doesn't seem to be the main thrust of the article. The article seem to be more concerned with the motion path the robot must take as a function of the part position and velocity
Leo , I didn't see a page two. The pdf file seems to start at page 370 or something. I didn't see the number 785. The text does number the equations so use the equation numbers.
This is still very complicated and too much to explain on a user group.
Peter Nachtwey
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

Two more things. 1. It is the distance over which the blending occurs that affects how rounded ( the acceleration ) the transition will be. 2. Blending is just one technique. Super imposed moves and splicing are two other techniques to do the same thing. They all have advantages and disadvantages. I wouldn't have used blending because two motion segments need to be calculated and the blending function. Super imposed moves require that two functions must be computed. Splicing ends one function at the same position, velocity and acceleration that are the initial conditions for the next segment. This means the blending .pdf may not apply. You really should ask the robot control manufacturer about the algorithm they used.
Peter Nachtwey
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

I think Peter you don't have enough experience with robots. This blending function is very good (you can see in .pdf mathematical prove why.I try to explain this .pdf and I am asking for help.
Leo
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

Peter Nachtwey
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

Can you explain me Super imposed moves technique?
Thanks
Leo