PHPackages                             josecelano/php-complex - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. josecelano/php-complex

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

josecelano/php-complex
======================

PHP Complex class implemented with arbitrary-precision decimal arithmetic

1.1.1(6y ago)012[2 issues](https://github.com/josecelano/php-complex/issues)PHPCI failing

Since Apr 9Pushed 6y ago1 watchersCompare

[ Source](https://github.com/josecelano/php-complex)[ Packagist](https://packagist.org/packages/josecelano/php-complex)[ RSS](/packages/josecelano-php-complex/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (3)Dependencies (3)Versions (4)Used By (0)

PHP Complex
===========

[](#php-complex)

I'm working on a PHP Fractal kata:

[PHP Mandelbrot Kata](https://github.com/josecelano/php-mandelbrot-arbitrary-precision)

In order to get be able to zoom in the final Mandelbrot Set image as much as I want I need arbitrary precision for some complex number operations. In this package I'have implemented only the operations needed.

This is the arbitrary precision package being used:

[php-decimal.io](https://php-decimal.io/)

Prerequisites
-------------

[](#prerequisites)

- PHP 7.4

Installation
------------

[](#installation)

```
docker build -t php-complex .
docker run -it --rm \
	-v "$PWD":/usr/src/app \
	-w /usr/src/app \
	-u $(id -u ${USER}):$(id -g ${USER}) \
	php-complex \
    composer install

```

Running the tests
-----------------

[](#running-the-tests)

```
docker run -it --rm \
	-v "$PWD":/usr/src/app \
	-w /usr/src/app \
	-u $(id -u ${USER}):$(id -g ${USER}) \
	php-complex

```

Acknowledgments
---------------

[](#acknowledgments)

-

TODO
----

[](#todo)

- Allow to define precision for each complex instance

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~4 days

Total

3

Last Release

2222d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/be136b95dbeae46d3ee90e3faf1b1440d659afd1028cea15dce1aadd753986a7?d=identicon)[josecelano](/maintainers/josecelano)

---

Tags

arbitrary-precisioncomplexphp

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/josecelano-php-complex/health.svg)

```
[![Health](https://phpackages.com/badges/josecelano-php-complex/health.svg)](https://phpackages.com/packages/josecelano-php-complex)
```

###  Alternatives

[aimeos/ai-client-html

Aimeos standard HTML frontend

1.0k341.5k11](/packages/aimeos-ai-client-html)[checkdomain/holiday

Checkdomain/Holiday provides a simple class to get holidays for a specified country

50384.1k2](/packages/checkdomain-holiday)[dfridrich/php-mime-type

Simple PHP class for guessing file mime type based on file extension with ability to use in Symfony project.

17274.8k3](/packages/dfridrich-php-mime-type)[jsvrcek/ics-bundle

This bundle provides a dependency injection wrapper for the JsvrcekICS iCal library

11150.6k](/packages/jsvrcek-ics-bundle)[muayyad-alsadi/yii-extended-clientscript

Extension to improve yiis native client script module

478.3k](/packages/muayyad-alsadi-yii-extended-clientscript)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
