I have a question about big O notation. Let's say I have 3 algorithms which, for an input of size $n$, have time complexity $O(n)$, $O(n^2)$ and $O(n \log n)$, respectively. Assume that all 3 algorithms take $a$, $b$ and $c$ seconds for the worst, average and best cases given an input of size $n$. What could be the actual time of these 3 algorithms given an input of size $2n$? Based on my understanding it should be:
$O(\cdot)$ only gives upper bounds. Being told that $f(n)=O(n\log n)$ doesn't exclude the possibility that $f(n)=n$, $f(n)=1$, etc.
The bounds only apply to sufficiently large $n$. Perhaps your measurements were for values of $n$ that are too small to exhibit the asymptotic behaviour.
Even if $n$ was large enough, consider the algorithm "If my input has odd length, return immediately; otherwise, perform some calculation that takes exactly $n^2$ steps." This has running time $O(n^2)$, so you'd expect an input twice as big to take four times as long. But an odd-length input will take about $n$ steps, whereas $2n$ is even, so an input of that length would take time at least $(2n)^2$, which is much more than four times as much.
The actual running time of the code on an actual computer will depend on all kinds of factors that aren't included in the theoretical analysis. You could be careful to exclude things such as interruptions by other processes, but consider something like disc access. Suppose that your input of size $n$ takes up a quarter of a disc block. Most of the running time of your algorithm might be waiting for that one block to be transferred; the input of length $2n$ will also fit in one block, so you do the same amount of disc I/O and doubling the input takes only a small fraction longer to run. On the other hand, if your length-$n$ input is a whole block, then reading two blocks will take twice the time. Except that the OS will probably cache the second block for you, so probably it won't. Similar effects apply to memory accesses and their interaction with the cache.
Your arithmetic is off. Consider the three functions $f(n)=n$, $g(n)=n^2$ and $h(n)=n\log_2 n$. Then
h(2n)=2n\log_2 2n = 2n(\log_2 n+\log_2 2) = 2h(n)+2n\,.$$