Menu

VPSIM / Blog: Recent posts

Virtual Particles Framework

You can visit the internet page for the Virtual Particles Framework, that is a page I began to develop a few years ago, with some of the background ideas of the current VPSIM. The idea is to dedicate that page for showing different possible configurations for the initial states of the particles, observing how the system evolves. For more info:
http://virtualparticles.co.nf/topics/top_2/top_2.htm

Posted by MIGUEL TOLEDO GONZÁLEZ 2018-09-26

JUST STARTING

Virtual Particles Simulator v1.0 - code serie k5 - was compiled under Windows 10 with Visual Studio 2017. I programmed it in standard C++ using for graphical output the Allegro 5.2.4 library. That multimedia library is (with difference!) the one I prefer for the kind of things I like to do. It is not very big, it is not very complicated to learn, and it's not very difficult to use. And, very important, let the C++ language be. Also, doesn't take, or overtake the natural functions of the C++ language, letting a good equilibrium on the code, between standard C++, and specific library-functions, for VPS, just the graphical output, and the events-management, like timer, keyboard and video-output. The philosophy behind VPS is to try to implement a computer application letting to visualize and precise calculate trajectories of systems of interacting particles at real-time, at any scale, using classical dynamics, in this case, the universal gravitation's law of Newton, and the Coulomb's electrical force law, applying the second law of Newton to calculate the acceleration - that is, the change on the velocity of the particles. This first version of the project, has many limitations, specially, when increasing the number of particles >100, the computer has many problems to manage the memory, taking in account, that VPSIM uses a dynamical matrix for the particles, and another dynamical matrix for their interactions-processor between any of them against each other.
To understand that, take an example. With 3-particles the particles-matrix size is just 3. The processors-matrix contains their mutual interactions, also M={a,b,c}, and PM={ab,ac,bc} accounting their mutual-interactions. In general, for n-particles the size of M is n, and the size of PM is equal to the number of combinations of n-particles taken as pairs, just C(n,2). For 3-particles, C(3,2)=3 processors, but for example, for 100-particles, the size of the processors matrix would be C(100,2)=4950. Note that C(n,k)=binom(n,k) the binomial-coefficient. It's evident that "normal" computers can have important difficulties to simulate systems involving more that 100 particles. A way to solve that problem, can be to use not directly the particles objects, or the processors objects, but their memory-addresses, their pointers. That is where C++ can be brilliant to do the job.

Posted by MIGUEL TOLEDO GONZÁLEZ 2018-09-19 Labels: start