I have a doubt about how to allocate arrays in a structure.
real, dimension(3) :: coord
type(node_type), allocatable, dimension(:) :: node
And then in the main I have
type(RBC_type), DEVICE, allocatable, dimension(:) :: RBC
Then, when I have to allocate the structure, I do the following:
and it seems to work.
But when I try to allocate the node:
do i = 1, N
I can compile, but when running I get this error: Segmentation fault (core dumped).
I am allocating everything on the host side. Could you help me with this?