Polar Parametric Curves

## Description

This interact allows the user to adjust the values $n_1, n_2, a_1, a_2$ and $b$ in the parametric polar equation

(1)\begin{align} r = \cos(a_1 t)^{n_1} + \sin(a_2 t)^{n_2} + b \end{align}

and observe the effects on the plotted curve. This is not very general, but could be modified to show other families of polar curves.

## Sage Cell

#### Code

```
@interact
def para(n1 = slider(1,5,1,default = 2), n2 = slider(1,5,1,default = 3), a1 = slider(1,10,1/10,6/5), a2 = slider(1,10,1/10,6), b = slider(0,2,1/50,0)):
var('t')
pretty_print(html('$r=' + latex(b+sin(a1*t)^n1 + cos(a2*t)^n2)+'$'))
p = parametric_plot((cos(t)*(b+sin(a1*t)^n1 + cos(a2*t)^n2), sin(t)*(b+sin(a1*t)^n1 + cos(a2*t)^n2)), (t,0, 20*pi), plot_points = 1024, rgbcolor = (0,0,0))
show(p, figsize = [5,5], xmin = -2-b, xmax = 2+b, ymin = -2-b, ymax = 2+b, axes = False)
```

## Options

None

## Tags

Primary Tags: Single Variable Calculus: Polar

Secondary Tags: Polar: Curves (Trigonometry, polar coordinates, vectors, curves)

## Related Cells

None

## Attribute

Permalink: https://wiki.sagemath.org/interact/calculus#Some_polar_parametric_curves

Author: Marshall Hampton

Date: 22 Jul 2020 23:01

Submitted by: Zane Corbiere