Question: Lists and Points

(just got v12, haven't used it since v8) <--- my only excuse!

Trying to make a list of the centroids of the faces of a regular icosahedron. Here's my code:

***********

with(geom3d);

icosahedron(f,point(o,0,0,0);

a:=faces(f);

cent:=[];

printlevel:=-1; for k from 1 to 20 do point(A,a[k][1]):point(B,a[k][2]):point(C,a[k][3]);

print(coordinates(centroid(c,[A,B,C])));

cent:=[op(cent),coordinates(centroid(c,[A,B,C]))] od;
 

************

This gets me a list "cent" of length 20 containing the coordinates of the 20 centroids. What I want is a list containing them as "points" in Maple. So that e.g., centpoint[8] would be a Maple "point" corresponding to the centroid whose coordinates are in cent[8].

Is this possible? I may just be blockheaded on this one.

Second Q: is there a better approach from the start?

Thanks,

Len Smiley

Please Wait...