!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 

uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/var/www/html/main_file/vendor/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Calculation/Engineering/   drwxr-xr-x
Free 13.14 GB of 57.97 GB (22.67%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     ComplexOperations.php (4.32 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

namespace PhpOffice\PhpSpreadsheet\Calculation\Engineering;

use 
Complex\Complex as ComplexObject;
use 
Complex\Exception as ComplexException;
use 
PhpOffice\PhpSpreadsheet\Calculation\ArrayEnabled;
use 
PhpOffice\PhpSpreadsheet\Calculation\Functions;
use 
PhpOffice\PhpSpreadsheet\Calculation\Information\ExcelError;

class 
ComplexOperations
{
    use 
ArrayEnabled;

    
/**
     * IMDIV.
     *
     * Returns the quotient of two complex numbers in x + yi or x + yj text format.
     *
     * Excel Function:
     *        IMDIV(complexDividend,complexDivisor)
     *
     * @param array|string $complexDividend the complex numerator or dividend
     *                      Or can be an array of values
     * @param array|string $complexDivisor the complex denominator or divisor
     *                      Or can be an array of values
     *
     * @return array|string
     *         If an array of numbers is passed as an argument, then the returned result will also be an array
     *            with the same dimensions
     */
    
public static function IMDIV($complexDividend$complexDivisor)
    {
        if (
is_array($complexDividend) || is_array($complexDivisor)) {
            return 
self::evaluateArrayArguments([self::class, __FUNCTION__], $complexDividend$complexDivisor);
        }

        try {
            return (string) (new 
ComplexObject($complexDividend))->divideby(new ComplexObject($complexDivisor));
        } catch (
ComplexException $e) {
            return 
ExcelError::NAN();
        }
    }

    
/**
     * IMSUB.
     *
     * Returns the difference of two complex numbers in x + yi or x + yj text format.
     *
     * Excel Function:
     *        IMSUB(complexNumber1,complexNumber2)
     *
     * @param array|string $complexNumber1 the complex number from which to subtract complexNumber2
     *                      Or can be an array of values
     * @param array|string $complexNumber2 the complex number to subtract from complexNumber1
     *                      Or can be an array of values
     *
     * @return array|string
     *         If an array of numbers is passed as an argument, then the returned result will also be an array
     *            with the same dimensions
     */
    
public static function IMSUB($complexNumber1$complexNumber2)
    {
        if (
is_array($complexNumber1) || is_array($complexNumber2)) {
            return 
self::evaluateArrayArguments([self::class, __FUNCTION__], $complexNumber1$complexNumber2);
        }

        try {
            return (string) (new 
ComplexObject($complexNumber1))->subtract(new ComplexObject($complexNumber2));
        } catch (
ComplexException $e) {
            return 
ExcelError::NAN();
        }
    }

    
/**
     * IMSUM.
     *
     * Returns the sum of two or more complex numbers in x + yi or x + yj text format.
     *
     * Excel Function:
     *        IMSUM(complexNumber[,complexNumber[,...]])
     *
     * @param string ...$complexNumbers Series of complex numbers to add
     *
     * @return string
     */
    
public static function IMSUM(...$complexNumbers)
    {
        
// Return value
        
$returnValue = new ComplexObject(0.0);
        
$aArgs Functions::flattenArray($complexNumbers);

        try {
            
// Loop through the arguments
            
foreach ($aArgs as $complex) {
                
$returnValue $returnValue->add(new ComplexObject($complex));
            }
        } catch (
ComplexException $e) {
            return 
ExcelError::NAN();
        }

        return (string) 
$returnValue;
    }

    
/**
     * IMPRODUCT.
     *
     * Returns the product of two or more complex numbers in x + yi or x + yj text format.
     *
     * Excel Function:
     *        IMPRODUCT(complexNumber[,complexNumber[,...]])
     *
     * @param string ...$complexNumbers Series of complex numbers to multiply
     *
     * @return string
     */
    
public static function IMPRODUCT(...$complexNumbers)
    {
        
// Return value
        
$returnValue = new ComplexObject(1.0);
        
$aArgs Functions::flattenArray($complexNumbers);

        try {
            
// Loop through the arguments
            
foreach ($aArgs as $complex) {
                
$returnValue $returnValue->multiply(new ComplexObject($complex));
            }
        } catch (
ComplexException $e) {
            return 
ExcelError::NAN();
        }

        return (string) 
$returnValue;
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0056 ]--