Differentiability: Difference between revisions

From JSXGraph Wiki
No edit summary
No edit summary
Line 18: Line 18:
var graph = board.create('functiongraph', [pol, -10, 10], {strokeWidth: 2, name:"f", withLabel: true});
var graph = board.create('functiongraph', [pol, -10, 10], {strokeWidth: 2, name:"f", withLabel: true});


var x0 = board.create('glider', [1, 0, board.defaultAxes.x], {name: 'x_0', size:4});
var x0 = board.create('glider', [1, 0, board.defaultAxes.x], {name: 'x_0', size:4, label: {display: 'html'}});
var fx0 = board.create('point', [function() { return x0.X(); }, function() { return pol(x0.X()); }], {name: '', color: 'grey', fixed: true, size:3});
var fx0 = board.create('point', [function() { return x0.X(); }, function() { return pol(x0.X()); }], {name: '', color: 'grey', fixed: true, size:3});
var x = board.create('glider', [5, 0, board.defaultAxes.x], {name: 'x', size:4});
var x = board.create('glider', [5, 0, board.defaultAxes.x], {name: 'x', size:4});
Line 27: Line 27:
         function() { return x.X(); },
         function() { return x.X(); },
         function() { return (fx.Y()-fx0.Y())/(fx.X()-fx0.X() + 0.0000001); }],
         function() { return (fx.Y()-fx0.Y())/(fx.X()-fx0.X() + 0.0000001); }],
         { size: 1, name: 'f_1', color: 'black', fixed: true, trace: true});
         { size: 1, name: 'f_1', color: 'black', fixed: true, trace: true, label : {, display: 'html'}});
      
      
var txt = board.create('text', [2, 7, function() {  
var txt = board.create('text', [2, 7, function() {  
Line 40: Line 40:
</jsxgraph>
</jsxgraph>


===The underlying JavaScript code===
<source lang="javascript">
</source>


[[Category:Examples]]
[[Category:Examples]]
[[Category:Calculus]]
[[Category:Calculus]]

Revision as of 19:17, 22 January 2019

The underlying JavaScript code