Jan-31-2021, 10:39 PM

I have a binary file that contains 32 bit floats. I would like to read the file into a matrix, rotate the matrix, and then write the matrix to a file.

In the original file the values would be arranged like this:

a0, b0, a1, b1, a2, b2, a3, b3...aN, bN

where a,b can be thought of as rows and 1, 2, 3 as columns.

In the resulting file the values would be arranged like this:

a0, a1, a2, a3...aN, b0, b1, b2, b3...bN

I'm beginning to think I might need to use the array library to read and write the files, and write some C code to do the rotation. Does anyone know of other ways?

In the original file the values would be arranged like this:

a0, b0, a1, b1, a2, b2, a3, b3...aN, bN

where a,b can be thought of as rows and 1, 2, 3 as columns.

In the resulting file the values would be arranged like this:

a0, a1, a2, a3...aN, b0, b1, b2, b3...bN

I'm beginning to think I might need to use the array library to read and write the files, and write some C code to do the rotation. Does anyone know of other ways?