Übung: Schreibweise von Funktionen verstehen
(function() {
var functionPath = [];
functionPath.push([ -11, randRange( -5, 5 ) ]);
for( var i = -10; i < 11; i++ ) {
if ( abs( randRangeNonZero( -10, 10 ) < 2 ) && functionPath[i+10][1] < 8 ) {
functionPath.push([i, functionPath[i+10][1]+1]);
} else if ( abs( randRangeNonZero( -10, 10 ) < 2 ) && functionPath[i+10][1] > -8 ) {
functionPath.push([i, functionPath[i+10][1]-1]);
} else if ( abs( randRangeNonZero( -10, 10 ) < 2 ) && functionPath[i+10][1] < 7 ) {
functionPath.push([i, functionPath[i+10][1]+2]);
} else if ( abs( randRangeNonZero( -10, 10 ) < 3 ) && functionPath[i+10][1] > -7 ) {
functionPath.push([i, functionPath[i+10][1]-2]);
} else {
functionPath.push([i, functionPath[i+10][1]]);
}
}
return functionPath;
})()
randRange(-9, 9)
FUNCTION_PATH[CORRECT_X + 11][1]
Die Funktion f(x)
ist unten aufgetragen. Bestimme f(CORRECT_X)
.
graphInit({
range: 10,
scale: 20,
axisArrows: "<->",
tickStep: 1,
labelStep: 1,
unityLabels: false,
labelFormat: function( s ) { return "\\small{" + s + "}"; }
});
path( FUNCTION_PATH, { stroke: "#6495ed" } );
f(CORRECT_X)=
CORRECT_Y
An welchem Punkt schneidet f(x)
die Stelle x = CORRECT_X
?
graph.vert = line( [CORRECT_X, -10], [CORRECT_X, 10], {
stroke: "#28ae7b",
strokeDasharray: "- "
} );
circle( [CORRECT_X, CORRECT_Y], 3/20, {
stroke: "none",
fill: "black"
} );
Sie schneiden sich in (CORRECT_X, CORRECT_Y)
.
Daher ist f(CORRECT_X) = CORRECT_Y
.
graph.vert.remove();