Maple plot the $l^p$ balls: $\{(x,y) \mid |x|^p + |y|^p \le 1\}$ for $p = 1,...,10$

84 Views Asked by At

I have been asked to construct this plot in maple for an analysis assignment. I have been given no other instructions on how to do this. I am not familiar at all with defining or plotting these kinds of functions in maple. Any help would be greatly appreciated as I have been struggling with this for a few days now. Thank you!

1

There are 1 best solutions below

1
On

This seems to a question about Maple programming rather than math, and as such is better suited to stackoverflow.com or mapleprimes.com and not here.

Some things you could try:

restart:

N := 10:

P := [seq(plots:-implicitplot( abs(x)^p+abs(y)^p=1,
                               x=-1.1..1.1, y=-1.1..1.1,
                               gridrefine=2, filledregions,
                               title=sprintf("p = %a",p)),
          p=[$1..N])]:

plots:-display(Array([ seq([seq(P[(i-1)*2+j], j=1..2)],
                           i=1..iquo(N,2)) ]));

plots:-display( op(P) );

plots:-display( op(P), insequence=true );
# Now click on above plot and play the animation via menubar

Explore( plots:-implicitplot( abs(x)^p+abs(y)^p=1,
                              x=-1.1..1.1, y=-1.1..1.1,
                              gridrefine=2, filledregions,
                              title=sprintf("p = %a",p)),
         parameters=[ p=1..N ] );