Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6087095
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T11:49:52+00:00 2026-05-23T11:49:52+00:00

I am working on a piece of software written in Java that uses some

  • 0

I am working on a piece of software written in Java that uses some processing.core library classes and simpleopenni to track a user’s hand with the XBOX Kinect.

What I am trying to figure out is how to determine when a user’s hand movement changes direction abruptly.

What I have at my disposal currently is an array of PVectors (essentially a vector of x,y,and z coordinates: A point in 3d space) that record the user’s hand position for the past 30 frames or so.

I imagine that there must be a way to obtain a value that represents the amount of directional change in nearly real-time given the most recent few points recorded. Maybe fit a curve and take some derivatives?

Ideally the solution should not be very computationally expensive, as I am trying to implement a real-time worthy solution.

Any direction that you can offer will be greatly appreciated!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T11:49:53+00:00Added an answer on May 23, 2026 at 11:49 am

    Let the position now (that is, 0 frames ago) be (x0, y0, z0)
    Let the position n frames ago be (xn, yn, zn).
    Let the position 2n frames ago be (xm, ym, zm).

    Then the change in position between frames 2n and n is (xn-xm, yn-ym, zn-zm).
    You can think of this as the average velocity during those n frames.

    And the change in position between n and now is (x0-xn, y0-yn, z0-zn).
    This represents the average velocity during the next n frames.

    Now you have the velocity for the n frames that ended n frames ago, and you have the velocity for the n frames that just ended now.

    The change in velocity during the last n frames must be the difference between those two vectors. For each coordinate:

    Ax = (x0-xn) - (xn-xm) = x0 -2xn + xm
    Ay = (y0-yn) - (yn-ym) = y0 -2yn + ym
    Az = (z0-xn) - (zn-zm) = z0 -2zn + zm

    The magnitude of the acceleration is |A| = sqrt( (Ax)^2 + (Ay)^2 + (Az)^2 )
    If you’re concerned only with “large” changes and prefer speed over accuracy, you may be able to get away with A' = (Ax)^2 + (Ay)^2 + (Az)^2
    or even A" = abs(Ax) + abs(Ay) + abs(Az)

    The idea is that you want each component to contribute to the whole regardless of whether it’s positive or negative, so you “force” it to be positive either by squaring it or taking its absolute value.

    Hope that helps!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm working on a piece of software that would work well with an iTunes
Folks, I'm working on a little piece of rich client software that I'd like
I am working on a piece of 3D software that has sometimes has to
Currently I am working on a piece of software, which is currently written 100%
I'm working on a piece of software that creates a contract and captures the
I'm working on a piece of scientific software that is very cpu-intensive (its proc
I'm currently working on a piece of software designed in WPF that connects to
I am working on a piece of software that effectively needs to talk to
We have a 3rd party piece of software that uses a bunch of internal
I'm working on a piece of software that monitors other processes' system calls using

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.