HDTenEightyP/NetNews huggingface dataset:
From: burley@apple-gunkies.gnu.ai.mit.edu (Craig Burley)
Newsgroups: comp.lang.fortran
Subject: Re: SPECIFIC Question about Fortran  (vs. C)
Date: 30 Dec 92 23:35:31
Organization: Free Software Foundation 545 Tech Square Cambridge, MA 02139
NNTP-Posting-Host: apple-gunkies.gnu.ai.mit.edu
In-reply-to: ritley@uimrl7.mrl.uiuc.edu's message of Wed, 30 Dec 1992 18:32:34 GMT

In article <C034uA.7qu@news.cso.uiuc.edu> ritley@uimrl7.mrl.uiuc.edu () writes:

   In the recent discussion regarding whether or not Fortran is dead,
   the following comment piqued my curiosity:

   From: mjl@dino.ph.utexas.edu (Maurice J. LeBrun)

   >... Fortran (which translates very efficiently into machine
   >language) has stayed preeminent in numerical computing. 

   Although I could probably hunt down references about this in the
   library, I'd like to ask:  Do the standards which define Fortran
   actually specify the type of machine code to be generated?  Do 
   they specify, for example, _how_ a square root should be computed,
   or rather the accuracy with which it should be computed, or
   possibly none of these things?  

No.  No, no, yes.  As far as I can tell, it is standard-conforming
for

	WRITE (*,*) SQRT(4.)

to output:

	1.3

   In particular, although standard programs will compile on standard
   compilers, is there anything in the published Fortran standard
   which discusses the numerical results which standard programs are
   expected to output (excluding issues like number of loop
   iterations)?

Not really, no.  It is apparently not considered within the scope of a
language standard to specify the range and precision of numerical
results.

   [ If so, then might anyone know if 'C' similarly is written to conform
   to such standards. ]

C is no better in this regard.

I think the problem is that trying to have a language standard get too
involved with specifying conforming mathematics leaves the standard open
to becoming less useful for some machines that can't achieve standards
and those who exceed the standards.

Someday there might be an accepted way to specify _how_ accurate a
particular implementation of Fortran is, and that technique (or set of
techniques) might find its way into future standards for languages like
Fortran, but for now, leaving such stuff out is probably best.  Its
up to users to demand the accuracy/performance tradeoff they want in a
particular case.
--

James Craig Burley, Software Craftsperson    burley@gnu.ai.mit.edu
Member of the League for Programming Freedom (LPF) lpf@uunet.uu.net
Newsgroups: comp.lang.fortran
From: lionel@quark.enet.dec.com (Steve Lionel)
Subject: Re: A VMS Fortran I/O question
Organization: Digital Equipment Corporation
Date: Thu, 31 Dec 1992 15:32:42 GMT


In article <C03pyp.E4v@news.cso.uiuc.edu>, ercolessi@uimrl3.mrl.uiuc.edu 
(furio ercolessi) writes...
>Does anybody know (well, Steve Lionel certainly knows, but maybe
>he's in holiday ...) what should I do to kill the carriage control character 
>on the standard output in VMS Fortran ?
> 
>That is, I would like to be able to code something like
>      PRINT '(a)','Hello'
>instead of
>      PRINT '(1x,a)','Hello'
>in order to bring the code back and forth between Unix and VMS and 
>retain the same behavior  [please don't tell me i have to pipe the output 
>through 'asa' on the Unix side :-)]
> 
>I am sure there is some magic OPEN that does the trick.  If you do
>      OPEN(6,FILE='SYS$OUTPUT',STATUS='UNKNOWN',CARRIAGERETURN='LIST')
>then this fixes the WRITE(6,)  but not the PRINTs.
>The PRINTs go to a logical unit called FOR$PRINT but how should I
>reference it in the OPEN?  Is there a magic unit number associated
>with it? 
> 
>Thanks!
> 
>PS  OK, *real programmers* always use WRITE(6,)!

Yes, I do know, and no, I'm not on vacation (though perhaps I should be..)
But you're not going to like the answer....

