承接 holicz/pvgis 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

holicz/pvgis

Composer 安装命令:

composer require holicz/pvgis

包简介

Package to provide solar electricity production by GPS coordinates from PVGIS

README 文档

README

composer require holicz/pvgis

Requirements

  • PHP ^7.4|^8.0

Usage

Basic usage

<?php

use holicz\PVGIS\PVGIS;
use holicz\PVGIS\Adapter\PvgisAdapter;
use holicz\PVGIS\Enum\Database;

$latitude = '50.0898689';
$longitude = '14.4000936';

$pvgis = new PVGIS(new PvgisAdapter());
$electricityProduction = $pvgis->getElectricityProduction(
    $latitude,
    $longitude,
    35, // Solar panels angle (not required)
    CardinalDirection::SOUTH, // Solar panels azimuth (not required)
    Database::SARAH // Name of the radiation database (not required)
);

// Yearly sum of production
$electricityProduction->getYearlyProduction();

foreach ($electricityProduction->getMonthlyProductions() as $monthlyProduction) {
    // Month number
    $monthlyProduction->getMonth();
    // Sum of the monthly production
    $monthlyProduction->getProduction();
}

Using multiplier

If you for example know that you have six solar panels and the production is 1.86x time more bigger than the PVGIS result you should use the multiplier method

$electricityProduction->multiply(1.86);

统计信息

  • 总下载量: 885
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-03-30

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固