/* voc 2.1.0 [2025/05/18] for gcc LP64 on slackware xtspaF */

#ifndef MultiArrays__h
#define MultiArrays__h

#include "SYSTEM.h"

typedef
	struct MultiArrays_ArrayDesc *MultiArrays_Array;

typedef
	struct MultiArrays_DataDesc {
		char _prvt0[1];
	} MultiArrays_DataDesc;

typedef
	struct MultiArrays_ArrayDesc { /* MultiArrays_DataDesc */
		INT64 _prvt0;
		INT32 len;
	} MultiArrays_ArrayDesc;

typedef
	struct MultiArrays_BoolDesc *MultiArrays_Bool;

typedef
	struct MultiArrays_BoolArrayDesc *MultiArrays_BoolArray;

typedef
	struct {
		ADDRESS len[1];
		BOOLEAN data[1];
	} *MultiArrays_BoolPtr;

typedef
	struct MultiArrays_BoolArrayDesc { /* MultiArrays_ArrayDesc */
		INT64 _prvt0;
		INT32 len;
		MultiArrays_BoolPtr b;
	} MultiArrays_BoolArrayDesc;

typedef
	struct MultiArrays_ScalarDesc { /* MultiArrays_DataDesc */
		char _prvt0[1];
	} MultiArrays_ScalarDesc;

typedef
	struct MultiArrays_BoolDesc { /* MultiArrays_ScalarDesc */
		BOOLEAN b;
	} MultiArrays_BoolDesc;

typedef
	struct MultiArrays_ComplexDesc *MultiArrays_Complex;

typedef
	struct MultiArrays_ComplexArrayDesc *MultiArrays_ComplexArray;

typedef
	struct {
		ADDRESS len[1];
		REAL data[1];
	} *MultiArrays_RealPtr;

typedef
	struct MultiArrays_ComplexArrayDesc { /* MultiArrays_ArrayDesc */
		INT64 _prvt0;
		INT32 len;
		MultiArrays_RealPtr r, i;
	} MultiArrays_ComplexArrayDesc;

typedef
	struct MultiArrays_ComplexDesc { /* MultiArrays_ScalarDesc */
		REAL r, i;
	} MultiArrays_ComplexDesc;

typedef
	MultiArrays_DataDesc *MultiArrays_Data;

typedef
	struct MultiArrays_IntDesc *MultiArrays_Int;

typedef
	struct MultiArrays_IntArrayDesc *MultiArrays_IntArray;

typedef
	struct {
		ADDRESS len[1];
		INT16 data[1];
	} *MultiArrays_IntPtr;

typedef
	struct MultiArrays_IntArrayDesc { /* MultiArrays_ArrayDesc */
		INT64 _prvt0;
		INT32 len;
		MultiArrays_IntPtr i;
	} MultiArrays_IntArrayDesc;

typedef
	struct MultiArrays_IntDesc { /* MultiArrays_ScalarDesc */
		INT16 i;
	} MultiArrays_IntDesc;

typedef
	struct MultiArrays_LIntDesc *MultiArrays_LInt;

typedef
	struct MultiArrays_LIntArrayDesc *MultiArrays_LIntArray;

typedef
	struct {
		ADDRESS len[1];
		INT32 data[1];
	} *MultiArrays_LIntPtr;

typedef
	struct MultiArrays_LIntArrayDesc { /* MultiArrays_ArrayDesc */
		INT64 _prvt0;
		INT32 len;
		MultiArrays_LIntPtr j;
	} MultiArrays_LIntArrayDesc;

typedef
	struct MultiArrays_LIntDesc { /* MultiArrays_ScalarDesc */
		INT32 j;
	} MultiArrays_LIntDesc;

typedef
	struct MultiArrays_LRealDesc *MultiArrays_LReal;

typedef
	struct MultiArrays_LRealArrayDesc *MultiArrays_LRealArray;

typedef
	struct {
		ADDRESS len[1];
		LONGREAL data[1];
	} *MultiArrays_LRealPtr;