There is a magic unit number for FOR$PRINT, -1, but you can't OPEN it
to change the carriage control setting and there's no other way I can
think of to accomplish this.  (Well, there's one, but I'm not sure it
will work - try it and see.  FOR$RAB will return you the RAB of unit
-1, and from that you can get the FAB.  You may then be able to 
SYS$CLOSE the file, change the carriage control to CR ('LIST'),
re-SYS$OPEN and SYS$CONNECT it.  You may have to fuss with the
filename, or perhaps set FAB$V_NAM to make it use the NAM block.  You'll
also have to have done one PRINT first to get the file open before 
FOR$RAB will work.)

Is this really easier than using WRITE(6,) instead?

Steve Lionel                    lionel@quark.enet.dec.com
SDT Languages Group
Digital Equipment Corporation
110 Spit Brook Road
Nashua, NH 03062
From: engel@vms.huji.ac.il
Newsgroups: comp.lang.fortran
Subject: rules for efficient programming in Fortran?
Date: 3 Jan 93 20:39:36 GMT
Organization: The Hebrew University of Jerusalem

Hello,
Do you have rules for efficient programming in FORTRAN
(or suggestions for reading appropriate books)
so that there is no excessive or unnecessary CPU? If so,
could you send them to me?
Thanks,
Micky Engel
(e-address: engel@hujivms.bitnet OR engel@shum.cc.huji.ac.il)
From: ake@dayton.saic.com (Earle Ake)
Newsgroups: comp.lang.fortran
Subject: Re: swapping bytes on a two byte integer
Date: 22 Dec 1992 13:35:49 -0500
Organization: Science Applications Intl Corp - Dayton, Ohio
NNTP-Posting-Host: dayton.saic.com
X-Newsreader: TIN [version 1.1 PL8]

Griff Miller X7114 (miller@hmsp04.wg3.waii.com) wrote:
: In article <BzB6rI.LI7@acsu.buffalo.edu> acscmaw@ubvmsb.cc.buffalo.edu (MARK WIECZOREK) writes:
: >
: >I have a very simple problem. I have a binary data file composed of two byte
: >integers. After reading the data I would like to change the order of the 
: >bytes and write the result to a file. I've looked through the vax fortran
: >manuals and couldn't find a way to do this. Any help would be greatly
: >appreciated. 
: >
: >Mark Wieczorek

: How about: 

:       CHARACTER*1 CWORK
:       CHARACTER*2 C2BYT
:       INTEGER IUNIT,OUNIT

:       IUNIT=1
:       OUNIT=2
: C (OR WHATEVER)

:       READ (IUNIT) C2BYT
:       CWORK=C2BYT(1:1)
:       C2BYT(1:1)=C2BYT(2:2)
:       C2BYT(2:2)=CWORK
:       WRITE (OUNIT) C2BYT 

:       END

	REAL FORTRAN programmers use equivalence statements to get the job
done with no wasted space!

	CHARACTER*2 AWORD
	CHARACTER*1 ABYTE(2)
	EQUIVALENCE (AWORD, ABYTE(1))

	READ(1) ABYTE(2), ABYTE(1)
	WRITE(2) AWORD

	END


: Note: Even though I used all caps, I do not presume to be a 
: Real Programmer.  :-)

	I am not going by my own rules here but a real FORTRAN programmer does
not use character variables and only uses 6 spaces at the beginning of the line
instead of the wimpy tab character that so many compilers allow now.  Remember,
key punches didn't deal with the tab key very well.


-Earle
-- 
Earle Ake  Internet: <ake@dayton.saic.com>  NSI-DECnet (SPAN): 28276::ake
Newsgroups: comp.lang.fortran
From: bibhas@pico.engr.mun.ca (Bibhas Bhattacharya)
Subject: Public domain F77 compiler for DOS?
Keywords: Fortran compiler
Organization: Memorial University of Newfoundland
Date: Tue, 29 Dec 1992 19:56:32 GMT

Hi!
Is there any free FORTRAN compiler for DOS?
Thanks.
Bibhas.
--
	+==========================+=========================+
	| login name: DR. Jackyl   |  In real life: Mr. Hyde.|
	+==========================+=========================+
		          bibhas@pico.engr.mun.ca
From: kim@cc.usu.edu
Newsgroups: comp.lang.fortran
Subject: fortran flowcharts?
Date: 30 Dec 92 13:59:54 MDT
Organization: Utah State University

  We are looking for a program to read a Fortran program and
