Tuesday, March 20, 2007

The Vsepr Theory Molecular Structure Of H2se



PRACTICE 3

Humaniod hands



# include # include # include


# include # include void

hand (float ang, float rpy, RPZ float, float rpyf123, rpyf23 float, float rpyf3, rixf123 float, float rixf23, rixf3 float, float rmxf123, rmxf23 float, float rmxf3, raxf123 float, float raxf23, raxf3 float, float rmexf123, rmexf23 float, float rmexf3, rmaz float, float rmax, float rmay) void

mueveExtremidades (abd float, float abi, apd float, float api, float x1, float y1, float z1);

void init (void)
{
glClearColor (0.0, 0.0, 1.0, 0.0);
glShadeModel (GL_FLAT);
}

void display(void)
{

glClear (GL_COLOR_BUFFER_BIT);
glColor3f (1.0, 1.0, 1.0);
glLoadIdentity (); /* clear the matrix */
/* viewing transformation */
gluLookAt (0.0, 0.0, 5.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0);
glScalef (1.0, 1.0, 1.0); /* modeling transformation */


glPushMatrix();
glScalef(0.1,.6,1.0);
glTranslatef(-21,2.75f,0.0f);
glRotatef(90,0,0,1);
mano(0,1,45,0,0, 45,0,0, 45,0,0, 45,0,0, -20,0,0, -15, 0,1,0 );
glPopMatrix();

glPushMatrix();
glScalef(0.1,.6,1.0);
glTranslatef(21,2.75f,0.0f);
glRotatef(-90,0,0,1);
mano(0,1,45,0,0, 45,0,0, 45,0,0, 45,0,0, -20,0,0, -15, 0,1,0 ,);
glPopMatrix();

mueveExtremidades(8,-8,8,-8,0,0,0);

glFlush ();
}

void reshape (int w, int h)
{
glViewport (0, 0, (GLsizei) w, (GLsizei) h);
glMatrixMode (GL_PROJECTION);
glLoadIdentity ();
glFrustum (-1.0, 1.0, -1.0, 1.0, 1.5, 20.0);
glMatrixMode (GL_MODELVIEW);
}

/* ARGSUSED1 */
void keyboard(unsigned char key, int x, int y)
{
switch (key) {
case 27:
exit(0);
break;
}
}

nt main(int argc, char** argv)
{
glutInit(&argc, argv);
glutInitDisplayMode (GLUT_SINGLE GLUT_RGB);
glutInitWindowSize (500, 500);
glutInitWindowPosition (300,230);
glutCreateWindow (argv[0]);
init ();
glutDisplayFunc(display);
glutReshapeFunc(reshape);
glutKeyboardFunc(keyboard);
glutMainLoop();

return 0;
}



