Hello. I have c++ application where I am performing n-body gravitational motion simulations. I would like to generate x,y,z cartesian coordinates at discrete time values that can imported into Paraview for 3d viewing and animation of the particle trajectories together as a system of particles. I generate ascii data trajectory files currently with 1 file per particle. In a given txt file, each row of numeric values represents the x,y,z coordinates at a discrete periodic time value for that particle.
The following is an example result of two masses moving apart from the origin, where each row is the x,y,z coordinates at a different time value. Currently, I am not writing the time values to the trajectory files, but I could if that would benefit a workflow of importing and interpreting the data as temporal trajectories.
Mass1.txt:
0,0,0
1,1,1
2,2,2
Mass2.txt
0,0,0
-1,-1,-1
-2,-2,-2
I’ve spent a few hours google searching for answers and playing around with the Paraview interface and haven’t been able to determine a solution. If you know how to help me and can offer advice, I would appreciate your assistance.
My end goal as imagined would be to write my trajectory data to a file format readily consumed by a Paraview import process, and be able to interact with (rotate, zoom and pan around with the mouse) a rendering perspective of the particle positions statically at any time in their trajectory, as well as generate renderings of their motion across time as I interact with the pose/perspecive in the 3d environment.
Thank you