extrapolating vectors?

I want to extrapolate the positions and rotations of some object for a game mechanic I want to try out in where a NPC predicts what is going to happen in the near future. I know there are several extrapolation formulas used for multiplayer networking and that these formulas are used in economics. But I want to utilize this in my game design and therefor I thought I would be handy to get some information about the subject first. What has been done in this field and does anyone know any formulas that can predict a point in space based on a sequence (between maybe 10 and 20 frames or so) of positions. If I can apply it for positions I can probably also apply it for rotations.

Any ideas?

A solution I just thought up after seeing your post is to record the angles and radii of the last twenty positions relative to each other and then search further back along the path for more positions with the same twenty relative angles and radii (add some tolerance), then copy and modify the following positions for your projected path. So basically it would be a path snippet recognition algorithm :slight_smile:

I dunno, maybe a little overkill?.

With the above method you could even predict a circle or a sine wave. (and we all know how pesky bandits like to zigzag when escaping a hail of bullets)

Disclaimer - I don’t really have a clue what I’m doing…