generate a flowchart.   Has anyone seen or heard of such a program?
Thanks for any and all suggestions.

				Kim Marshall
                                kim@cc.usu.edu
From: tim@ksr.com (Tim Peters)
Newsgroups: comp.lang.fortran
Subject: SKOL (was Re: Uglifier (was Re: Real Programmers))
Date: 22 Dec 92 00:28:59 EST

>[wws@craywr.cray.com (Walter Spector)]
>...
>There was even an undocumented extension in the old CFT Fortran
>compiler called 'IMPLICIT SKOL' which did something magical with
>variables starting with I00.  ...

=jot@cray.com (Otto Tennant)]
=...
=It is equivalent to 'IMPLICIT NONE', but allowing implicit integer
=declaration of variables beginning I00.

Tee hee.  I had forgotten all about this, Otto -- & I'm the poor sap who
implemented IMPLICIT SKOL in CFT <shudder, am I really that old?!>.  It
did one other thing:  forgave you if you didn't declare externals via
EXTERNAL, provided again that their name began with "I00".  That's the
whole scoop.

=... it appears to be based on STAGE2, from the early 70's at U of
=Colorado.

That's my recollection too -- bet David Prigge would know.

+[nick@idacrd.UUCP (Nick Patterson)]
+...
+I will probably get some perhaps justified abuse and humiliation for the
+following:  SKOL was a great preprocessor, with all sorts of neat features
+...

No argument here!  SKOL was a wonderfully expressive language given the
alternatives (CFT & CAL) available at the time.  Besides the usual things
that kill macro-based languages, there were (IMO) three others:

1) Otto's
   =When you look inside SKOL (I recommend Dramamine first), ...

   Adding a new feature to SKOL-- or fixing an old one --was an absolute
   nightmare.

2) At a time when CFT was cranking thru 50,000 - 100,000 source lines a
   minute, compiling a few pages of SKOL was cause for a cigarette break.
   _Incredibly_ slow.

3) SKOL ran off in directions users didn't want (e.g., coroutines come to
   mind ...).

+So I ported it to UNICOS for my own use!
+SKOL lives!!

Nick, that is so sick <grin>.

wondering-if-ksr-could-make-a-new-sale-by-offering-skol<ahem>-ly y'rs
   - tim

Tim Peters   Kendall Square Research Corp
tim@ksr.com,         ksr!tim@uunet.uu.net
Newsgroups: comp.lang.fortran
From: ercolessi@uimrl3.mrl.uiuc.edu (furio ercolessi)
Subject: A VMS Fortran I/O question
Reply-To: ercolessi@uimrl3.mrl.uiuc.edu (furio ercolessi)
Organization: MRL - UIUC
Date: Thu, 31 Dec 1992 02:08:48 GMT

Does anybody know (well, Steve Lionel certainly knows, but maybe
he's in holiday ...) what should I do to kill the carriage control character 
on the standard output in VMS Fortran ?

That is, I would like to be able to code something like
      PRINT '(a)','Hello'
instead of
      PRINT '(1x,a)','Hello'
in order to bring the code back and forth between Unix and VMS and 
retain the same behavior  [please don't tell me i have to pipe the output 
through 'asa' on the Unix side :-)]

I am sure there is some magic OPEN that does the trick.  If you do
      OPEN(6,FILE='SYS$OUTPUT',STATUS='UNKNOWN',CARRIAGERETURN='LIST')
then this fixes the WRITE(6,)  but not the PRINTs.
The PRINTs go to a logical unit called FOR$PRINT but how should I
reference it in the OPEN?  Is there a magic unit number associated
with it? 

Thanks!

PS  OK, *real programmers* always use WRITE(6,)!
--
Furio Ercolessi
Materials Research Laboratory           |   Intl School for Advanced Studies
Univ. of Illinois at Urbana-Champaign   |   Trieste, Italy
furio@uiuc.edu                          |   furio@sissa.it
Newsgroups: comp.lang.fortran
From: ritley@uimrl7.mrl.uiuc.edu ()
Subject: Re: fortran flowcharts?
Reply-To: ritley@uiucmrl.bitnet ()
Organization: Materials Research Lab
Date: Wed, 30 Dec 1992 23:05:02 GMT

