# five or higher dimensional waves

Is it possible to create a wave with five or higher dimensions?

I have physical properties, e.g., light intensities, measured at different conditions, such as temperature, geometric angle, solute concentration, etc.

I want to store, display and analyze the intensities flexibly. I thought a multiple dimension wave would be a suitable container for the data.

I guess, since all commands I know of working with waves support up to four dimensions, the answer is no. So you would need to work around this and use the 4 most important parameters in one wave. But then, I am also not sure it makes things easier when working with so many dimensions in one wave. You could emulate this by having the fifth (and higher dimensions) as a series of waves in a folder (and even subfolders). Then this folder would represent your 'complete' dataset.

No, Igor supports only 4 dimensions in waves. Even then, many operations don't work at all, or don't work in a terribly useful way, if your wave is > 1 dimension.

I have not encountered practical applications that required true 5D data sets.  With increasing dimensionality the size of the waves increases and frequently becomes difficult to manage.  This requires some planning and depends on your application.  There are two general workarounds that come to mind:

If you are working with dimensions of sizes dim[0],dim[1]... choose the smallest dimension (say dim[3]) and split your data into dim[3] 4D waves.  This will solve the representation of your data but you still end up with 4D waves that are not very useful for plotting or analysis.

The second approach, which could be useful if your data set is sampled on 4D 'rectangular' grid, is to save the data as a 1D wave and write a short function that returns the appropriate index:

Function get5DDataPoint(theRow,theCol,theLayer,theChunk,theSuperChunk,inWave,rows,cols,layers,chunks,superChunks)
Variable theRow,theCol,theLayer,theChunk,theSuperChunk,rows,cols,layers,chunks,superChunks
Wave inWave

Variable layerSize=rows*cols
Variable chunkSize=layerSize*layers
Variable offset=theRow+theCol*rows+theLayer*layerSize+theChunk*chunkSize+theSuperChunk*(chunkSize*chunks)
return inWave[offset]
End

I hope this helps,

A.G.

Thank you for the comments and suggestions. I understood that Igor could handle up to 4 dimensions, and it is not good to analyze such high dimension waves.

Getting a 1D wave from the multi-dimension wave is what I attempted. However, as there is a limitation in the wave's dimension, I think maybe I should store the multi-dimension data in an XML file and then get the 1D wave from there.

maru wrote:

Getting a 1D wave from the multi-dimension wave is what I attempted. However, as there is a limitation in the wave's dimension, I think maybe I should store the multi-dimension data in an XML file and then get the 1D wave from there.

Keep in mind that if you are storing data in a text based format, the cost to parse that text and convert it into numerical values may be significant, particularly if you need to do this to the same data over and over.