'log' => sub { $_[0]->copy()->blog($_[1]); }, #### sub blog { # not implemented yet my ($self,$x,$base,$a,$p,$r) = ref($_[0]) ? (ref($_[0]),@_) : objectify(1,@_); return $upgrade->blog($x,$base,$a,$p,$r) if defined $upgrade; return $x->bnan(); } #### my ($rc,$exact) = $CALC->_log_int($x->{value},$base->{value}); #### sub _log_int { # calculate integer log of $x to base $base # ref to array, ref to array - return ref to array my ($c,$x,$base) = @_; # X == 0 => NaN return if (scalar @$x == 1 && $x->[0] == 0); # BASE 0 or 1 => NaN return if (scalar @$base == 1 && $base->[0] < 2);