typedef
	struct MultiArrays_LRealArrayDesc { /* MultiArrays_ArrayDesc */
		INT64 _prvt0;
		INT32 len;
		MultiArrays_LRealPtr y;
	} MultiArrays_LRealArrayDesc;

typedef
	struct MultiArrays_LRealDesc { /* MultiArrays_ScalarDesc */
		LONGREAL y;
	} MultiArrays_LRealDesc;

typedef
	struct MultiArrays_RealDesc *MultiArrays_Real;

typedef
	struct MultiArrays_RealArrayDesc *MultiArrays_RealArray;

typedef
	struct MultiArrays_RealArrayDesc { /* MultiArrays_ArrayDesc */
		INT64 _prvt0;
		INT32 len;
		MultiArrays_RealPtr x;
	} MultiArrays_RealArrayDesc;

typedef
	struct MultiArrays_RealDesc { /* MultiArrays_ScalarDesc */
		REAL x;
	} MultiArrays_RealDesc;

typedef
	struct MultiArrays_SIntDesc *MultiArrays_SInt;

typedef
	struct MultiArrays_SIntArrayDesc *MultiArrays_SIntArray;

typedef
	struct {
		ADDRESS len[1];
		INT8 data[1];
	} *MultiArrays_SIntPtr;

typedef
	struct MultiArrays_SIntArrayDesc { /* MultiArrays_ArrayDesc */
		INT64 _prvt0;
		INT32 len;
		MultiArrays_SIntPtr s;
	} MultiArrays_SIntArrayDesc;

typedef
	struct MultiArrays_SIntDesc { /* MultiArrays_ScalarDesc */
		INT8 s;
	} MultiArrays_SIntDesc;

typedef
	MultiArrays_ScalarDesc *MultiArrays_Scalar;

typedef
	INT32 *MultiArrays_SizeVectorDesc;

typedef
	struct {
		ADDRESS len[1];
		INT32 data[1];
	} *MultiArrays_SizeVector;



import ADDRESS *MultiArrays_DataDesc__typ;
import ADDRESS *MultiArrays_ScalarDesc__typ;
import ADDRESS *MultiArrays_SIntDesc__typ;
import ADDRESS *MultiArrays_IntDesc__typ;
import ADDRESS *MultiArrays_LIntDesc__typ;
import ADDRESS *MultiArrays_RealDesc__typ;
import ADDRESS *MultiArrays_LRealDesc__typ;
import ADDRESS *MultiArrays_BoolDesc__typ;
import ADDRESS *MultiArrays_ComplexDesc__typ;
import ADDRESS *MultiArrays_ArrayDesc__typ;
import ADDRESS *MultiArrays_SIntArrayDesc__typ;
import ADDRESS *MultiArrays_IntArrayDesc__typ;
import ADDRESS *MultiArrays_LIntArrayDesc__typ;
import ADDRESS *MultiArrays_RealArrayDesc__typ;
import ADDRESS *MultiArrays_LRealArrayDesc__typ;
import ADDRESS *MultiArrays_BoolArrayDesc__typ;
import ADDRESS *MultiArrays_ComplexArrayDesc__typ;

