Grasshopper

algorithmic modeling for Rhino

Hello,

I have put a formula in the expression designer .The formula is the following :(Atan(x/2)/(y/2))*2 , where x and y are variable set with sliders.   I should obtain an angle value but i am not sure how to extract it from the formula. 

I didn't set a domain or anything as I didn't found it useful, and don't know whether its relevant for my case. 

Helppp!!

Thanks !

Views: 477

Replies to This Discussion

The output of the component should be your angle. Note that code uses radians as angle units, not degrees, so if you want to have degrees, you'll have to modify the output.

Are you sure your brackets are correct though? As written, the expression looks like:

    Atan(x/2)

-----------------  * 2

        y/2

I'm wondering if you're actually after:

          x/2

Atan(-------) * 2

          y/2

Thanks for the quick answer.

I have check my formula its meant to be tan-1( (d/2)/(t/2) ) x 2, with teethe formula going  tan-1( (d/2)/(t/2) ) multiplied by 2.

You are right about the radian unit- I have checked it but i still don't know how to make an angle  defined by two lines. Because right now i have the angle value but not the vector line that defines it.

What I am trying to obtain is an a five angle defined by the formula. 

I am joining my definition so far.

Thanks !

Attachments:

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service