|
Embedded Template Library 1.0
|
Classes | |
| struct | etl::log< NV, BASE > |
| struct | etl::log2< NV > |
| struct | etl::log10< NV > |
log<N, BASE> : Calculates logs to any base, rounded down to the nearest integer.
log2<N> : Calculates logs to base 2, rounded down to the nearest integer.
log10<N> : Calculates logs to base 10, rounded down to the nearest integer.
| struct etl::log |
The base generic log template. Defines value as the log of the number at the specified base. The result is rounded down to the next integer.
| NV | The number to find the log of. |
| BASE | The base of the log. |
Public Types | |
| enum | value_type { value = (NV >= BASE) ? 1 + log<NV / BASE, BASE>::value : 0 } |
| struct etl::log2 |