There are two approaches to this question, a computational and an information-theoretic approach. It is unclear from the question which one is preferred.
I am going to assume that the number of output symbols that are not revealed ($512-k$) is larger than $n$, and consequently that $n$ is smaller than $512$.
Computationally, this is fairly easy to analyse. A hash function like SHA-512 in an application like this can reasonably be approximated by a random function. And for a random function, unless you know the preimage of the function value, each part of the function value is independent of every other part, so knowing $k$ of the output symbols does not help you determine the remaining $512-k$ output symbols.
For a random function, the only possible approach is to enumerate the inputs. If $k$ is large compared to $n$, you expect a random function to be injective (1-1), so you should be able to determine the input uniquely after enumerating half of all possible inputs ($2^{n-1}$).
If $k$ is small compared to $n$, you expect about $2^{n-k}$ possible preimages, each one leading to a different value for the $512-k$ output symbols.
If $k$ is approximately the size of $n$, you expect some collisions which makes exact (or even approximate) calculations tedious.
In either case, however, the expected effort involved in finding the output symbols is on the order of $2^n$ hash calculations, which means that this is the "computational strength" of the $512-k$ remaining output symbols.
Information-theoretically, we need to count the number of possible preimages. Assuming that SHA-512 can be approximated by a random function, we get as above, three cases: $k\ggg n$, $k\approx n$ and $k \lll n$. In the first case, you expect zero entropy. In the second case, you may have a small amount of uncertainty, while in the third case you have $n-k$ bits of entropy.
42
stands to the number forty-two. $\endgroup$k
as bits, good. So let's talk in the same units of measurement, thusk
is now the bits of the output, and remember that the hash output is also a secret, where k bits are revealed. $\endgroup$