MPI struct datatype with an array
问题 I would like to easily send an someObject in one MPI_SEND/RECV call in mpi. type someObject integer :: foo real :: bar,baz double precision :: a,b,c double precision, dimension(someParam) :: x, y end type someObject I started using a MPI_TYPE_STRUCT, but then realized the sizes of the arrays x and y are dependent upon someParam. I initially thought of nesting a MPI_TYPE_CONTIGUOUS in the struct to represent the arrays, but cannot seem to get this to work. If this is even possible? ! Setup