The Arrays have to be dynamic because they can hold anything from a small grid of 5 by 5 upto the limit that would feasibly run with each element representing an automaton state within a spatial array.
Each cell having a function, which is defined by the user and then parsed and compiled at...
Im not sure if i posted the code that i have been using however I did try the code that was posted and found that it worked for a single dimensional array. However changing the code to two dimensions gives the results that i have already experienced. As the array represents a grid of cellular...
Ive run the code with a one dimensional array and it works howevery as the array represents a grid of cellular automaton it needs to be two dimensional. So I tried changing your code and the two arrays seem to point to the same memory location as updating one effects the other
here is the...
this is the code for the procedure i had to amend it
to copy the elements of the array individually however
as there could be thousands of elements this is quite
a combersome way of doing the job.
procedure TSimulationEngine.SimpleIteration;
var
TempFrom:TCellSpaceArray...
Im currently using delphi 5 and need a true copy of a dynamic array, Ive tried both versions of copy but this results in the copy pointing to the original. I need to store a tempary copy that does not get updated when manipulating the original.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.