Vendor/phpspreadsheet/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Calculation/LookupRef.php
public static function COLUMN($cellAddress = null)
    {
        if ($cellAddress === null || trim($cellAddress) === '') {
            return 0;
        }

        if (is_array($cellAddress)) {
            foreach ($cellAddress as $columnKey => $value) {
                $columnKey = preg_replace('/[^a-z]/i', '', $columnKey);

                return (int) Coordinate::columnIndexFromString($columnKey);
            }
        } else {
            if (strpos($cellAddress, '!') !== false) {
                list($sheet, $cellAddress) = explode('!', $cellAddress);
            }
            if (strpos($cellAddress, ':') !== false) {
                list($startAddress, $endAddress) = explode(':', $cellAddress);
                $startAddress = preg_replace('/[^a-z]/i', '', $startAddress);
                $endAddress = preg_replace('/[^a-z]/i', '', $endAddress);
                $returnValue = [];
                do {
                    $returnValue[] = (int) Coordinate::columnIndexFromString($startAddress);
                } while ($startAddress++ != $endAddress);

                return $returnValue;
            }
            $cellAddress = preg_replace('/[^a-z]/i', '', $cellAddress);

            return (int) Coordinate::columnIndexFromString($cellAddress);
        }
    }
public static function COLUMN($cellAddress = null)
    {
        if ($cellAddress === null || trim($cellAddress) === '') {
            return 0;
        }

        if (is_array($cellAddress)) {
            foreach ($cellAddress as $columnKey => $value) {
                $columnKey = preg_replace('/[^a-z]/i', '', $columnKey);

                return (int) Coordinate::columnIndexFromString($columnKey);
            }
        } else {
            if (strpos($cellAddress, '!') !== false) {
                list($sheet, $cellAddress) = explode('!', $cellAddress);
            }
            if (strpos($cellAddress, ':') !== false) {
                list($startAddress, $endAddress) = explode(':', $cellAddress);
                $startAddress = preg_replace('/[^a-z]/i', '', $startAddress);
                $endAddress = preg_replace('/[^a-z]/i', '', $endAddress);
                $returnValue = [];
                do {
                    $returnValue[] = (int) Coordinate::columnIndexFromString($startAddress);
                } while ($startAddress++ != $endAddress);

                return $returnValue;
            }
            $cellAddress = preg_replace('/[^a-z]/i', '', $cellAddress);

            return (int) Coordinate::columnIndexFromString($cellAddress);
        }
    }
COLUMN.

Returns the column number of the given cell reference
If the cell reference is a range of cells, COLUMN returns the column numbers of each column in the reference as a horizontal array.
If cell reference is omitted, and the function is being called through the calculation engine, then it is assumed to be the
reference of the cell in which the COLUMN function appears; otherwise this function returns 0.

Excel Function:
=COLUMN([cellAddress])

@param null|array|string $cellAddress A reference to a range of cells for which you want the column numbers

@return int|int[]