Secant and tangent: Difference between revisions

From JSXGraph Wiki
No edit summary
No edit summary
Line 36: Line 36:
         graph = board.createElement('curve', ['x', polynomial, 'x', -10, 10], {curveType:'graph'});
         graph = board.createElement('curve', ['x', polynomial, 'x', -10, 10], {curveType:'graph'});


q = board.createElement('glider', [0,0,graph], {style:6});
q = board.createElement('glider', [4.5,0,graph], {style:6});
s = board.createElement('slider', [0,-3,4,0.001,1,1],{name:' '});
s = board.createElement('slider', [0,-3,4,0.001,1,1],{name:' '});
q2 = board.createElement('point', [function(){ return q.X()+Math.max(s.X(),0.01);},
q2 = board.createElement('point', [function(){ return q.X()+Math.max(s.X(),0.01);},
Line 59: Line 59:
         graph = board.createElement('curve', ['x', f, 'x', -10, 10], {curveType:'graph'});
         graph = board.createElement('curve', ['x', f, 'x', -10, 10], {curveType:'graph'});


         qf = board.createElement('glider', [4.5,0,graph], {style:6});
         qf = board.createElement('glider', [0,0,graph], {style:6});
         sf = board.createElement('slider', [0,-3,4,-1,1,1],{name:' '});
         sf = board.createElement('slider', [0,-3,4,-1,1,1],{name:' '});
         qf2 = board.createElement('point', [function(){ return qf.X()+sf.X();},
         qf2 = board.createElement('point', [function(){ return qf.X()+sf.X();},

Revision as of 13:42, 16 January 2009