# [BEHAVIOR] Polar Coordinates

### » Mon Aug 07, 2017 10:47 pm

Polar Coordinates behavior

It allows you to use polar coordinates instead of orthogonal coordinates (regular X,Y)

Properties:
• OriginX
• OriginY
• DeltaX (aka the distance to the Origin)
• DeltaY (aka the angle)
• Status (Enabled or Disabled)

ACES:
Actions:
• Set Origin
• Set Delta Position
• Set Enabled
• Update

Conditions:
• Comapre Origin
• Compare Delta Position
• Is Enabled

Expression:
• Origin
• Delta Position
• Status

B
42
S
9
G
2
Posts: 250
Reputation: 3,869

### » Mon Aug 07, 2017 11:00 pm

That is exactly what i missed for a long time. Ima snap this tomorrow.
B
33
S
18
G
29
Posts: 2,493
Reputation: 21,450

### » Tue Aug 08, 2017 2:12 am

Tell me if you see anything wrong or that I could do better
B
42
S
9
G
2
Posts: 250
Reputation: 3,869

### » Tue Aug 08, 2017 10:28 am

Oh i am happy with it as it is (how it works).

I would like to suggest other names, to give it more an intuitive 'polar feeling'. But that is up to you.

.OriginX i would name .PoleX / .PoleY. "Pole" is mostly used to point to that point. (i think)
.DeltaY i would name .Azimuth. "Angle" is taken. And Azimuth means the angle to a reference angle.

You could add that 'reference angle' (the polar axis, up to you), but i guess that will complicate things for most users. Everyone is used to zero angle as reference.

Say you have two objects under an angle(x1,y1,x2,y2)
Say we can set an expression .ReferenceAngle to that angle. (or leave it to a default zero)
Then we can set .Azimuth with .ReferenceAngle as the angle from where .Azimuth starts to rotate from.

Now we can easily go along with rotated coordinate systems.
B
33
S
18
G
29
Posts: 2,493
Reputation: 21,450

### » Tue Aug 08, 2017 4:26 pm

99Instances2Go wrote:I would like to suggest other names, to give it more an intuitive 'polar feeling'. But that is up to you.

.OriginX i would name .PoleX / .PoleY. "Pole" is mostly used to point to that point. (i think)
.DeltaY i would name .Azimuth. "Angle" is taken. And Azimuth means the angle to a reference angle.

Well the Origin X and Y designate the position of the origin of the polar coordinates (aka the point (0,0)), so I think it's better named that way.
I could name DeltaX and DeltaY, Radius and Angle for clarity purposes. Also the "Angle" is not necessarily taken as it will be Object.PolarCoordinates.Angle

99Instances2Go wrote:You could add that 'reference angle' (the polar axis, up to you), but i guess that will complicate things for most users. Everyone is used to zero angle as reference.
Say you have two objects under an angle(x1,y1,x2,y2)
Say we can set an expression .ReferenceAngle to that angle. (or leave it to a default zero)
Then we can set .Azimuth with .ReferenceAngle as the angle from where .Azimuth starts to rotate from.

I understand what you mean but I don't think that's really useful. The purpose of the plugin is to allow the use of polar coordinates, not make the act of polar rotation easier. However, you can make that pretty easily, as you can see in the two example capx.
And you can set the "Start" angle from the editor in the behavior's parameters, so it's kinda similar to what you want.
B
42
S
9
G
2
Posts: 250
Reputation: 3,869

### » Thu Aug 10, 2017 12:52 am

UPDATE:
Renamed DeltaX and DeltaY to Radius and Angle.
Added CarToPol and PolToCar expressions to convert Carthesian to Polar and vice versa.

B
42
S
9
G
2
Posts: 250
Reputation: 3,869