Results 1 to 4 of 4

Thread: Tetrahedron in a unit sphere

  1. #1
    Nov 2007

    Tetrahedron in a unit sphere

    Hi everyone, i'm in need of help with a certain aspect of my project, hopefully someone has some suggestions:

    Im doing a mesh morphing program for two arbitrary genus0 meshes, i'm using the method of Marc Alexa for implementation.

    However i am stuck on a certain part which says:

    'Choose a random regular tetrahedron with vertices on the unit sphere'.

    Ive been searching for a few days now to find out how to construct a regular tetrahedron which fits exactly (more or less) inside a unit sphere.

    From what i have read, i need to have a 'circumscribed' tetrahedron', which has the sphere going outside through all the vertices in the tetrahedron.

    But i am having great difficulty programming this as i cannot work out how to determine how big the tetrahedron should be so that the vertices are on the surface of the sphere.

    Any help or suggestions would be greatly appreciated.

    Many Thanks
    Follow Math Help Forum on Facebook and Google+

  2. #2
    MHF Contributor

    Aug 2006
    Look at this page Tetrahedron -- from Wolfram MathWorld
    Are you looking for the circumradius?
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Nov 2007
    Hi there,

    Thanks. I already came across that page however, it was useful for understanding tetrehedron but was hard to think of implementing it. I've actually finished a class now that will generate a regular tetrahedron for a unit sphere, ill post it on here later.

    Follow Math Help Forum on Facebook and Google+

  4. #4
    Nov 2007
    For anyone thats interested:

    class Tetrahedron {

    The standard equation for points on a sphere will be used:
    x = r * cos(theta) * cos(phi)
    y = r * sin(theta) * cos(phi)
    z = r * sin(phi)
    x^2 + y^2 + z^2 = 1 for the unit sphere

    The angle theta goes around the equator 0 to 360 degrees, 0 to 2Pi
    The angle phi goes from north pole 90 to -90 degrees, Pi/2 to -Pi/2
    Radians = Pi * (angle_in_degrees) / 180


    public ArrayList<GL_Vertex> verts = new ArrayList();
    public ArrayList<GL_Triangle> tris = new ArrayList();

    doublePi = 3.141592653589793238462643383279502884197;
    doublephiaa = -19.471220333; /* the phi angle needed for generation */

    public Tetrahedron(){

    for(int i = 0; i<4; i++)
    GL_Vertex v =
    new GL_Vertex();

    double r = 1.0; /* any radius in which the polyhedron is inscribed */

    double phia = Pi*phiaa/180.0; /* 1 set of three points */

    double the120 = Pi*120.0/180.0;
    double the = 0.0;

    verts.get(0).pos.x = (float) 0.0;
    verts.get(0).pos.y = (float) 0.0;
    verts.get(0).pos.z = (float) r;

    for(int i=1; i<4; i++)

    verts.get(i).pos.x =(float) (r*Math.cos(the)*Math.cos(phia));
    verts.get(i).pos.y =(float) (r*Math.sin(the)*Math.cos(phia));
    verts.get(i).pos.z =(float) (r*Math.sin(phia));
    the = the+the120;

    for(int i=0; i<4; i++){

    GL_Triangle tri0 =
    new GL_Triangle(verts.get(0), verts.get(1), verts.get(2));
    GL_Triangle tri1 =
    new GL_Triangle(verts.get(0), verts.get(2), verts.get(3));
    GL_Triangle tri2 =
    new GL_Triangle(verts.get(0), verts.get(3), verts.get(1));
    GL_Triangle tri3 =
    new GL_Triangle(verts.get(1), verts.get(2), verts.get(3));

    tris.add(0, tri0);
    tris.add(1, tri1);
    tris.add(2, tri2);
    tris.add(3, tri3);

    /* map vertices to 4 faces */





    //Length of every edge 1.6329932 */


    Based on algorithm from : Regular Polyhedron Generators
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. subsets of unit sphere in C^2
    Posted in the Differential Geometry Forum
    Replies: 5
    Last Post: May 5th 2010, 02:22 PM
  2. Sphere inscribed in a regular tetrahedron
    Posted in the Geometry Forum
    Replies: 1
    Last Post: Mar 10th 2010, 05:22 AM
  3. Replies: 0
    Last Post: Mar 7th 2010, 07:47 PM
  4. Replies: 3
    Last Post: Jul 17th 2009, 04:53 AM
  5. Sphere in a tetrahedron
    Posted in the Calculus Forum
    Replies: 1
    Last Post: Jun 26th 2009, 03:09 AM

Search Tags

/mathhelpforum @mathhelpforum