Difference between revisions of "Barycenter Command"

From GeoGebra Manual
Jump to: navigation, search
Line 1: Line 1:
<noinclude>{{Manual Page|version=4.2}}</noinclude>{{betamanual|version=4.2}}
+
<noinclude>{{Manual Page|version=4.2}}</noinclude>
 
{{command|cas=true|geometry|Barycenter}}
 
{{command|cas=true|geometry|Barycenter}}
 
;Barycenter[  <List of Points>, <List of Weights>  ]
 
;Barycenter[  <List of Points>, <List of Weights>  ]

Revision as of 11:53, 21 December 2012



Barycenter[ <List of Points>, <List of Weights> ]
Set the center of a system of points in the list, defined as the average of their positions, weighted by their value, using the proper formula.
Example: Barycenter[{(2, 0), (0, 2), (-2, 0), (0, -2)}, {1, 1, 1, 1}] yields point A(0,0)
Example: Barycenter[{(2, 0), (0, 2), (-2, 0), (0, -2)}, {2, 1, 1, 1}] yields point B(0.4,0). The x-coordinate of this point was determined by \frac{1}{ 2+1+1+1 }*(2*2+1*0+1*(-2)+1*0) = \frac{1}{ 5 }*2 = 0.4
© 2024 International GeoGebra Institute