Grasshopper

algorithmic modeling for Rhino

Working with frames, a change in the alignement changed everything

Hello every one!

I'm sorry to bother you, but I come with a request.

I've been working on a frame structure and until now everything was fine.

But then I tried to change the alignment like this (H define the total height of the structure) and now I'm lost when I try to express the angle "a" with L and H as variables.

Would any body know how to do this with only "H" and "L" as variable and the bottom left point staying at the same spot?

I've attached the definition I'm working with if it can help somebody understand my conundrum.

Thank you for your time.

Thomas

 

Views: 342

Attachments:

Replies to This Discussion

Your file doesn't generate a preview and is far too big to debug for fun.  If you can supply a working version, it would make it easier.

In general though, it goes something like this (GH code attached):

Attachments:

Wow thank you for your quick reply, I'm going to go try it out. In the mean time, I've modified my GH definition so that it shows the structure and changed some label.

The top group is the one that generate the frames for the walls that I'm working on.

Attachments:

So I tried, and it gives me the result I had in the first scenario (with top most ans bottom most corner aligned). But it is way more efficient and clean than what I had.

I'm attaching the file I'm working on that is way simpler than the first one to manage to find the angle.

Attachments:

I'm sorry, your code is too complex for me to wade through...  There are so many ways to do this.

Here is a more complete method for getting the box shape you want, given the 'L' and 'H' dimensions.  It depends on the fact that vectors and points can be used interchangeably,  relative to the XYZ origin.

Good luck!

Attachments:

I posted and deleted an earlier version of this that contained an error computing the height of the tilted box; now corrected.

P.S.  Instead of jumping into GH widgets too quickly (which is fun!), it can pay off to think it through a little...  In this case, the basics of what you want to know can be determined with trigonometry:

Attachments:

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service