Home | Doxygen Documentation | Tutorials | Developer Tools (restricted)

app-gregor/harbrecht/vector2.h
Go to the documentation of this file.
00001 /***************
00002  *  vector2.h  *
00003  ***************/
00004 
00005 
00006 /*====================================================*
00007  *  Kleine Arithmetik fuer zweidimensionale Vektoren  *
00008  *====================================================*/
00009 
00010 
00011 typedef struct {double x, y;} vector2;
00012 /* Typdefinition */
00013 
00014 
00015 vector2 vector2_make(double x, double y);
00016 /* Typkonvertierung: 2xREAL in vector2 */
00017 
00018 
00019 vector2 vector2_add(vector2 a, vector2 b);
00020 /* Vektoraddition */
00021 
00022 
00023 vector2 vector2_sub(vector2 a, vector2 b);
00024 /* Vektorsubtraktion */
00025 
00026 
00027 vector2 vector2_Smul(double s, vector2 a);
00028 /* S-Multiplikation */
00029 
00030 
00031 double vector2_skalp(vector2 a, vector2 b);
00032 /* Skalarprodukt */
00033 
00034 
00035 double vector2_norm(vector2 a);
00036 /* Euklid-Norm */

Home | Doxygen Documentation | Tutorials | Developer Tools (restricted)