In article <1992Dec30.135954.62361@cc.usu.edu>, kim@cc.usu.edu writes:

|>
|>  We are looking for a program to read a Fortran program and
|>generate a flowchart.   Has anyone seen or heard of such a program?
|>Thanks for any and all suggestions.
|>
|>				Kim Marshall
|>                                kim@cc.usu.edu
|>

I recall a fairly good program called Flow-Tran (If I remember correctly),
which was installed on the Cyber (NOS) computer system at Sonoma State
University (Rohnert Park, California) in 1986, or thereabouts.

If all else fails and you are sufficiently desperate, you might try
contacting the computer center there, to see if anyone remembers
or still has this program.  And failing that I suppose you could contact
the Control Data Corporation, although I am not certain whether
Flow-Tran was distributed by CDC.

Sorry I can't be of more help than that.....
From: dbillesbach@crcvms.unl.edu
Newsgroups: comp.lang.fortran
Subject: Re: MS-FORTRAN
Date: 23 Dec 92 09:15:10 CST
Organization: University of Nebraska--Lincoln	
NNTP-Posting-Host: crcvms.unl.edu

In article <1992Dec22.124057.759@walter.cray.com>, trauger@cray.com (Jimbo Trauger) writes:
> 
> Hi, 
{original text deleted}
> Jim Trauger

     Jim:

MS FORTRAN can use several different libraries.  They determine how 
floating point is implemented.  If the library file name ends in "7", you 
must have an 80x87 co-processor chip, if the file name ends in "E", you 
don't need the co-processor (but I think that it is used if it is present), 
and if the file name ends in "A", a propriatary, non-IEEE compliant 
floating point standard is used.  Details of all of this are in the 
documentation.  My best guess of your problem is the following.  You have a 
co-processor and installed the "7" library.  When you compiled, however, 
the "fl" processor defaults to the "E" library which is not present in your 
library directory.  To get around this, you can specify the proper library 
with the following "fl" switches:  /FPc87 or /FPi87 (see the manual for the 
differences in these).  The other solution is to add the following command 
line to your AUTOEXEC.BAT file:

set fl= /FPi87

I may also have this backwards, and you might need to "tell"  fl to use the 
"E" or "A" library.  Anyway, I hope this helps.

                      Dave B.

                                _  ,/|
                               '\`o.O'
                                =(_ _)=
                                  |U|

                          Ackkkk!!   Tbhppphhhh!!
From: torres@ee470.ee.mcgill.ca ( mario  torres )
Newsgroups: comp.lang.fortran
Subject: Help in learning FORTRAN
Date: 31 Dec 92 19:37:49 GMT
Organization: EE Lab, McGill University EE Lab, Montreal


Hello:
	I would like to know if anyone could advise me as to some good
books available on FORTRAN.  I am new to the language and need to learn 
it in order to do some software maintenance.
I would appreciate it if anyone could send a list or post it or direct me
to an ftp site.

Thanks in advance.
From: doug@hopey.telcom.arizona.edu (Doug Wellington USGS)
Newsgroups: comp.lang.fortran
Subject: SOLVED: Common block problem with MS-FORTRAN
Date: 31 Dec 92 23:13:00 GMT
Distribution: world,local
Organization: University of Arizona Telecommunications
News-Software: VAX/VMS VNEWS 1.41

I solved the problem with the common block crossing the segment
barrier by counting all of the bytes in all of the items in the
common block and padding so that no variable actually lay "on top"
of the end of the segment.

In this case, I had several arrays of CHARACTER and INTEGER that
added up to a total of 44000 bytes.  Then I had an array of CHARACTER*30
that took the total up to 74000.  (All of the arrays had 1000 elements.)
64K comes out to 65536 bytes, so I subtracted the 44000 from that which
left 21536, then I divided by 30 (for each element in the CHARACTER*30).
That gave me 717 with a remainder of 26. (Aha!)  That meant that the 718th
element had 26 characters in the first segment and 4 in the second.  So
the solution was to add one CHARACTER*26 in front of the whole array of
CHARACTER*30, so that the 718th element actually started in the second
segment.  Sheesh!

