polar coordinates
A coordinate system consisting of poles, polar axes and polar diameters in a plane. Setting a point o on the plane is called a pole. Starting from o, draw a ray Ox, which is called the polar axis. Then set a length unit, which usually specifies that the counterclockwise direction is positive. In this way, the position of any point P on the plane can be determined by the length ρ of the line segment OP and the angle θ from Ox to OP. The ordered number pair (ρ, θ) is called the polar coordinate of the point P, which is denoted as P(ρ, θ); ρ is called the polar diameter of point P, and θ is called the polar angle of point P. When ρ≥0, 0 ≤θ < 2π, every point on the plane except the pole ο has unique polar coordinates. The polar diameter of the pole is zero and the polar angle is arbitrary. If the above restrictions are removed, every point on the plane has countless sets of polar coordinates. Generally, if (ρ, θ) is the polar coordinate of a point, then (ρ, θ+2n π), (-ρ, θ+(2n+ 1) π) can be used as its polar coordinate, where n is an arbitrary integer. There are some curves on the plane. When polar coordinates are used, the equation is relatively simple. For example, the polar coordinate equation of a circle with the origin as the center and R as the radius is ρ = r, and the equation of a constant velocity spiral is. In addition, three different conic curves of ellipse, hyperbola and parabola can be expressed by a unified polar coordinate equation.
Conversion from polar coordinate system to rectangular coordinate system;
x=ρcosθ
y=ρsinθ
Conversion from rectangular coordinate system to polar coordinate system;
The length can be found directly: ρ = sqrt (x 2+y 2) sqrt means to find the square root.
The angle needs to be calculated in sections, that is, to judge the x and y values.
If ρ=0 and the angle θ is arbitrary, there is also a function definition θ = 0;
If rho > 0, then:
{Let ang=acin(y/ρ)
If y=0 and x>0, then θ = 0;
If y = 0, x
If y>0, θ = ang;
If y
}