void mueveExtremidades(float abd, float abi, float apd,float api,float x1,float y1,float z1)
{
float x,y,z,brazod, brazoi, pied, piei;
x=x1;
y=y1;
z=z1;
brazod=abd;
brazoi=abi;
pied=apd;
piei=api;

glPushMatrix();
//cabeza
glTranslatef(0.0f,2.5f,0.0f);
glutWireCube (0.5);

//tronco
glScalef(2.5,2.5,2.0);
glTranslatef(0.0f,-0.45f,0.0f);
glutWireCube (0.5);
//piernas

glPushMatrix();
glPushMatrix();
//pierna izquierda
glRotatef(piei,x,y,z);
glTranslatef (-0.1f,-0.55f, 0.0f);
glScalef (-. 3,1.2,1.0)
glutWireCube (0.5);
glPushMatrix ();

glTranslatef (0.0f,-0.7f, 0.0 f)
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (0.0f, .35 f, 0.0f);
glScalef (1.1, .4,1.0)
glutWireCube (0.5);
glPopMatrix ();
glPopMatrix ();
/ / feet
glPushMatrix ();
glTranslatef (.3 f,-1.0f, 0.0f);
glScalef (1.6, .2,1.0)
glutWireCube (0.5);
glPopMatrix ();
glPopMatrix ();

/ / right leg
glRotatef (pied, x, y, z);
glTranslatef (0.1f,-0.55f, 0.0f);
glScalef (-. 3,1.2,1.0)
glutWireCube (0.5), glPushMatrix
();

glTranslatef (0.0f,-0.7f, 0.0f);
glutWireCube (0.5);
glPushMatrix
();
glTranslatef (0.0f, .35 f, 0.0f);
glScalef (1.1, .4,1.0)
glutWireCube (0.5);
glPopMatrix ();
glPopMatrix ();

/ / feet
glTranslatef (-. 3f,-1.0f, 0.0f);
glScalef (1.6, .2,1.0)
glutWireCube (0.5);


glPopMatrix ();
/ / right arm
glPushMatrix ();
glRotatef (brazod, x , y, z);
glTranslatef (0.35f, 0.1f, 0.0f);
glScalef (0.5,0.4, .5);
glutWireCube (0.5);

glPushMatrix ();

glTranslatef (0.4f, 0.0f, 0.0f);
glScalef (0.5,1.2,1.0);
glutWireCube (0.5);

glPopMatrix ();
glTranslatef (0.7f, 0.0f, 0.0f);
glScalef (.7,1,1.0)
glutWireCube (0.5);
/ / left arm
glPopMatrix ();
glRotatef (brazoi, x, y, z);
glTranslatef (-0.35f, 0.1f, 0.0f);
glScalef (0.5,0.4, .5);
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (-0.4f, 0.0f, 0.0f) ;
glScalef (0.5,1.2,1.0);
glutWireCube (0.5);

glPopMatrix ();
glTranslatef (-0.7f, 0.0f, 0.0f);
glScalef (.7,1,1.0);
glutWireCube (0.5);
glPopMatrix ();}




manually void (float a, float rpy, rpz float, float rpyf123, rpyf23 float, float rpyf3, rixf123 float, float rixf23, rixf3 float, float rmxf123, rmxf23 float, float rmxf3, raxf123 float, float raxf23, raxf3 float, float rmexf123, rmexf23 float, float rmexf3, float rmaz , float rmax, float rmay)



{glRotatef (this, rmax, rmay, rmaz);
glPushMatrix ();
/ / palm

glScalef (4,3,2);
glutWireCube (0.5);
glPopMatrix ();

glPushMatrix ();
/ / Pulgar
/ / falange1
glRotatef (rpyf123, 0,1,0);
glTranslatef (1.25f,-0.55f, 0.0f);
glScalef (1.25,1,1);
glutWireCube (0.5);

/ / falange2
glRotatef (rpyf23, 0,1,0);
glTranslatef (.5 f, 0.0f, 0.0f);
glScalef (1,1,1);
glutWireCube (0.5);

/ / falange3
glRotatef (rpyf3, 0,1,0);
glTranslatef (0.39f, 0.0f, 0.0f);
glScalef (.5,1,1);
glutWireCube (0.5);

glPopMatrix ();

glPushMatrix ();
/ / Indices
/ / falange1
glRotatef (rixf123, 1,0,0);
glScalef (1,1.5,1);
glTranslatef (0.75f, 0.75f, 0.0f);
glutWireCube (0.5);

/ / falange2
glRotatef (rixf23, 1,0,0);
glScalef (1 , 1.25,1);
glTranslatef (0.0f, 0.45f, 0.0f);
glutWireCube (0.5);

/ / falange3
glRotatef (rixf3, 1,0,0);
glScalef (1, .5, 1);
glTranslatef (0.0f, .75 f, 0.0f);
glutWireCube (0.5);

glPopMatrix ();

glPushMatrix ();
/ / Medio
/ / falange1
glRotatef (rmxf123, 1.0 , 0);
glScalef (1,1.5,1);
glTranslatef (0.25f, 0.75f, 0.0f);
glutWireCube (0.5);

/ / falange2
glRotatef (rmxf23, 1,0,0);
glScalef (1,1.25,1);
glTranslatef (0.0f, 0.45f, 0.0f);
glutWireCube (0.5 );

/ / falange3
glRotatef (rmxf3, 1,0,0);
glScalef (1, .75,1);
glTranslatef (0.0f, .60 f, 0.0f);
glutWireCube (0.5);

glPopMatrix ();

glPushMatrix ();
/ / Anguilla
/ / falange1
glRotatef (raxf123, 1,0,0);
glScalef (1,1.25,1);
glTranslatef (-0.25f, 0.860f , 0.0f);
glutWireCube (0.5);

/ / Falange2
glScalef (1,1.25,1);
glRotatef (raxf23, 1,0,0);
glTranslatef (0.0f, .45 f, 0.0f);
glutWireCube (0.5);

/ / falange3
glRotatef (raxf3, 1,0,0);
glScalef (1,1,1);
glTranslatef (0.0f, .5 f, 0.0f);
glutWireCube (0.5);

glPopMatrix ();

glPushMatrix ( );
/ / meñique
/ / falange1
glRotatef (rmexf123, 1,0,0);
glScalef (1,1.2,1);
glTranslatef (-0.75f, 0.86f, 0.0f);
glutWireCube (0.5 );

/ / falange2
glRotatef (rmexf23, 1,0,0);
glScalef (1,1,1);
glTranslatef (0.0f, 0.5f, 0.0f);
glutWireCube (0.5);

/ / falange3
glRotatef (rmexf3, 1,0,0);
glScalef (1 , 1.1);
glTranslatef (0.0f, .5 f, 0.0f);
glutWireCube (0.5);

glPopMatrix ();}

