Grasshopper

algorithmic modeling for Rhino

Hi everyone,

I have a little problem that I hope someone can help me with, as I have not had any luck finding the right search term for my problem for Google.

So I have a bunch of points which are being created along some unpredictable (but pretty smooth) path in 3D space. There is always new ones coming, but their location can not be predicted. Something like you would have in statistics.

Now in Grasshopper its pretty easy to use the Fit Line component to get an average line through some points and simply use that as a vector to predict in which direction roughly things will move.

Unfortunately I am using a different programming tool (vvvv) for once, which doesn't have that or most other specialised geometry related components of Grasshopper.

Therefore my question is how is that line through points is calculated, given I just have the location of all the points in order they were created (they will always be created along the imaginary time axis).

Can someone point me in the direction of what this is called in statistics and/or geometry.

Thanks.

Here is what the thing could look like in Grasshopper. What I need is the vector which predicts the trend of the last X points.

Views: 1976

Replies to This Discussion

Thank you, I will check this out!

Thank you, I will check it out!

So to better understand whats happening I am trying to recreate your script in GH first. Got stuck on multiplying the matrixes though. Is it the right way?

Attachments:

Thank you for all the information. I will have a look at it and try to understand it better. The whole matrix calculation is still somewhat mysterious to me. I need some sort of "advanced math for designers" course ;) A-Level maths only went so far..

You can multiply matrixes using the multiply component, but it appears it only works if they are the same format.

That's awesome, and I am sure it will come in handy soon!

Meanwhile with some help I got it working in vvvv as well. Not as slick as your version (only linear, but that's enough for what I need), but then vvvv isn't really designed for major 3D and geometric operations, because it doesn't run inside a host like Rhino.

Thanks for your effort!

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service