Hello Everyone!

So, I have a question about how does covering grid actually works. I have a Flash simulation output of a 28*28 Mpc box containing a cluster. I am trying to simulate the spectra from a region of size (0.08 Mpc x, 0.08 Mpc y, 28 Mpc z) around the centre, (I will assume z is my line of sight) so I use this line to define the region:

#The shape of my region
cube = pf.h.covering_grid(level_max, left_edge=newlep, right_edge=newrep,dims=[6, 6, 128])

where level = 5 (max level of refinement for my Flash data), "newlep" is centre coordinates (Mpc)  minus 0.08 Mpc and newrep is centre coordinates plus 0.08 Mpc, and then into percentage units.

I put them into an array of dimensions [6,6,128] because I want 36 spectra (one for each pixel of the ccd) so I will fix an (x,y) position and write an XSPEC file for all z elements. (I need basically temperature and density of all the elements).

My question is: how does covering grid makes a single field value (temperature, for example)  inside the (x,y,z) position? because I am arbitrarily saying to divide the region into 6 pixel, but the data file might have  many simulation pixels inside , so how are the field values calculated? is it just an average? or are just certain points taken into consideration?

Thanks for any hints/tips/help!
Barbara Ramirez
University of Innsbruck, Austria