INCLAN Graphics: plot curve: Difference between revisions
No edit summary |
|||
(5 intermediate revisions by the same user not shown) | |||
Line 10: | Line 10: | ||
The command draws a Bézier spline curve defined by the points ('''x''<sub>i</sub>,''y''<sub>i</sub>). The total number of points must be 3''n'' + 1, with integer ''n'' ≥ 1. The resulting curve passes through the points 1, 4, 7,...; the other points guide the curve. Four points define the shape of each segment of the curve: The curve segment leaves (''x''<sub>1</sub>,''y''<sub>1</sub>) along the direction of the straight line connecting (''x''<sub>1</sub>,''y''<sub>1</sub>) with (''x''<sub>2</sub>,''y''<sub>2</sub>) and reaches (''x''<sub>4</sub>,''y''<sub>4</sub>) along the direction of the straight line connecting (''x''<sub>3</sub>,''y''<sub>3</sub>) with (x4,y4). The lengths of the lines connecting (''x''<sub>1</sub>,''y''<sub>1</sub>) with (''x''<sub>2</sub>,''y''<sub>2</sub>) and (''x''<sub>3</sub>,''y''<sub>3</sub>) with (''x''<sub>4</sub>,''y''<sub>4</sub>) represent, in a sense, the “velocity” of the path at the endpoints. The curve segment is always enclosed by the convex quadrilateral defined by the four points. | The command draws a Bézier spline curve defined by the points ('''x''<sub>i</sub>,''y''<sub>i</sub>). The total number of points must be 3''n'' + 1, with integer ''n'' ≥ 1. The resulting curve passes through the points 1, 4, 7,...; the other points guide the curve. Four points define the shape of each segment of the curve: The curve segment leaves (''x''<sub>1</sub>,''y''<sub>1</sub>) along the direction of the straight line connecting (''x''<sub>1</sub>,''y''<sub>1</sub>) with (''x''<sub>2</sub>,''y''<sub>2</sub>) and reaches (''x''<sub>4</sub>,''y''<sub>4</sub>) along the direction of the straight line connecting (''x''<sub>3</sub>,''y''<sub>3</sub>) with (x4,y4). The lengths of the lines connecting (''x''<sub>1</sub>,''y''<sub>1</sub>) with (''x''<sub>2</sub>,''y''<sub>2</sub>) and (''x''<sub>3</sub>,''y''<sub>3</sub>) with (''x''<sub>4</sub>,''y''<sub>4</sub>) represent, in a sense, the “velocity” of the path at the endpoints. The curve segment is always enclosed by the convex quadrilateral defined by the four points. | ||
[[Image: | [[Image:curve.jpg|250px]] | ||
List mode:<br> | List mode:<br> | ||
The command draws Bézier spline curves through the points of the given vector expressions ''x'', ''y''<sub>1</sub>,... If no vector expressions are specified, splines are drawn through the points of all list columns. If the ''x''-expression is omitted (i.e. if only a single expression, ''y''<sub>1</sub>, is given), the ''x''-coordinates are taken from the ''x''-column of the list. The number of list points must be 3''n'' + 1, with integer ''n''. | The command draws Bézier spline curves through the points of the given vector expressions ''x'', ''y''<sub>1</sub>,... If no vector expressions are specified, splines are drawn through the points of all list columns. If the ''x''-expression is omitted (i.e. if only a single expression, ''y''<sub>1</sub>, is given), the ''x''-coordinates are taken from the ''x''-column of the list. The number of list points must be 3''n'' + 1, with integer ''n''. |
Latest revision as of 17:36, 9 September 2009
Synopsis
plot curve x1 y1 x2 y2 x3 y3 x4 y4 ... (normal mode)
plot curve [[x] y1...](list mode)
Description
Normal mode:
The command draws a Bézier spline curve defined by the points ('xi,yi). The total number of points must be 3n + 1, with integer n ≥ 1. The resulting curve passes through the points 1, 4, 7,...; the other points guide the curve. Four points define the shape of each segment of the curve: The curve segment leaves (x1,y1) along the direction of the straight line connecting (x1,y1) with (x2,y2) and reaches (x4,y4) along the direction of the straight line connecting (x3,y3) with (x4,y4). The lengths of the lines connecting (x1,y1) with (x2,y2) and (x3,y3) with (x4,y4) represent, in a sense, the “velocity” of the path at the endpoints. The curve segment is always enclosed by the convex quadrilateral defined by the four points.
List mode:
The command draws Bézier spline curves through the points of the given vector expressions x, y1,... If no vector expressions are specified, splines are drawn through the points of all list columns. If the x-expression is omitted (i.e. if only a single expression, y1, is given), the x-coordinates are taken from the x-column of the list. The number of list points must be 3n + 1, with integer n.