Hi,
I am quite new to FORTRAN and am currently making programs to gain an understanding of it. I am using FORTRAN 90 and Microsoft Visual Studio.
I have made a program in FORTRAN 90, this spawns particles in which then land on a plane. What I would like to do is to check to see if any of the particles are within any cylinders in a line. If they are then I would like to keep them, if not then I would like them to be deleted.
I have thought about how this could be achieved. I have the centre points of the cylinder and the radius (ie. xyz for centre of the top and xyz for centre of the bottom, and a radius value). I thought that the centre of the particle with the radius could be compared with each co-ordinate of the centre point through the cylinder, and then to see if it is within the radius of that point, thus within the cylinder.
Please could you point me in the direction of a tutorial which teaches how to code this, or give me some guidance of how I can achieve this?
Thank you for your time, I really appreciate it.
I am quite new to FORTRAN and am currently making programs to gain an understanding of it. I am using FORTRAN 90 and Microsoft Visual Studio.
I have made a program in FORTRAN 90, this spawns particles in which then land on a plane. What I would like to do is to check to see if any of the particles are within any cylinders in a line. If they are then I would like to keep them, if not then I would like them to be deleted.
I have thought about how this could be achieved. I have the centre points of the cylinder and the radius (ie. xyz for centre of the top and xyz for centre of the bottom, and a radius value). I thought that the centre of the particle with the radius could be compared with each co-ordinate of the centre point through the cylinder, and then to see if it is within the radius of that point, thus within the cylinder.
Please could you point me in the direction of a tutorial which teaches how to code this, or give me some guidance of how I can achieve this?
Thank you for your time, I really appreciate it.