diff --git a/src/funktion.c b/src/funktion.c index cbbc45b..96bc4db 100644 --- a/src/funktion.c +++ b/src/funktion.c @@ -157,3 +157,8 @@ float Vsubstract3(float x3, float z3) { double result = x3 - z3; return result; } +float Vmultiplier(float x1,float m) { + x1 = x1 * m; + printf("(|%f",x1); + return x1; +} diff --git a/src/funktion.h b/src/funktion.h index d13ad49..8ec588e 100644 --- a/src/funktion.h +++ b/src/funktion.h @@ -31,5 +31,6 @@ float Vaddx3(float x3, float z3); float Vsubstract(float x1, float z1); float Vsubstract2(float x2, float z2); float Vsubstract3(float x3, float z3); +float Vmultiplier(float x1,float m); #endif diff --git a/src/main.c b/src/main.c index d88a015..3f88d2e 100644 --- a/src/main.c +++ b/src/main.c @@ -6,7 +6,7 @@ int main() { - double a,b,c,d,h,x1,s1,x2,x3,z1,z2,z3; + double a,b,c,d,h,x1,s1,x2,x3,z1,z2,z3,m; a = getValue('a'); b = getValue('b'); h = getValue('h'); @@ -132,4 +132,10 @@ int main() x3 = getValue('X'); z3 = getValue('z'); Vsubstract3(x3, z3); + + printf("x eingeben"); + x1 = getValue('X'); + printf("m eingeben"); + m = getValue('M'); + Vmultiplier(x1, m); }