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 6604321
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T19:08:21+00:00 2026-05-25T19:08:21+00:00

I have two paths in 3D and I want to average them, if there’s

  • 0

I have two paths in 3D and I want to “average” them, if there’s such a thing.

I have the xyz pairs timestamped at the time they were sampled:

    ms   x   y   z
    3   0.1 0.2 0.6
    12  0.1 0.2 1.3
    23  2.1 4.2 0.3
    55  0.1 6.2 0.3

Facts about the paths:

  • They all start and end on/near the same xyz point.
  • I have the total duration it took to complete the path as well as individual vertices
  • They have different lengths (i.e. different number of xyz pairs).

Any help would be 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-25T19:08:21+00:00Added an answer on May 25, 2026 at 7:08 pm

    Expanding on @6502’s answer.

    If you wish to retrieve a list of points that would make up the average path, you could sample the avg function at the instances of the individual input points. (Stretched toward the average length)

    def avg2(T1, waypoints1, T2, waypoints2):
        # Collect the times we want to sample at
        T = (T1 + T2) / 2
        times = []
        times.extend(t*T/T1 for (t,x,y) in waypoints1)  # Shift the time towards
        times.extend(t*T/T2 for (t,x,y) in waypoints2)  #   the average
        times.sort()
    
        result = []
        last_t = None
        for t in times:
            # Check if we have two points in close succession
            if last_t is not None and last_t + 1.0e-6 >= t:
                continue
            last_t = t
    
            # Sample the average path at this instance
            x, y = avg(t, T1, waypoints1, T2, waypoints2)
            yield t, x, y
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

If I am making a module, and want to have two custom paths: path/path/path/index.htm
I have two absolute filesystem paths (A and B), and I want to generate
I have a directed graph with two directed paths in it. I want an
What's the opposite of os.path.commonprefix? I have two paths and I want the non-overlapping
I have two string variables which are both file paths. The code that worked
I have a script (python) supposed to build up two paths - one in
I have two columns say Main and Sub . (they can be of same
I have two distinct Django projects, which I want to run on a single
From my navigationController I have two paths: navigationController --> ViewControllerA -- ViewControllerB (currently showing).
I have two applications, one for android and one for blackberry and I want

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.