Calculates power of 2.

Namespace:  AForge.Math
Assembly:  AForge.Math (in AForge.Math.dll) Version: 2.2.5.0 (2.2.5.0)

Syntax

C#
public static int Pow2(
	int power
)

Parameters

power
Type: System..::.Int32
Power to raise in.

Return Value

Returns specified power of 2 in the case if power is in the range of [0, 30]. Otherwise returns 0.

See Also