|Jun21-12, 05:14 PM||#1|
Creating 2-d array from a text file in fortran
I have a text file of the format
I need to read this into an array. How is this done in Fortran?
|Jun21-12, 07:59 PM||#2|
you start by declaring a couple of array variables long enough to accommodate your values.
then, you open the file
write a do-loop
read values into array with the loop variable as the index
If I tell you more, I will be writing more than what it takes to simply write the code and give it to you.
with those hints, go ahead and take a shot at it, don't be shy, write some code and see what happens....you are not going to break anything nor set the room on fire or anything...that's what so wonderful about software!
|array, fortran, matrix|
|Similar Threads for: Creating 2-d array from a text file in fortran|
|Transfering data from a text file into a 2D vector array in c++||Engineering, Comp Sci, & Technology Homework||2|
|Read array from a file in Fortran||Programming & Comp Sci||4|
|Fortran 90 creating an array of unknown size||Programming & Comp Sci||3|
|Getting fortran to read a text file and write the whole file to a different location||Programming & Comp Sci||4|
|Fortran: creating array containing characters||Programming & Comp Sci||1|