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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T10:50:38+00:00 2026-05-16T10:50:38+00:00

Imagine a surface which has got 2 points which are moving over the surface

  • 0

Imagine a surface which has got 2 points which are moving over the surface (resulting into various lines and curves) while adhering to the following conditions.

  1. These two points are always and always at a constant C distance from each other.
  2. Each point has it’s own velocity and direction vector. Of course both these parameters will be restricted based on condition 1.
    Ex. if point 1 has 0 velocity and point 2 is moving it will result into a circle like shape with point one being it’s center.

I am unable to express these conditions in programming constructs. Can someone help me with that?

I am using OpenGL but even a pseudo code will do for me.

  • 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-16T10:50:38+00:00Added an answer on May 16, 2026 at 10:50 am
    vec3 center;
    
    
    
    while(1):
        vec3 centerDirection = ...
        center += centerDirection
        float angle = ...
        vec3 dir(cos(angle), 0, sin(angle))
        vec3 p1 = center + (C/2) * dir
        vec3 p2 = center - (C/2) * dir
        draw p1
        draw p2
    

    This is a solution where you move the center of a circle and make sure p1 and p2 are two diametrically opposed points
    Another solution :

    while 1:
        p1 += random
        p2 += random
        delta = p1-p2
        delta.normalize()
        p2 = p1 + C * delta
    

    i.e you restrain p2, not both points.

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

Sidebar

Related Questions

Imagine I've got a database with lots of data, from which users can search.
Imagine you have class A which has code which runs as method M. And
Imagine we have a set of entities each of which has its state: free,
Imagine you have a function tree which has a number of nodes which can
Imagine you have a template which has a button that by clicking on it,
Imagine that HTML page is a game surface (see picture). User can have n
I'm developing an application in which 2D animations will be displayed over a live-camera
Imagine that I have a engine gem A that has your application.css and application.js
Imagine I got some kind of function called by a macro to return an
Imagine there's a picturebox which loads a monochrome image. And there is a need

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.