Thanks to everyone who replied.  I tossed the mail already, so I'm sorry
I can't thank people by name, but you guys know who you are. Thanks again!
-Doc
From: chew@accel.aa.washington.edu (Gilbert Chew)
Newsgroups: comp.lang.fortran
Subject: Is FORTRAN a viable language?
Date: 29 Dec 1992 23:41:27 GMT
Organization: U of Wash Dept of Aeronautics and Astronautics
Distribution: world
Reply-To: chew@accel.aa.washington.edu (Gilbert Chew)
NNTP-Posting-Host: accel.aa.washington.edu

Is FORTRAN dead?

I myself program in FORTRAN, and I am hoping to 
eventually purchase a FORTRAN compiler for my
own PC (a 386-33, incidentally).

However, while perusing the newsgroups for help
and information in buying said compiler, I noticed
that the C/C++ newsgroup seems to have about
100 times the traffic of the FORTRAN newsgroup!

I had always thought that, while C/C++ may be
getting more publicity, there were still scientists
and engineers who used FORTRAN.  So, where are
all the FORTRAN messages?

Various magazine articles in the campus library seem
to give the impression that FORTRAN is NOT dead, 
since "everybody" still uses it.  If so, then why are there
so few compilers on the market?  In Programmer's
Paradise, Programmer's Shop, Programmers Up the Butt,
The Connection, etc. (mail-order catalogs all), the
C/C++ compilers outnumber the FORTRAN compilers
several times over!

The ultimate question is, I guess, Should I even bother
with the FORTRAN compiler?  Or should I make my main
language C/C++?  Will there still be support for FORTRAN
in 10 years?
From: johnl@iecc.cambridge.ma.us (John R. Levine)
Newsgroups: comp.lang.fortran
Subject: Re: fortran flowcharts?
Date: 3 Jan 93 18:11:17 GMT
Article-I.D.: iecc.9301031311.AA03638
Organization: I.E.C.C.

>  We are looking for a program to read a Fortran program and
>generate a flowchart.

I used a commercial program called AUTOFLOW to do this 20 years ago.
It was well suited to the task of providing program flowcharts
because some bozo's checklist said they had to exist, even though the
program was already written.  As is the case with most flowcharts,
they were so voluminous as to be useless.

AUTOFLOW was sold by Applied Data Research in Princeton NJ which was
absorbed into some part of Bell Atlantic several years ago.

Regards,
John Levine, johnl@iecc.cambridge.ma.us, {spdcc|ima|world}!iecc!johnl
Newsgroups: comp.lang.fortran
From: walt@netcom.com (Walt Brainerd)
Subject: Re: Dynamic Memory Allocation in FORTRAN, Question
Organization: Netcom - Online Communication Services  (408 241-9760 guest) 
Date: Tue, 22 Dec 1992 00:37:35 GMT

In article <BzMK05.HJ2@news.cso.uiuc.edu>, ercolessi@uimrl3.mrl.uiuc.edu (furio ercolessi) writes:

> Ooops! Sorry. Then I misinterpreted a discussion here some weeks 
> ago. I will always add the number, promised!

I don't think you misinterpreted the discussion.
I think that discussion misrepresents history, so I thought
I should get my $0.02 worth in before it becamse the
"established" word.

Sorry I came down on your comments.  And I think the idea
of adding the number to clarify which standard is being
discussed is the only way to go.
-- 
Walt Brainerd                walt@netcom.com
Unicomp, Inc.                +1-415-949-4052
235 Mt. Hamilton Ave.        +1-415-949-4058 (fax)
Los Altos, CA 94022 USA      "F90--Fortran for the '90s"
From: jpeach@ac.dal.ca
Newsgroups: comp.lang.fortran
Subject: graphics in fortran
Date: 29 Dec 92 15:32:06 GMT
Organization: Dalhousie University, Halifax, Nova Scotia, Canada

