• Post Reply Bookmark Topic Watch Topic
  • New Topic

Structured binary to ascii  RSS feed

 
Ashok
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello all,

I am a newbie to Java.
I have a binary file in the following structure. The file was written by a fortran77 program. Now I want to read this binary file through java and convert to ascii format.
Any kind of advice is welcome.
Thanks in advance !!
Ashok

character*132 toplbl !ascii header

integer*4 ivary

integer*4 nbyte

integer*4 inddat

real*4 xang,yang,zang

integer*4 intx,inty,intz

real*4 extent

real*4 xstart,xend

real*4 ystart,yend

real*4 zstart,zend

write(FILENAME)toplbl
write(FILENAME)ivary, nbyte, intdat, extent, extent, extent,
xang, yang, zang, xstart, xend, ystart, yend, zstart,
zend, intx, inty, intz
do k = 1,igrid
do j = 1,igrid
write(14)(phimap(i,j,k),i=1,igrid)
end do
end do
 
Joe Ess
Bartender
Posts: 9406
12
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
javaSqueez, we are a friendly bunch here, so we ask that you use your real name. As our Naming Policy states, accounts with obviously fictitious names will be closed.
You can change your displayed name here.
Thanks
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!