| rte_approx.h(3) | Library Functions Manual | rte_approx.h(3) |
rte_approx.h
#include <stdint.h>
int rte_approx (double alpha, double d, uint32_t *p,
uint32_t *q)
int rte_approx_64 (double alpha, double d, uint64_t *p, uint64_t *q)
RTE Rational Approximation
Given a rational number alpha with 0 < alpha < 1 and a precision d, the goal is to find positive integers p, q such that alpha - d < p/q < alpha + d, and q is minimal.
Definition in file rte_approx.h.
Find best rational approximation
Parameters
Returns
Find best rational approximation (64 bit version)
Parameters
Returns
Generated automatically by Doxygen for DPDK from the source code.
| Version 24.11.3 | DPDK |