How to print out a Fortran array
  Home FAQ Contact Sign in
 
Advanced search
MATCHING GROUPS



more...
POPULAR GROUPS

more...

found 454 articles for 0.009 sec
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Michael Prager
Date: Nov 20, 2006 07:33

...: Sorry. I may be wrong. I thought that in Fortran, array can have any type, not "single type". For ...know PS(1) is an integer and PS(2) is a character array, how can I print array PS? Shawn, It appears that you are unfamiliar with many basic points of Fortran. May I suggest that you take an online tutorial on Fortran? There are many -- use Google to find them. I think ...
Show full article (0.83Kb) · Show article thread
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: glen herrmannsfeldt
Date: Nov 17, 2006 12:11

.... I may be wrong. I thought that in Fortran, array can have any type, not "single type". For example: PS(1) = 3 ...1) is an integer and PS(2) is a character array, how can I print array PS? Many interpreted languages can do that. AWK, Mathematica, and R are some that ...can store different types in the way you say. Fortran doesn't do that, never did, and likely ...
Show full article (0.73Kb)
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: nospam
Date: Nov 17, 2006 11:45

Shawn <shaw@nospam.com> wrote: I thought that in Fortran, array can have any type, not "single type". For example: PS(1) = 3 PS(2)... sure what language you are thinking of, but it isn't Fortran. Equivalence can sort of do something vaguely related, provided that you ignore the fine print that says it isn't technically valid (and it is usually...
Show full article (0.94Kb)
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Shawn
Date: Nov 17, 2006 11:34

...> This does not make sense to me. An array contains variables of a single type, and ..."repeat edit descriptor" as in "(10f10.6)" to print 10 reals per line. Sorry. I may be wrong. I thought that in Fortran, array can have any type, not "single type". For example: PS(1) = 3 ...(1) is an integer and PS(2) is a character array, how can I print array PS? Thank you very much for your help.
Show full article (0.71Kb) · Show article thread
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Dylan Sung
Date: Nov 17, 2006 13:52

... I still have a question: I have an array holding real type of data, if I...following? DO 210 I=1, array_dimension_unknown PRINT *, 'TSDATA(',I,')= ', TSDATA(I) 210 CONTINUE ...tell us which compiler you're using. In Fortran 95 you could write: DO I=1, size(TSDATA) PRINT *, 'TSDATA(',I,')= ', TSDATA(I) end do ...
Show full article (1.24Kb) · Show article thread
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Beliavsky
Date: Nov 17, 2006 13:31

...> DO 210 I=1, array_dimension_unknown PRINT *, 'TSDATA(',I,')= ', TSDATA(I) 210 ... use for array_dimension_unknown? What version of Fortran are you using? I strongly ...The issue of which standard of Fortran to use is often discussed ... determine the dimensions of an array in the main program or ... as "assumed shape" array. Unrelated matter -- in Fortran 90 and later ...
Show full article (1.05Kb) · Show article thread
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Michael Metcalf
Date: Nov 17, 2006 13:20

...Now I still have a question: I have an array holding real type of data, if I...following? DO 210 I=1, array_dimension_unknown PRINT *, 'TSDATA(',I,')= ', TSDATA(I) 210 CONTINUE ... tell us which compiler you're using. In Fortran 95 you could write: DO I=1, size(TSDATA) PRINT *, 'TSDATA(',I,')= ', TSDATA(I) end do However, it...
Show full article (0.82Kb)
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Shawn
Date: Nov 17, 2006 13:10

Thank you all. I was confused. Now I still have a question: I have an array holding real type of data, if I don't know its dimension(e.g. array size), can I write a loop to print each item out? Something like the following? DO 210 I=1, array_dimension_unknown PRINT *, 'TSDATA(',I,')= ', TSDATA(I) 210 CONTINUE Thank you very much.
Show full article (0.36Kb) · Show article thread
Re: How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Beliavsky
Date: Nov 17, 2006 10:18

...> I am trying to understand a Fortran program. I hope to print out one array to the...how can I write statements to print them out? I don't really...not make sense to me. An array contains variables of a single type..." as in "(10f10.6)" to print 10 reals per line. If a...> I am very new to Fortran. I only know such statements(... one is a 3 character): PRINT *, 'TS(1)= ', TS(1) WRITE ...
Show full article (0.96Kb) · Show article thread
How to print out a Fortran array?     

Group: comp.lang.fortran · Group Profile · Search for How to print out a Fortran array in comp.lang.fortran
Author: Shawn
Date: Nov 17, 2006 09:41

Hi, I am trying to understand a Fortran program. I hope to print out one array to the screen. But because each item can be integer, ... character, how can I write statements to print them out? I don't really know ...which type. I am very new to Fortran. I only know such statements(suppose I ...real, second one is a 3 character): PRINT *, 'TS(1)= ', TS(1) WRITE ('(A3)', ...
Show full article (0.46Kb)
1 · 2 · 3 · 4 · 5 · 6 · 7 · 8 · 9 · next