Empirically it seems
$$\lim_{k\to \infty} \frac{1}{k}\sum_{n=1}^k \frac{g(n)}{\log p(n)} = 1\tag{1} $$ in which p(n) is the nth prime and g(n) is the prime gap $p(n+1)-p(n).$
Cramer conjectured that
$$g(n) = O\left(\log^2 p(n)\right). $$
My somewhat open-ended question is:
Formally how does (1) relate to Cramer's estimate (if at all)...and can we prove (1)?
For instance, we might have infinitely many values $\frac{g(n)}{\log p(n)}$ close to $0$ for prime gaps of $2$.
So clearly $(1) \nrightarrow g(n) \sim \log p(n).$ But can we say for general $f(n), g(n)$ for example that
$$\lim_{k \to \infty} \frac{1}{k}\sum \frac{f(n)}{g(n)} = 1 \rightarrow f(n) = O(g(n))? $$
I would prefer the question be construed broadly in case I have missed something about how these two ideas relate. Thank you for any insights.
This is true, but it does not use any properties of prime gaps deeper than the prime number theorem.
For primes, the condition $p(n+1) < 2 p(n)$ is Bertrand's postulate. So this implies that your limit is $$\lim_{k \to \infty} \frac{1}{k} \int_{t=2}^{p(k+1)} \frac{dt}{\log t} = \lim_{p \to \infty} \frac{1}{\pi(p)-1} \int_{t=2}^{p} \frac{dt}{\log t}.$$ By the prime number theorem, this limit is $1$.
So, let's prove the claim. The function $1/\log t$ is decreasing. So the integral $\int_{t=2}^{p_{k+1}} \frac{dt}{\log t}$ is bounded above and below by its left and right Riemann sums. We choose a Riemann sum whose division points are $p_1$, $p_2$, ..., $p_{k+1}$: $$\sum_{n=1}^k \frac{p_{n+1}-p_n}{\log p_n} \ > \ \int_{t=2}^{p_{k+1}} \frac{dt}{\log t} \ > \ \sum_{n=1}^k \frac{p_{n+1}-p_n}{\log p_{n+1}} > \ \sum_{n=1}^k \frac{p_{n+1}-p_n}{\log p_{n} + \log 2}$$ where the last inequality is by the Bertrand like condition.
For any $\epsilon>0$, there will be some $m$ such that $\log 2/\log p_n < \epsilon$ for $n > m$. So the last term is $$> \sum_{n=1}^m \frac{p_{n+1}-p_n}{\log p_{n} + \log 2} + \frac{1}{1+\epsilon} \sum_{n=m+1}^k \frac{p_{n+1}-p_n}{\log p_n} = -C_{\epsilon} + \frac{1}{1+\epsilon} \sum_{n=1}^m \frac{p_{n+1}-p_n}{\log p_{n}}$$ for a constant $C_{\epsilon}$. So the limit in the claim is bounded between $1$ and $1/(1+\epsilon)$ for any $\epsilon>0$.