Build a list of GeoPoint as a circle.
@param center center of the circle
@param radiusInMeters
@return the list of GeoPoint
979013
public static ArrayList<GeoPoint> pointsAsCircle(GeoPoint center, double radiusInMeters){
		ArrayList<GeoPoint> circlePoints = new ArrayList<GeoPoint>(360/6);
		for (int f = 0; f < 360; f += 6){
			GeoPoint onCircle = center.destinationPoint(radiusInMeters, f);
			circlePoints.add(onCircle);
		}
		return circlePoints;
	}
635695
public static Location center(Location... location)
    {
        double lat = 0;
        double lon = 0;
        double height = 0;
        for (int ii=0;ii<location.length;ii++)
        {
            lat += location[ii].getLatitude();
            lon += location[ii].getLongitude();
        }
        Location loc = new Location(lat/location.length, lon/location.length);
        return loc;
    }
402729
function(feature) {
        var center = feature.geometry.getBounds().getCenterLonLat();
        var cluster = new OpenLayers.Feature.Vector(
            new OpenLayers.Geometry.Point(center.lon, center.lat),
            {count: 1}
        );
        cluster.cluster = [feature];
        return cluster;
    }
759394
public List<GoogleMapShape> addToMap(GoogleMap map,
                                         GeometryCollection<Geometry> geometryCollection) {

        List<GoogleMapShape> shapes = new ArrayList<GoogleMapShape>();

        for (Geometry geometry : geometryCollection.getGeometries()) {
            GoogleMapShape shape = addToMap(map, geometry);
            shapes.add(shape);
        }

        return shapes;
    }
1051992
public function geoWithinCenterSphere(float $x, float $y, float $radius) : self
    {
        $this->query->geoWithinCenterSphere($x, $y, $radius);

        return $this;
    }
915627
@Override
	public void set(Point3D center, double radius1) {
		this.cxProperty.set(center.getX());
		this.cyProperty.set(center.getY());
		this.czProperty.set(center.getZ());
		this.radiusProperty.set(Math.abs(radius1));
	}
1140739
public function geoWithinCenterSphere(float $x, float $y, float $radius) : self
    {
        $this->expr->geoWithinCenterSphere($x, $y, $radius);
        return $this;
    }
312387
public double calcKMeansCosts(double[] center) {
		assert (this.sumPoints.length == center.length);
		return this.sumSquaredLength - 2
				* Metric.dotProduct(this.sumPoints, center) + this.numPoints
				* Metric.dotProduct(center);
	}
1114323
public static TravelingSalesman of(int stops, double radius) {
		final MSeq<double[]> points = MSeq.ofLength(stops);
		final double delta = 2.0*PI/stops;

		for (int i = 0; i < stops; ++i) {
			final double alpha = delta*i;
			final double x = cos(alpha)*radius + radius;
			final double y = sin(alpha)*radius + radius;
			points.set(i, new double[]{x, y});
		}

		// Shuffling of the created points.
		final Random random = RandomRegistry.getRandom();
		for (int j = points.length() - 1; j > 0; --j) {
			final int i = random.nextInt(j + 1);
			final double[] tmp = points.get(i);
			points.set(i, points.get(j));
			points.set(j, tmp);
		}

		return new TravelingSalesman(points.toISeq());
	}
1360446
def point_in_circle(pt, center, radius):
    '''
    
    '''
    d = np.linalg.norm(np.asarray(pt) - np.asarray(center))
    return d <= radius
922903
public Circle fit(Point initPoint, DenseMatrix64F points)
    {
        initCenter.data[0] = initPoint.getX();
        initCenter.data[1] = initPoint.getY();
        radius = Double.NaN;
        fit(points);
        return this;
    }
781270
public JTSPointExpression<Point> centroid() {
        if (centroid == null) {
            centroid = JTSGeometryExpressions.pointOperation(SpatialOps.CENTROID, mixin);
        }
        return centroid;
    }
783632
public static Point getCircumCenter(Geometry geometry) {
        if(geometry == null || geometry.getNumPoints() == 0) {
            return null;
        }
        return geometry.getFactory().createPoint(new MinimumBoundingCircle(geometry).getCentre());
    }
32763
public static Point getCorner (Point center, Point size)
    {
        return new Point(center.x - size.x/2, center.y - size.y/2);
    }
890951
public void setCenterProperties(Point3d center) {
		this.cxProperty = center.xProperty;
		this.cyProperty = center.yProperty;
		this.czProperty = center.zProperty;
	}
1030707
public List<GoogleMapShape> toShapes(
            GeometryCollection<Geometry> geometryCollection) {

        List<GoogleMapShape> shapes = new ArrayList<GoogleMapShape>();

        for (Geometry geometry : geometryCollection.getGeometries()) {
            GoogleMapShape shape = toShape(geometry);
            shapes.add(shape);
        }

        return shapes;
    }
612142
protected static List<CentroidMapping> calculateDistances(double[][] baseCentroids,
            double[][] targetCentroids, int centroidNum)
    {
        // ベース中心点配列とマージ対象中心点配列の各々のユークリッド距離を算出
        List<CentroidMapping> allDistance = new ArrayList<>();

        for (int baseIndex = 0; baseIndex < centroidNum; baseIndex++)
        {
            for (int targetIndex = 0; targetIndex < centroidNum; targetIndex++)
            {
                CentroidMapping centroidMapping = new CentroidMapping();
                centroidMapping.setBaseIndex(baseIndex);
                centroidMapping.setTargetIndex(targetIndex);
                double distance = MathUtils.distance(baseCentroids[baseIndex],
                        targetCentroids[targetIndex]);
                centroidMapping.setEuclideanDistance(distance);
                allDistance.add(centroidMapping);
            }
        }
        return allDistance;
    }