The problem happens because the jupyter notebook can not process the standard stdin in sub-processes.
Even if you run a shell command (also executed in a subprocess) that uses the default input, the kernel will "hang" (eventually emitting a restart message or not).
Example, if you run the command below in a notebook cell:
on Windows:
!set /p variavel="Digite um valor "
or UNIX / OS X:
!read -p "Digite um valor " variavel
The kernel "hangs", waiting for input.
A possible workaround for this problem: read the input values in the Python code and send these values as parameters for the Fortran routine:
x=input("Valor X ")
y=input("Valor Y ")
a=input("Valor A ")
f1(x, y, a)