Friday, March 16, 2007

Tank Purge Dip System Advantages



Matrix Transformation

The order is first rotation (zax) and then travel by-d, because moving the camera is as moving the world in the opposite direction.
Another method for generating the matrix transformation and rotation is to calculate the unit vectors UVN and form the rotation matrix composed directly. Given the vectors N and V, these unit vectors are computed as
n = N / NC C = (n1, n2, n3)
u = VXN / VXN ç ç = (u1, u2, u3) v = nxu
= ( v1, v2, v3)
This method also automatically adjusts the direction of V so that v is perpendicular to n.
The rotation matrix composite processing view is



that transforms u into the global axis xw, v and w on the axis of the shaft n zw. This matrix takes place automatically reflection necessary to transform a left side view of a global system right.
The complete transformation of world coordinates to view coordinates is obtained as the matrix product
MVC
¬ WC = R · T-1


glViewport (0, 0, width, height);

This function defines portion of the window where you can draw ogl. The parameters are y, upper-left corner of the "box" where you can draw (with reference
the window), and width and height. In this case picks up the width and height, which are the parameters of reshape (), ie, the data just received
because the resizing of the window.

Tuesday, March 13, 2007

Rosy Cheeks On A Baby

Previous

Vector space

A vector space (or linear space) is the basic object of study in the branch of mathematical called linear algebra. The operations we can make between them are the vector sum and scalar multiplication, dot product, vector product and scalar triple preduce with some natural constraints such as closure of these operations, the association of these and the combination of these operations, following, we arrive at the description of a mathematical structure called space vector.


Given a formal definition
body commutative scalar K (as the body of real numbers or body of complex numbers ), which call for:
0 (zero) to the null element.
1 (a) the unit element.
A set V equipped with an internal composition law (+) (vector sum), and a law External composition (·) (a scalar product) to the body K, is a vector space if and only if:
V has the structure of commutative group
, regarding the internal composition law (+ ), (vector sum).
Regarding its external composition law (·), (scalar product), is fulfilled

Vector field In mathematics a vector field is a construction of calculation vector which associates a vector each point the Euclidean space .
Vector fields are often used in physical
, for example, model the speed and direction of a moving fluid throughout space, or the intensity and direction of a certain strength , as the electromagnetic force or gravitational , they change point to point.
The rigorous mathematical treatment, the vector fields defined in
distinguishable varieties as sections the tangent bundle variety.







Ring Given a nonempty set A and two internal laws of composition, the ordered triple (A,,) has the structure of ring if and only if

a) is associative. Ie,: a, b, c A

b) has a neutral element in A. Ie / if

c) Every element of A is invertible in A for.
is, /

d) is commutative. Ie: a, b A

These 4 properties show that (A,) is an abelian group.

e) is associative. Ie,: a, b, c A (ab) c = a (bc)

