off center circle

draw2d(nticks=100,
       color=blue,
       line_width=2,
       xlabel="x", ylabel="y",
       xrange=[-0.5,2.5],
       yrange=[-1.5,1.5],
       proportional_axes=xy,
       xaxis=true,xtics_axis=true,
       yaxis=true,ytics_axis=true,
       grid=true,
       axis_top=false,axis_bottom=false,axis_left=false,axis_right=false,
       terminal=wxt,
       polar(2*cos(theta),theta,0,2*%pi));

draw2d(user_preamble="set grid polar",
       nticks=100,
       color=blue,
       line_width=2,
       xrange=[-0.5,2.5],
       yrange=[-1.5,1.5],
       proportional_axes=xy,
       xaxis=true,xtics_axis=true,
       yaxis=true,ytics_axis=true,
       grid=true,
       axis_top=false,axis_bottom=false,axis_left=false,axis_right=false,
       terminal=wxt,
       polar(2*cos(theta),theta,0,2*%pi));

plotting r,theta in rectangular coordinates

draw2d(nticks=100,
       color=blue,
       line_width=2,
       xlabel="theta",
       ylabel="r",
       xrange=[0,2*%pi],
       yrange=[0,2],
       proportional_axes=xy,
       xaxis=true,xtics_axis=true,
       yaxis=true,ytics_axis=true,
       grid=true,
       axis_top=false,axis_bottom=false,axis_left=false,axis_right=false,
       terminal=wxt,
       explicit(2*cos(theta),theta,0,2*%pi));

Just an example of using atan2 to figure out theta from x and y (atan2(y,x))

atan2(2,-2);

cardioid r=1-cos(theta)

draw2d(user_preamble="set grid polar",
       nticks=200,
       line_width=2,
       color=blue,
       xrange=[-2.5,1],
       yrange=[-1.5,1.5],
       proportional_axes=xy,
       xaxis=true,xtics_axis=true,
       yaxis=true,ytics_axis=true,
       grid=true,
       axis_top=false,axis_bottom=false,axis_left=false,axis_right=false,
       terminal=wxt,
       polar(1-cos(theta),theta,0,2*%pi));

what do constants do in cylindrical coords

draw3d(proportional_axes=xyz,
       user_preamble="set xyplane at -2.5",
       title="r=2, theta=pi/4, z=-1",
       enhanced3d=false,
       terminal=wxt,
       line_width=2,
       surface_hide=true,
       color=blue,
       explicit(-1,x,-2.5,2.5,y,-2.5,2.5),
       color=red,
       implicit(x-y=0,x,0,2.5,y,0,2.5,z,-2.5,2.5),
       color=dark_green,
       implicit(x^2+y^2=2^2,x,-2.5,2.5,y,-2.5,2.5,z,-2.5,2.5));

r=z in cylindrical coords

draw3d(proportional_axes=xyz,
       title="r=z",
       user_preamble="set xyplane at 0",
       line_width=2,
       color=blue,
       parametric_surface(v*cos(t),v*sin(t),
                          v,
                          v,0,2,t,0,2*%pi),
       surface_hide=true,
       terminal=wxt);

Some computations

integrate(integrate((r *cos(theta))^2 * r, r, 0, 2),\theta,-%pi/2,%pi/2);

integrate(integrate(r *cos(theta) * r, r, 0, 2),\theta,-%pi/2,%pi/2);

(2*%pi)/(16/3);

float(%), numer;