import void MultiArrays_AllInt1 (MultiArrays_Array A, INT16 (*f)(INT16));
import void MultiArrays_AllInt2 (MultiArrays_Array A, MultiArrays_Array B, INT16 (*f)(INT16, INT16));
import void MultiArrays_AllLInt1 (MultiArrays_Array A, INT32 (*f)(INT32));
import void MultiArrays_AllLInt2 (MultiArrays_Array A, MultiArrays_Array B, INT32 (*f)(INT32, INT32));
import void MultiArrays_AllLReal1 (MultiArrays_Array A, LONGREAL (*f)(LONGREAL));
import void MultiArrays_AllLReal2 (MultiArrays_Array A, MultiArrays_Array B, LONGREAL (*f)(LONGREAL, LONGREAL));
import void MultiArrays_AllReal1 (MultiArrays_Array A, REAL (*f)(REAL));
import void MultiArrays_AllReal2 (MultiArrays_Array A, MultiArrays_Array B, REAL (*f)(REAL, REAL));
import void MultiArrays_AllSInt1 (MultiArrays_Array A, INT8 (*f)(INT8));
import void MultiArrays_AllSInt2 (MultiArrays_Array A, MultiArrays_Array B, INT8 (*f)(INT8, INT8));
import MultiArrays_SizeVector MultiArrays_CalculatePos (INT32 Index, INT32 *dimension, ADDRESS dimension__len);
import void MultiArrays_Copy (MultiArrays_Array From, MultiArrays_Array To);
import BOOLEAN MultiArrays_GetBool (MultiArrays_Array A, MultiArrays_SizeVector position);
import MultiArrays_Complex MultiArrays_GetComplex (MultiArrays_Array A, MultiArrays_SizeVector position);
import INT16 MultiArrays_GetInt (MultiArrays_Array A, MultiArrays_SizeVector position);
import INT32 MultiArrays_GetLInt (MultiArrays_Array A, MultiArrays_SizeVector position);
import LONGREAL MultiArrays_GetLReal (MultiArrays_Array A, MultiArrays_SizeVector position);
import REAL MultiArrays_GetReal (MultiArrays_Array A, MultiArrays_SizeVector position);
import INT8 MultiArrays_GetSInt (MultiArrays_Array A, MultiArrays_SizeVector position);
import INT32 MultiArrays_Index (INT32 *pos, ADDRESS pos__len, INT32 *dimension, ADDRESS dimension__len);
import INT32 MultiArrays_Index1 (MultiArrays_Array A, INT32 x);
import INT32 MultiArrays_Index2 (MultiArrays_Array A, INT32 x, INT32 y);
import INT32 MultiArrays_Index3 (MultiArrays_Array A, INT32 x, INT32 y, INT32 z);
import INT32 MultiArrays_Index4 (MultiArrays_Array A, INT32 x, INT32 y, INT32 z, INT32 u);
import void MultiArrays_InitBool (MultiArrays_Array *A, MultiArrays_SizeVector dimension, MultiArrays_BoolPtr data, BOOLEAN copy);
import void MultiArrays_InitComplex (MultiArrays_Array *A, MultiArrays_SizeVector dimension, MultiArrays_RealPtr dataR, MultiArrays_RealPtr dataI, BOOLEAN copy);
import void MultiArrays_InitInt (MultiArrays_Array *A, MultiArrays_SizeVector dimension, MultiArrays_IntPtr data, BOOLEAN copy);
import void MultiArrays_InitLInt (MultiArrays_Array *A, MultiArrays_SizeVector dimension, MultiArrays_LIntPtr data, BOOLEAN copy);
import void MultiArrays_InitLReal (MultiArrays_Array *A, MultiArrays_SizeVector dimension, MultiArrays_LRealPtr data, BOOLEAN copy);
import void MultiArrays_InitReal (MultiArrays_Array *A, MultiArrays_SizeVector dimension, MultiArrays_RealPtr data, BOOLEAN copy);
import void MultiArrays_InitSInt (MultiArrays_Array *A, MultiArrays_SizeVector dimension, MultiArrays_SIntPtr data, BOOLEAN copy);
import INT32 MultiArrays_Len (MultiArrays_Array A, INT32 dim);
import INT32 MultiArrays_Order (MultiArrays_Array A);
import MultiArrays_SizeVector MultiArrays_Size (MultiArrays_Array A);
import void MultiArrays_SizeVector1 (MultiArrays_SizeVector *Vec, INT32 x);
import void MultiArrays_SizeVector2 (MultiArrays_SizeVector *Vec, INT32 x, INT32 y);
import void MultiArrays_SizeVector3 (MultiArrays_SizeVector *Vec, INT32 x, INT32 y, INT32 z);
import void MultiArrays_SizeVector4 (MultiArrays_SizeVector *Vec, INT32 x, INT32 y, INT32 z, INT32 u);
import void MultiArrays_Test (void);
import void *MultiArrays__init(void);


#endif // MultiArrays
