[MITgcm-support] reshape grid_cs32.face001.bin
Martin Losch
Martin.Losch at awi.de
Fri Feb 22 03:11:54 EST 2013
Hi,
in these files all fields have the dimenstion 33x33: 33*33*18 = 19602 in order to taken into account the connection between the faces. You can reshape them and then throw away line/column 33.
Martin
On Feb 22, 2013, at 4:40 AM, Krishnakumar Rajagopalan <krishna_raj_2010 at yahoo.com> wrote:
> Hi All,
>
> I am trying to read and reshape grid_cs32.face001.bin just to see the variables inside. The file is read by the solver in 64bit precision and the contents of this binary file as printed out by the solver in the output is
>
> (PID.TID 0000.0001) tile: 1 ; Read from file grid_cs32.face001.bin
> (PID.TID 0000.0001) => xC yC dxF dyF rA xG yG dxV dyU rAz dxC dyC rAw rAs dxG dyG AngleCS AngleSN
>
> Assuming the 18 variables are 32x32 ( I am not very sure about AngleCS & AngleSN) . The size of the total data that I read should be 32*32*18=18432
>
> But when I read in the following way,
> fid=fopen('grid_cs32.face001.bin','r','b'); data=fread(fid,'real*8');
>
> The size of data is 19602 ( different from 18432, so I am unable to reshape)
>
> Thanks a lot in advance
>
> Kumar
>
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-support
More information about the MITgcm-support
mailing list