This property shows that (A,) is a semigroup.

f) distributes twice over. Ie,,: a, b, c A
a (bc) = (ab) (ac) (bc) a = (ba) (ca)

short we can say that

(A,,) is a ring iff (A,) is an abelian group, (A,) is a semigroup and the second operation distributes over the first.




DEMONSTRATION OF ROTATION MATRIX AXLE







Monday, March 12, 2007

Buy Element Tech Decks



Previous Practice No.2
This is the archive of humanoid that moves according to the parameter is muevete function.

# include # include # include


# include # include void

pint (xAxis float, float ejey, ejez float, float r, char c) void
muevete (abd float, float abi, apd float, float api);

void init (void) {
glClearColor
(0.0, 0.0, 0.0, 0.0);
glShadeModel (GL_FLAT);}


void display (void) {

glClear (GL_COLOR_BUFFER_BIT);
glColor3f (0.1, 0.1, 0.1);
glLoadIdentity ();
gluLookAt (0.0, 0.0, 5.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0);
glScalef (1.0, 1.0, 1.0);

glEnable (GL_DEPTH_TEST);
glPushMatrix ();
glLoadIdentity ();
muevete ( 8, -8.8, -8);
glPopMatrix ();
Sleep (1000);
surface (0,0,1, -15, 'r');
glutPostRedisplay ();
Sleep (1000);
glDisable (GL_DEPTH_TEST);
glPushMatrix ();
Sleep (1000);
muevete(8,-8,8,-8);
glPopMatrix();
glLoadIdentity();
pinta(0,0,1,-15,'r');
glutSwapBuffers();
glFlush ();
}

void reshape (int w, int h)
{
glViewport (0, 0, (GLsizei) w, (GLsizei) h);
glMatrixMode (GL_PROJECTION);
glLoadIdentity ();
glFrustum (-1.0, 1.0, -1.0, 1.0, 1.5, 20.0);
glMatrixMode (GL_MODELVIEW);
}

/* ARGSUSED1 */
void keyboard(unsigned char key, int x, int y)
{
switch (key) {
case 27:
exit(0);
break;
}
}

int main(int argc, char** argv)
{
glutInit(&argc, argv);
glutInitDisplayMode (GLUT_SINGLE GLUT_RGB);
glutInitWindowSize (500, 300);
glutInitWindowPosition (300,230);
glutCreateWindow (argv[0]);
init ();
glutDisplayFunc(display);
glutReshapeFunc(reshape);
glutKeyboardFunc(keyboard);
glutMainLoop();

return 0;
}


void pinta(float ejex, float ejey, float ejez,float r,char c)
{
float x1,y1,z1,r1;
char c1;
x1=ejex;
y1=ejey;
z1=ejez;
r1=r;
c1=c;
glPushMatrix();
if (c1 == 'r')
glRotatef (r1, x1, Y1, z1);
else if (c1 == 't')
glTranslatef (x1, Y1, z1);

/ / glTranslatef cabeza
(0.0f, 2.5f, 0.0f);
glutWireCube (0.5);
glScalef (2.5,2.5,2.0);
glTranslatef (0.0f,-0.45f, 0.0f);
glutWireCube (0.5);
/ / tronco
glPushMatrix ();
glTranslatef (-0.1f,-0.55f, 0.0f);
glScalef (-. 3,1.2,1.0);
glutWireCube (0.5);
glPopMatrix ();
/ / glPushMatrix piernas
();
glTranslatef (0.1f,-0.55f, 0.0f);
glScalef (-. 3,1.2,1.0);
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (0.0f,-0.7f, 0.0f);
glutWireCube (0.5);
glPopMatrix ();


glTranslatef (0.7f,-0.7f, 0.0f);
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (0.0f, .35 f, 0.0f);
glScalef (1.1, .4,1.0);
glutWireCube (0.5);
glPopMatrix ();

glPushMatrix ();
glTranslatef (-0.7f , .35 f, 0.0f);
glScalef (1.1, .4,1.0);
glutWireCube (0.5);
glPopMatrix ();
/ / pies
glPushMatrix ();
glTranslatef (.3 f, -. 3f, 0.0 f);
glScalef (1.6, .2,1.0);
glutWireCube (0.5);
glPopMatrix ();

glTranslatef (-. 8f, -. 3f, 0.0f);
glScalef (1.6, .2,1.0)
glutWireCube (0.5);


glPopMatrix ();
/ / right arm
glPushMatrix ();
glTranslatef (0.35f, 0.1f, 0.0f);
glScalef (0.5,0.4, .5);
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (0.4f, 0.0f, 0.0f);
glScalef (0.5,1.2,1.0);
glutWireCube (0.5);

glPopMatrix ();
glTranslatef (0.8f, 0.0f, 0.0f);
glutWireCube (0.5);
/ / left arm
glPopMatrix ();
glTranslatef (-0.35f, 0.1f, 0.0f);
glScalef (0.5,0.4, .5);
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (-0.4f, 0.0f, 0.0f);
glScalef (0.5,1.2,1.0);
glutWireCube (0.5);

glPopMatrix ();
glTranslatef (- 0.8f, 0.0f, 0.0f);
glutWireCube (0.5);
glPopMatrix ();}



