public function mLadder($P, $x = '1')
    {
        $tmp = $this->D2B($x);
        $n   = strlen($tmp) - 1;
        $S0  = $this->Inf;
        $S1  = $P;

        while ($n >= 0) {
            switch ($tmp[$n]) {
                case '0':
                    $S1 = $this->pointAddW($S0, $S1);
                    $S0 = $this->pointDoubleW($S0);
                    break;
                default:
                    $S0 = $this->pointAddW($S0, $S1);
                    $S1 = $this->pointDoubleW($S1);
                    break;
            }

            $n--;
        }

        return $S0;
    }