Difference between revisions of "Manuals/calci/DISTANCE"
Jump to navigation
Jump to search
Line 20: | Line 20: | ||
*If any of the co-ordinates (x1,y1,x2,y2) is non-numeric, Calci returns an error message. | *If any of the co-ordinates (x1,y1,x2,y2) is non-numeric, Calci returns an error message. | ||
*If the function is not available, then load the geometry by using 'load geometry' command. | *If the function is not available, then load the geometry by using 'load geometry' command. | ||
− | |||
== Examples == | == Examples == | ||
Line 50: | Line 49: | ||
== See Also == | == See Also == | ||
− | *[[Manuals/calci/DISTANCE | DISTANCE]] | + | <!--*[[Manuals/calci/DISTANCE | DISTANCE]] --> |
+ | <font color=Red>Related function to be added</font> | ||
==References== | ==References== | ||
*[http://en.wikipedia.org/wiki/Distance Distance] | *[http://en.wikipedia.org/wiki/Distance Distance] |
Revision as of 06:38, 21 November 2013
DISTANCE(point1,point2)
- Where 'point1' is any point with coordinates[x1,y1] and
- 'point2' is any point with coordinates[x2,y2]
DISTANCE() calculates the distance between two points.
Description
DISTANCE(point1,point2)
DISTANCE([2,3],[6,7]) returns 5.656854249492381
- This function returns the distance between two points using the following formula -
DISTANCE = SQRT( (x2-x1)^2 + (y2-y1)^2 )
= SQRT((6-2)^2 + (7-3)^2) = SQRT(32) = 5.656854249492381
- If any of the co-ordinates (x1,y1,x2,y2) is non-numeric, Calci returns an error message.
- If the function is not available, then load the geometry by using 'load geometry' command.
Examples
DISTANCE() | Output |
([4,8],[3,6]) | 2.23606797749979 |
([-4,2],[7,-3]) | 12.083045973594572 |
([-2,-3],[-3,-2]) | 1.4142135623730951 |
([10,0],[3,6]) | 9.219544457292887 |
See Also
Related function to be added