void muevete (brader float, float braizq, belongs to float, float pieizq)
{float
brazod, brazoi, pied , piei;

brazod = brader;
brazoi = braizq;
pied = owned;
piei = pieizq;

glPushMatrix ();
/ / cabeza
glTranslatef (0.0f, 2.5f, 0.0f);
glutWireCube ( 0.5);

/ / tronco
glScalef (2.5,3.0,2.0);
glTranslatef (0.0f,-0.45f, 0.0f);
glutWireCube (0.5);
/ / legs

glPushMatrix ();
glPushMatrix ();
/ / left leg
glRotatef (PIEI, 0,0,1 )
glTranslatef (-0.1f,-0.55f, 0.0f);
glScalef (-. 3,1.2,1.0)
glutWireCube (0.5);
glPushMatrix ();

glTranslatef (0.0f,-0.7f , 0.0f);
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (0.0f, .35 f, 0.0f);
glScalef (1.1, .4,1.0)
glutWireCube (0.5);
glPopMatrix ( )
glPopMatrix ();
/ / feet
glPushMatrix ();
glTranslatef (.3 f,-1.0f, 0.0f);
glScalef (1.6, .2,1.0)
glutWireCube (0.5);
glPopMatrix ();
glPopMatrix ();

/ / right leg
glRotatef (pied, 0,0,1);
glTranslatef (0.1f ,-0.55f, 0.0f);
glScalef (-. 3,1.2,1.0)
glutWireCube (0.5);
glPushMatrix ();

glTranslatef (0.0f,-0.7f, 0.0f);
glutWireCube ( 0.5);

glPushMatrix ();
glTranslatef (0.0f, .35 f, 0.0f);
glScalef (1.1, .4,1.0)
glutWireCube (0.5);
glPopMatrix ();
glPopMatrix ();

/ / feet
glTranslatef (-. 3f,-1.0f, 0.0f);
glScalef (1.6, .2,1.0)
glutWireCube (0.5);


glPopMatrix ();
/ / right arm
glPushMatrix ();
glRotatef (brazod, 0,0,1);
glTranslatef (0.35f, 0.1f, 0.0f);
glScalef ( 0.5,0.4, .5);
glutWireCube (0.5);
glPushMatrix
();

glTranslatef (0.4f, 0.0f, 0.0f);
glScalef (0.5,1.2,1.0);
glutWireCube (0.5);

glPopMatrix ();
glTranslatef (0.8f, 0.0f, 0.0f);
glutWireCube (0.5);
/ / left arm
glPopMatrix ();
glRotatef (brazoi, 0,0,1);
glTranslatef ( -0.35f, 0.1f, 0.0f);
glScalef (0.5,0.4, .5);
glutWireCube (0.5);

glPushMatrix ();
glTranslatef (-0.4f, 0.0f, 0.0f);
glScalef (0.5,1.2,1.0);
glutWireCube (0.5);

glPopMatrix ();
glTranslatef (- 0.8f, 0.0f, 0.0f);
glutWireCube (0.5);
glPopMatrix ();}