[Pw_forum] interactive mm_dispersion routine

Paolo Giannozzi p.giannozzi at gmail.com
Fri Apr 8 07:42:47 CEST 2016


Unit 4 is used at the end of the run, so it may be a good idea to close it,
or to use unit 5 instead

Paolo



On Thu, Apr 7, 2016 at 7:23 PM, Roberto Pasianot <rpasianot at gmail.com>
wrote:

> Ciao Aldo, this works for me
>
>         open(unit=4,file='/dev/stdin')
>         open(unit=3,file='/dev/stderr')
>         read(4,*)a
>         write(3,*)'This is a: ',a
>         end
>
> Regards,
>
> Roberto
>
>
> On 4/7/16, Aldo Ugolotti <a.ugolotti at campus.unimib.it> wrote:
> > Dear qe users,
> > I'm trying to modify mm_dispersion file to have it asking interactively
> for
> > some vdw coefficient AND radii. Hence I'm adding few lines to the file,
> in
> > particular a write and a read statement. I get two problems:
> > 1) writing to stdout the string gets taken from output file by
> redirection,
> > but using stderr flow the compiler says that it's not defined;
> > 2) I'm not able to correctly define an input device for reading the
> values:
> > I've tried "100", "*" and "stdin". In this cases compiling is not a
> > problem, but running the code gets always an error saying "unit -4
> > unexpected end of file".
> > How can I solve this?
> >
> > Thanks in advance,
> >
> > Aldo Ugolotti
> > Master's thesist
> > Università di Milano-Bicocca
> >
>
> _______________________________________________
> Pw_forum mailing list
> Pw_forum at pwscf.org
> http://pwscf.org/mailman/listinfo/pw_forum




-- 
Paolo Giannozzi, Dip. Scienze Matematiche Informatiche e Fisiche,
Univ. Udine, via delle Scienze 208, 33100 Udine, Italy
Phone +39-0432-558216, fax +39-0432-558222
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.quantum-espresso.org/pipermail/users/attachments/20160408/7c44c42d/attachment.html>


More information about the users mailing list