For a start, you need to make the debug arrays shared instead of firstprivate. Otherwise, each thread gets a private copy, assigns to it and then it goes out of scope at the end of the parallel loop: the subsequent writes are of the original, uninitialised arrays.
Most likely you don't want to make everything firstprivate. Variables which are read-only inside the parallel loop, or arrays where different loop iterations assign to different parts of the array should be shared. Temporary variables which are assigned and then used in every iteration should be private.
You have lot of variables to deal with in your loop, and the consequences of getting the data-attribute scoping wrong are unpleasant (race conditions and hence non-deterministic behaviour). It may help to declare as many variables as possible inside the scope of the parallel loop: these will then be automatically private to each thread. Then you only have to deal with a (hopefully) much shorter list of variables which are in scope at the parallel for directive.