gpusph icon indicating copy to clipboard operation
gpusph copied to clipboard

Particle Temperature

Open hxtsg opened this issue 8 years ago • 1 comments

Hi Good morning! I'm now using GPUSPH to simulate fluids. I find it an excellent tool to use, but I have some problem modifying it. I want to add some temperature properties to the particles, but I find the code highly relevant and I need to edit a lot of places to make it modification work. So I'm wondering is there an interface we could use to add some other properties to each particle? Thanks a lot. I'm so interested for the reply

hxtsg avatar May 09 '17 02:05 hxtsg

@hxtsg, sorry for the late reply. I'm afraid there is no easy interface to add new particle properties in the code: it requires changes in a number of places.

You will need to change define_buffers.h to define the actual buffer handles for the properties, and then GPUSPH.cc and GPUWorker.cc to add the relevant buffers to the list of host and device arrays, add them to the list of buffers that get dumped on save and then of course retrieve them in the writer to actually save the data to disk. And of course any kernels that need to access the data, and possibly the places where buffers are swapped during the two-step integration.

Oblomov avatar May 17 '17 20:05 Oblomov