divineomega/php-distance 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

divineomega/php-distance

最新稳定版本:v2.0.0

Composer 安装命令:

composer require divineomega/php-distance

包简介

Allows for calculation of many types of distance between points

README 文档

README

Build Status Coverage Status Packagist

The PHP Distance library allows for calculation of many types of distance between points.

Installation

PHP Distance can be easily installed using Composer. Just run the following command from the root of your project.

composer require jord-jd/php-distance

If you have never used the Composer dependency manager before, head to the Composer website for more information on how to get started.

Usage

See the following code snippet that demonstates how to use this library.

$a = new Point($x1, $y1);
$b = new Point($x2, $y2);
$c = new Point($x3, $y3, $z3); # Infinite dimensions supported by some distance types

$distanceType = new Euclidean();
$distanceType = new EuclideanSquare();
$distanceType = new Haversine();	# For GPS coordinates (latitude and longitude)

$distance = (new Distance())
		->type(new Euclidean())	# Type is optional, and defaults to Euclidean distance
		->from($a)
		->to($b)
		->get();

统计信息

  • 总下载量: 11.06k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 3
  • 点击次数: 2
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 3
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: LGPL-3.0-only
  • 更新时间: 2018-11-25

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固