Opresion:

A few remarks are in order.

First, to test the maximum value of x for a three-dimensioned array in QuickBASIC (QB), I wrote a simple program, which consists of the first five lines of the code below.

When the program is run, I find that the value of i where the array fails is 20, making ARRAY(19,19,19) the maximum array for the stated conditions.

Next, since you are looking for large, three-dimension arrays in QB, and that is not possible, to my knowledge, beyond the above dimension 19, I propose the use of multiple such arrays.Â And, to illustrate this, I came up with the following QB program.Â Comments?:

A few remarks are in order.

First, to test the maximum value of x for a three-dimensioned array in QuickBASIC (QB), I wrote a simple program, which consists of the first five lines of the code below.

When the program is run, I find that the value of i where the array fails is 20, making ARRAY(19,19,19) the maximum array for the stated conditions.

Next, since you are looking for large, three-dimension arrays in QB, and that is not possible, to my knowledge, beyond the above dimension 19, I propose the use of multiple such arrays.Â And, to illustrate this, I came up with the following QB program.Â Comments?:

Code:

`GOTO START:`

'Array.bas creates two, 3-dimensional arrays of dimension (19,19,19), which

'is the maximum size of 3-dimension array I could create in my QB4.5, using

'the following code, before it produces a "Subscript out of range" message:

FOR i = 1 TO 100

Â REDIM array(i, i, i)

Â PRINT i

NEXT i

STOP

START:

'ARRAY.BAS, by Ralph A. Esquivel, 01/09/08, shows how to use two arrays and,

'by extrapolating the program, a large number of such arrays.

CLS

x = 19 'array size to use is (x,x,x), which allows:

'1*6,859 =Â 6,859 elements for one array

'2*6,859 = 13,718 elemens for two arrays

'etc.

DIM array1(x, x, x) AS DOUBLE

Â FOR i = 1 TO x

Â Â FOR j = 1 TO x

Â Â Â FOR k = 1 TO x

Â Â Â Â a = a + 1

Â Â Â Â array1(i, j, k) = a

Â Â Â Â PRINT array1(i, j, k);

Â Â Â NEXT k

Â Â NEXT j

Â NEXT i

STOP

DIM array2(x, x, x) AS DOUBLE

Â FOR i = 1 TO x

Â Â FOR j = 1 TO x

Â Â Â FOR k = 1 TO x

Â Â Â Â a = a + 1

Â Â Â Â array2(i, j, k) = a

Â Â Â Â PRINT array2(i, j, k);

Â Â Â NEXT k

Â Â NEXT j

Â NEXT i

STOP

Ralph, using QuickBASIC 4.5 and Windows XP Home Edition and Service Pack 2, with HP LaserJet 4L printer.