From: CapCity on
In the following statement:

read(strtmp(:j-1),'(i)')

Is the (i) the same as (i1)? If not, what does it mean?

Thanks!


From: steve on
On Apr 2, 12:18 pm, "CapCity" <C...(a)City.com> wrote:
> In the following statement:
>
> read(strtmp(:j-1),'(i)')
>
> Is the (i) the same as (i1)? If not, what does it mean?
>

Is that a verbatim copy of the line of code?

--
steve

From: CapCity on

"steve" <kargls(a)comcast.net> wrote in message
news:a739b63b-5ef3-4dca-a5f4-933025c7d566(a)l25g2000yqd.googlegroups.com...
On Apr 2, 12:18 pm, "CapCity" <C...(a)City.com> wrote:
> > In the following statement:
> >
> > read(strtmp(:j-1),'(i)')
> >
> > Is the (i) the same as (i1)? If not, what does it mean?
> >

> Is that a verbatim copy of the line of code?

Sorry, no, it wasn't. Slipped on the copy and paste:

read(strtmp(:j-1),'(i)') iprate(iprate(0,i),i)



> --
> steve



From: Steve Lionel on
On 4/2/2010 1:18 PM, CapCity wrote:
> In the following statement:
>
> read(strtmp(:j-1),'(i)')
>
> Is the (i) the same as (i1)? If not, what does it mean?

The use of just I as a format edit descriptor is non-standard. For the
compilers I am familiar with, it is allowed as an extension and says to
have the processor determine the width based on the type/kind of the
corresponding I/O list element. For example, in Intel Fortran, the width
chosen is 7 for INTEGER(1) and INTEGER(2), 12 for INTEGER(4) and 23 for
INTEGER(8).

--
Steve Lionel
Developer Products Division
Intel Corporation
Nashua, NH

For email address, replace "invalid" with "com"

User communities for Intel Software Development Products
http://software.intel.com/en-us/forums/
Intel Software Development Products Support
http://software.intel.com/sites/support/
My Fortran blog
http://www.intel.com/software/drfortran
From: Richard Maine on
Steve Lionel <steve.lionel(a)intel.invalid> wrote:

> On 4/2/2010 1:18 PM, CapCity wrote:
> > In the following statement:
> >
> > read(strtmp(:j-1),'(i)')
> >
> > Is the (i) the same as (i1)? If not, what does it mean?
>
> The use of just I as a format edit descriptor is non-standard. For the
> compilers I am familiar with, it is allowed as an extension and says to
> have the processor determine the width based on the type/kind of the
> corresponding I/O list element. For example, in Intel Fortran, the width
> chosen is 7 for INTEGER(1) and INTEGER(2), 12 for INTEGER(4) and 23 for
> INTEGER(8).

Though I'm more used to seeing that kind of extension on output than
input. I might guess that it is intended to be something like
list-directed input, but that is just a guess. The only safe statement
is that it is nonstandard, as you said.

If I were porting it and had no other information, I'd probably be
inclined to try to substitute list-directed input (given at least an f90
compiler, as list-directed internal input was nonstandard in f77).

--
Richard Maine | Good judgment comes from experience;
email: last name at domain . net | experience comes from bad judgment.
domain: summertriangle | -- Mark Twain