The curve r=cos(k * theta) is a k-leaved rose as mentioned but only if k is odd whereas it is a 2k-leaved rose if k is even, as can be seen in the panel graph for Roses. Also, in data Rose, you can replace "2*constant("pi")" with "(2-mod(&k, 2))*constant("pi")" since if k is odd, values from 0 to pi are sufficient for theta.