80% of population is vaccinated and 25% of infected had received the vaccine, what is the efficacy of the vaccine? 80% of population is vaccinated and 25% of infected had received the vaccine before being infected, what is the efficacy of the vaccine?
Lets denote
$\Pr(V) = 0.8$ (V="vaccinated")
$\Pr(I)$ is not given (I = "infected")
$\Pr(V\mid I) = 0.25$
What is the efficacy of the vaccine?
I am dumbfounded as I need to have either $\Pr(I)$ or $1-Pr(I)$ to solve any probability question related to this problem. For example $\Pr(I \mid V) = \frac{Pr(V \mid I)Pr(I)}{Pr(V)}$ which can be simplified because we know both $Pr(V)$ and $Pr(V \mid I)$: $Pr(I \mid V)=\frac{0.25*Pr(I)}{0.8}$, but then we hit brick wall as Pr(I) is not given.
 A: My response to the OP's concluding paragraph:
It is a common misconception that vaccine efficacy means the probability $P(I^c|V)$ of non-infection given that one is vaccinated.
Rather, vaccine efficacy measures the increase in protection conferred by the vaccine.
Your risk $P(I^c|V)$ of non-infection depends on the disease prevalence, and your exposure, safety measures, state of health, and vaccination status; vaccine efficacy (and vaccine effectiveness, for that matter) is not measuring this probability!
(Vaccine effectiveness is with reference to real-world data, whereas vaccine efficacy refers to clinical-trial results.) Note that none of this discussion, including what follows, takes immunity duration into consideration.

My Answer to main Question:
The technical definition of vaccine efficacy is given at the bottom of my Answer here. Note that this formula is based on an equal number of vaccinated and unvaccinated study subjects, which is not the case in your problem.
But we can adapt: based on your given setup/context,

*

*there are $4$ times as many vaccinated as there are unvaccinated
subjects;

*$25\%$ of the infected subjects had been vaccinated prior.

Thus, if the vaccine effectiveness is exactly $0\%$ (in other words, the vaccine has no effect), then we expect that among the infected, there will $4$ times as many vaccinated as there are unvaccinated subjects.
Since the actual multiple is $\frac{25}{75}=\frac13$ instead of $4,$ then the relative risk $R$ is $$\frac{\frac13}4=8.33\%,$$ so the vaccine effectiveness is $$1-R=91.67\%.$$
A: Suppose we have a group of $n$ people all of whom are susceptible to the disease when not vaccinated, and let $e$ be the efficacy of the vaccine (expressed as $ 0 \le e \le 1 $ rather than as a percentage) and let $v$ ($0 \le v \le 1$) be the population coverage of the vaccine. Then the number of vaccinated people falling sick, $s$, will be given by
$$ s = nv \left( 1 – e \right) \quad (1)$$
and the number of non-vaccinated people falling sick, $\bar s,$ will be given by
$$ \bar s = n \left( 1 – v \right) . \quad(2)$$
In the question the vaccine coverage is $80\%$, and so $v=0.8$. If we denote by $p$ the fraction of people falling sick that are vaccinated then we have
$$ p = \frac{ s } {s+\bar s}.$$
We are also given that $p=0.25$ since $25\%$ of the people falling sick have been vaccinated. Using equations (1) and (2) we get
$$ p =\frac{ s } {s+\bar s} = \frac{nv \left( 1 – e \right)}{nv \left( 1 – e \right) + n \left( 1 – v \right)}.$$
And so
$$ p= \frac{v-ve}{1-ve} ,$$
whereby solving for $e$ we obtain
$$ e= \frac{v-p}{v\left( 1-p \right) }.$$
Plugging in $p=0.25$ and $v=0.8$,
$$e= \frac{0.8-0.25}{0.8 \left( 1 – 0.25 \right) } = \frac{11}{12} \text{ or about } 91.67\%.$$
We can verify this by considering a population of $300$ susceptible people. Since the vaccine coverage is $80\%$, $240$ are vaccinated and $60$ are non-vaccinated. As the vaccine effectiveness is $11/12$ then $ 240 \times \left( 1- 11/12 \right) = 20$ of the vaccinated fall sick, which we add to the $60$ who fall sick in the non-vaccinated portion. Hence the fraction of vaccinated among all the sick is $20/ \left(20+60 \right) = 0.25,$ as required. Note that I have replaced the word efficacy with effectiveness. This is because we normally talk about efficacy in a trial situation and effectiveness in a real world situation and since we are reverse-engineering to obtain $e$ the data is very likely to come from a real world situation.
