xmath

package
v0.0.0-...-8299741 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 7, 2024 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Overview

Package xmath provides addons to std math package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CeilLog2

func CeilLog2(x uint64) int

CeilLog2 returns minimal i: 2^i >= x.

func CeilPow2

func CeilPow2(x uint64) uint64

CeilPow2 returns minimal y >= x, such that y = 2^i.

func FloorLog2

func FloorLog2(x uint64) int

FloorLog2 returns maximal i: 2^i <= x.

x=0 gives -> -1.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL