All Projects → Vovke → loan-payments-calculator

Vovke / loan-payments-calculator

Licence: MIT license
A small library for calculating loan payments using various configurations, works.

Programming Languages

PHP
23972 projects - #3 most used programming language

Projects that are alternatives of or similar to loan-payments-calculator

Loan-calculator-bank-payment
Loan Calculator a small web application encoded in HTML, PHP, JS, and CSS. If you want to earn from BANK NICHE then you can use Loan Calculator script.
Stars: ✭ 32 (+146.15%)
Mutual labels:  loan, loan-payments
Period
Complex period comparisons
Stars: ✭ 1,001 (+7600%)
Mutual labels:  schedule, calculations
widgets
💸 Web3 Payments with any token. DePay simplifies and improves Web3 Payments with the power of DeFi. Accept any token with on-the-fly conversion with state-of-the-art widgets.
Stars: ✭ 32 (+146.15%)
Mutual labels:  payment
CloudSchedule
分布式调度系统,基于zookeeper ,netty,调度内核参考Spring schedule 执行表达式和Spring schedule一样,没有使用Quartz,客户端完全基于注解配置,使用同 Spring schedule一致,最少配置,使用简单
Stars: ✭ 14 (+7.69%)
Mutual labels:  schedule
schedule-rs
An in-process scheduler for periodic jobs. Schedule lets you run Rust functions on a cron-like schedule.
Stars: ✭ 93 (+615.38%)
Mutual labels:  schedule
NUAA ClassSchedule
NUAA_ClassSchedule 登录南京航空航天大学新教务系统,获取课表及考试信息,解析后生成iCal日历及xlsx表格文件,进而导入Outlook等日历...
Stars: ✭ 29 (+123.08%)
Mutual labels:  schedule
jquery-schedule
jQuery Schedule
Stars: ✭ 53 (+307.69%)
Mutual labels:  schedule
awesome-payment
支付业务常用汇总
Stars: ✭ 24 (+84.62%)
Mutual labels:  payment
ex pesa
Payment Library For Most Public Payment API's in Kenya and hopefully Africa. Let us get this moneybag
Stars: ✭ 19 (+46.15%)
Mutual labels:  payment
drf-stripe-subscription
An out-of-box Django REST framework solution for payment and subscription management using Stripe.
Stars: ✭ 42 (+223.08%)
Mutual labels:  payment
magento2
Mollie Payments for Magento 2
Stars: ✭ 70 (+438.46%)
Mutual labels:  payment
DemoInPutPasswordView
仿微信支付密码输入框 (A input password alert view like wechat pay.)
Stars: ✭ 44 (+238.46%)
Mutual labels:  payment
hackupc-landing
🚀 HackUPC's landing page
Stars: ✭ 31 (+138.46%)
Mutual labels:  schedule
MOE
MOE is an event-driven OS for 8/16/32-bit MCUs. MOE means "Minds Of Embedded system", It’s also the name of my lovely baby daughter 😎
Stars: ✭ 54 (+315.38%)
Mutual labels:  schedule
crater
Open Source Invoicing Solution for Individuals & Businesses
Stars: ✭ 5,938 (+45576.92%)
Mutual labels:  payment
svelte-stripe-js
Everything you need to add Stripe Elements to your Svelte project
Stars: ✭ 139 (+969.23%)
Mutual labels:  payment
laravel-viva-payments
A Laravel package for integrating the Viva Payments gateway
Stars: ✭ 29 (+123.08%)
Mutual labels:  payment
midtrans-python-client
Official Midtrans Payment API Client for Python | https://midtrans.com
Stars: ✭ 24 (+84.62%)
Mutual labels:  payment
pix-payload-generator.net
Gerar payload para qrcode estático PIX. (Sistema de pagamento instantâneo do Brasil) Sem a necessidade de conexão com um PSP.
Stars: ✭ 23 (+76.92%)
Mutual labels:  payment
one
🚥 Idempotency Handler, for making sure incoming requests are idempotent. Useful for payments, "at least once delivery" systems and more.
Stars: ✭ 18 (+38.46%)
Mutual labels:  payment

LoanPaymentsCalculator

Build Status Code Coverage Scrutinizer Code Quality

LoanPaymentsCalculator is a programmer-oriented library for PHP. It is created to provide Loan Payment Schedules for various inputs and strategies. Mainly developed for the short term loans it can be used for any other loan types as well.

Installation

You may use Composer to download and install LoanPaymentsCalculator as well as its dependencies.

$ composer require vovke/loan-payments-calculator

Standards

All the dates meet ISO 8601 standard, Y-m-d (YYYY-MM-DD)

Components

DateProvider

We use it to provide closest date that suits specific rules, for example, first day of month, not bank holiday and etc.

dateProvider = new DateProvider(DateDetermineStrategy, HolidayProvider, shiftToFuture = true)
dateProvider->calculate( startDate )

HolidayProvider

an Interface for checking if the specific date is a bank holiday. Used for period calculation in Schedule.

Period

Period class is used to provide an object representing a time frame where needed, it contains start and end date for the specific period and the amount of days between those.

We use it as a container to describe the Loan period, where startDate is the day when Loan will potentially get issued, and endDate is the date of the last repayment, we also use period for each of the Loan's payments and in that case endDate is the date of the payment's repayment.

Schedule

Schedule class is used to generate periods for the given loan period, number of payments and payment frequency.

$schedule = new Schedule($startDate, $numberOfPeriods, $dateProvider)

PaymentScheduleCalculator

PaymentScheduleCalculator interface is a contract for implementing different ways of payments calculations.

EqualPrincipalPaymentScheduleCalculator

EqualPrincipalPaymentScheduleCalculator is the simplest implementation of PaymentScheduleCalculator interface, generates payments with equal principal amount.

    $startDate = new \DateTime('1984-08-08');
    $principalAmount = 500;
    $numberOfPeriods = 5;
    $dailyInterestRate = 0.000383;
    $dateProvider = new DateProvider(new ExactDayOfMonthStrategy(), new WeekendsProvider(), true);
    $schedule = new Schedule($startDate, $numberOfPeriods, $dateProvider);
    $schedulePeriods = $schedule->generatePeriods();

    $paymentSchedule = new EqualPrincipalPaymentScheduleCalculator($schedulePeriods, $principalAmount, $dailyInterestRate);
    $payments = $paymentSchedule->calculateSchedule();

AnnuityPaymentScheduleCalculator

AnnuityPaymentScheduleCalculator generates payments with equal payments amount.

    ...
    $paymentSchedule = new AnnuityPaymentScheduleCalculator($schedulePeriods, $principalAmount, $dailyInterestRate);
    $payments = $paymentSchedule->calculateSchedule();

License

Released under the terms of the MIT License.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].