I am going to be writing  a program in fortran that is going
to require some basic graphics ability.  What I want to be able
to do is to draw some line graphics in two dimensions.  I am
finding it difficult to locate a tool that woill add me in doing
this in fortran.  It has be be some type of standard so that
the software can be compiled on the IBM PC, MAC and the VMS
computers.  I discovered there is a standard called GKS
(Graphics Kernaling System)  It will do everything that I want
it to but I cannot find a company that sells it.  Can anyone
tell me were I can get this software tool or any other tools
that will work.  Please e-mail me at JPEACH@ac.dal.ca or
post a message here.  Thanks.
 
 
///MiStEr pEaCh\\\
Newsgroups: comp.lang.fortran
From: walt@netcom.com (Walt Brainerd)
Subject: Re: All I want for Xmas is the NAG library..........
Organization: Netcom - Online Communication Services  (408 241-9760 guest) 
Date: Mon, 21 Dec 1992 17:11:50 GMT

In article <1992Dec21.142059.6569@murdoch.acc.Virginia.EDU>, sts6f@vortex.mech.virginia.edu (Sonya T. Smith) writes:
> But seriously folks,  I would greatly appreciateit if someone would email to me
> instructions on where and how to get the NAG library.  
> 
Numerical Algorithms Group, Inc.
1400 Opus Place, Suite 200
Downers Grove, IL 60515
708-971-2337  971-2706 (fax)
-- 
Walt Brainerd                walt@netcom.com
Unicomp, Inc.                +1-415-949-4052
235 Mt. Hamilton Ave.        +1-415-949-4058 (fax)
Los Altos, CA 94022 USA      "F90--Fortran for the '90s"
Newsgroups: comp.lang.fortran
From: brent@ssd.csd.harris.com (Brent Benson)
Subject: Re: Dynamic Memory Allocation in FORTRAN, Question
Organization: Harris Computer Systems
Date: Mon, 21 Dec 1992 15:54:22 GMT

xiong@spade.rutgers.edu (Xiong) writes:

> Hi, I am wondering if it is possible to allocate memory dynomically
> in FORTRAN as in C?

Not in standard FORTRAN.  There are sometimes vendor extensions to do
this sort of thing.  For example, we have recently implemented (after
a customer request) something called pointer blocks in our f77
compiler.  These are similar to common blocks, but are dynamic rather
than static in nature.  The name of the pointer block needs to be an
integer*4 variable which will hold the address of the allocated memory
for the block.  We also provide a malloc() function for allocated the
space and a sizeofblock() function for automatically determining the
size of a given pointer block.

> I am loooking for something equivalent to: 
> int * a; a = (int *) malloc (numx * sizeof (int)); 
> in C.

	integer*4 ptr1, numx
	pointer /ptr1/ numx

	external malloc
	integer*4 malloc

	ptr = malloc(sizeofblock(ptr1))
	
--
Brent Benson                     
Harris Computer Systems
Newsgroups: comp.lang.fortran
From: wws@craywr.cray.com (Walter Spector)
Subject: Re: Dynamic Memory Allocation in FORTRAN, Question
Organization: Cray Research, Inc.
Date: 22 Dec 92 13:35:59 CST

In article <Dec.20.02.22.20.1992.7312@spade.rutgers.edu>, xiong@spade.rutgers.edu (Xiong) writes:
|> Hi, I am wondering if it is possible to allocate memory dynomically in
|> FORTRAN as in C?

There are no Standard mechanisms in the Fortran-77 Standard for performing
dynamic memory management.  Standard non-Standard ways of doing it usually
involve overindexing blank common or some form of pointers combined with
with a sbrk(2)-like or malloc(3c)-like interface.  Performing your own
sbrk system calls is obviously dangerous in a Unix-like environment,
calling a malloc-like routine is more reliable.

In a compiler with Fortran-90 memory management, there are two Standard
options: Automatic arrays which are very nice for scratch arrays,
and ALLOCATABLE variables combined with the ALLOCATE/DEALLOCATE statements
which give a more general capability.  (Note that in Fortran-90, pointers
would generally not be used for memory management.)  Compilers exist which
support one or both of these facilities.

Your compiler system will probably support one or more of the above
techniques.  RTFM for more details.

|> Thanks a lot for your help. If this question has been asked before (I
|> did not find it in the FAQ)

This really is a FAQ and should be included.  Keith?

Walt
----
Walt Spector
(wws@renaissance.cray.com)
Sunnyvale, California
_._ _._ _.... _. ._.