Re: New to Fortran on Win XP



Matti schrieb:
Hi all,

I wonder what's the best way to start learning Fortran 90/95/2003 on a
Win 32 XP Pro w. 2GB RAM. I have a wicked feeling that One has to use
the command prompt (that has a size of roughly 1MB on my computer), so
I cannot really understand how to run quite large programs.
I tried g95, compliled a small prg and got the desired a.exe . I
openend up a Window and clicked on my a.exe and a small command prompt
flashed on the screen. (Since I am not that fast I couldn´t really see
the desired output - I could when I ran the command prompt...) How to
proceed.

(Have tried a workaround by installing the VirtualBox and Ubuntu, but
then I can not access my HP Laserjet LPT printer. I imagined that I
would have been able to run the Fortran [gfortran on larger programs
than the 1MB for the Win Commmand prompt.)


It doesn't matter if you use ubuntu or windows. In general, mostly there are programs written for a windowing system, and others are written for the command line, which is called shell for the linux one (also often used for dos programs) and programs running inside cmd.exe in windows.

In other words, programs written for a command line should be used from the command line. Open a cmd.exe, change the directory to that of your program, and then type "a.exe" (you may type the fully qualified path to your a.exe also without changing the directory. Note, that the directory, which you can see in cmd.exe is the working directory of your program, so all your output files without a path are written in that directory. You may also use some tricks like piping the output to a file on the command line or getting input from a file, which looks like "infile.data < a.exe > outfile data. So you can see, working on the command line is very important). So you can see all of the output of your a.exe in the command window, if the buffer of the window is big enough (you can change the buffer size to a bigger one by clicking the top-left icon and then click on the properties).

I wish you a merry christmas, Sebastian.

Is the question clear enough?

Oh, yes I am not a computer linguist, so please no flames. OK? Thanks!


I hope that Santa can give me an answer... :-
BR Matti Sweden
.