Very short comparison of Fortran90 and C. This has basically everything you need to write your subroutines for the mdmorse code: Declaring variables ------------------- Fortran90 C --------- ------- real(double) double integer int Relational operations --------------------- Same except that != in C is /= in Fortan Logical operations ------------------ Fortran90 C --------- ------- .and. && .or. || .not. ! Arithmetic ---------- Identical to C, except that +=, ++, -- etc. is missing. You can easily replace these with i=i+1 ja i=i-1 and so on. Commands: --------- Fortran90 C --------- ------------------------- do i=1,N for (i=1;i<=N;i++) { ... ... enddo } if (i <= n) then if (i<=n) { ... else } else { ... endif } cycle continue; exit break; Subroutines ----------- stop 'End of program' exit(0); call subprogram(x) subprogram(&x) subroutine subprogram(x) subprogram(x) implicit none real(double) x double *x; Input-output ------------ open(10,file="outfile") fp=fopen("outfile","w") write (10,*) "Cu",x fprintf(fp,"%s %g\n","Cu",x); close(10) fclose(fp) Note that all parameters passed to subroutines in Fortran are by default passed by reference, not by value as in C. Hence to get the C correspondence you need to use &x.