Function: arrow2d - plot an arrow as a line with a triangular head.

Calling sequence:


base - base of the arrow, a 2D point ( list or vector)

vect - displacement (tip - base), a 2D point (list or vector)

Optional arguments:

scalefactor= [Maple Math] to multiply length by real constant [Maple Math] .

thickness= [Maple Math] for thickness of the arrow shaft ( [Maple Math] should be 0, 1, 2 or 3, default is 3).

colour= [Maple Math] to specify arrow colour (default is red).

other 2D plot options


This function creates a 2D plot data object which, when displayed, is an arrow from base to base+vect (or base+s*vect if the option scalefactor=s is specified).

For an arrow from base to tip , use arrow2d(base,tip-base) .

Unless the option scaling=constrained ("Projection, Constrained" on the plot menu or "1-1" on the context bar) is used, the shape of the arrowhead may be distorted.

While it is mainly provided for use by the curvarrows function, this function can be used on its own. Its result would usually be combined with other plot structures by the function display from the plots package.

This function is part of the package surfarro in the Maple Advisor Database library, and must be loaded before use by the command with(surfarro); or with(surfarro,arrow2d); .


> with(surfarro,arrow2d):

> a1:= arrow2d([0,0],[1,0]):
a2:= arrow2d([1,0],[0,1]-[1,0]):
a3:= arrow2d([0,1],[0,-1],scalefactor=1/2):
a4:= arrow2d([0,0],[0,1/2],colour=blue):

See also: arrow3d , curvarrows , display

Maple Advisor Database R. Israel, 1998