-
Notifications
You must be signed in to change notification settings - Fork 0
/
example3-proportional.js
21 lines (16 loc) · 1.21 KB
/
example3-proportional.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
var engine = require('./engine');
var Point = engine.Point;
var Line = engine.Line
var solve = engine.solve;
var A = new Point(0,0);
var b = Math.sqrt(3);
var B = new Point(b,0);
var c = Math.sqrt(5);
var C = new Point(c,0);
var d = b * b / c;
var D = new Point(d,0);
solve(
/* goals */ [D],
/* starting set */ [A, B, C],
/* problem setup */ [new Line(A,B)]
);