Ellipsis: Difference between revisions
From JSXGraph Wiki
A WASSERMANN (talk | contribs) No edit summary |
A WASSERMANN (talk | contribs) No edit summary |
||
Line 10: | Line 10: | ||
var ell = board.create('ellipse', [f1, f2, [0,3]]); | var ell = board.create('ellipse', [f1, f2, [0,3]]); | ||
var P = board.create('glider', [1, 2, ell], {name: 'P'}); | var P = board.create('glider', [-1, 2, ell], {name: 'P'}); | ||
var s1 = board.create('segment', [f1,P]); | |||
var s2 = board.create('segment', [f2,P]); | |||
var txt = board.create('text', [3, 3, () => P.Dist(f1).toFixed(2) + ' + ' + P.Dist(f2).toFixed(2) + ' = ' + (P.Dist(f1) + P.Dist(f2)).toFixed(2)]); | |||
</jsxgraph> | </jsxgraph> | ||