Fertig

Dependencies:   mbed

Fork of RT2_P3_students by RT2_P3_students

Revision:
7:72982ede2ff6
Parent:
6:2cc56521aa16
Child:
9:dc0eb7dd0d92
--- a/LinearCharacteristics.cpp	Tue Apr 10 11:44:36 2018 +0000
+++ b/LinearCharacteristics.cpp	Tue Apr 17 09:06:47 2018 +0000
@@ -2,9 +2,15 @@
 
 using namespace std;
 
-LinearCharacteristics::LinearCharacteristics(){    // standard lin characteristics
-    
+LinearCharacteristics::LinearCharacteristics(float gain,float offset){    // standard lin characteristics
+    this->gain = gain;
+    this->offset = offset;
 }
 
 LinearCharacteristics::~LinearCharacteristics() {}
 
+
+float LinearCharacteristics::evaluate(float x)
+{   
+return this->gain*(x - this->offset);
+    }