Generating Mock Catalogs with Lightcones ======================================== Suppose that you want to create a catalog of galaxies as would be found in a survey of an area of the sky out to some redshift. Such a "mock catalog" can be built by populating with galaxies all of the dark matter halos which happen to lie within the cone which that area makes as it is projected from the observer through the Universe. Generating such a mock catalog using Galacticus involves first extracting the halos (and their merger trees) within this "lightcone" from a suitable N-body simulation, and then processing them through Galacticus. In this tutorial, we will assume that you have merger trees from a cosmological simulation available in Galacticus' merger tree file format. Each such merger tree file can then be run through Galacticus in the usual way (see the tutorial on "`Using N-body Merger Trees `_"). Outputs should be requested at every snapshot (up to the largest redshift to be considered), and the ``lightcone`` filter should be used to cause only those galaxies which intersect the lightcone to be output—for example: .. code-block:: xml In the above, ``outputLightconeData=true`` causes lightcone coordinate information (i.e. the position and velocity of each galaxy in a coordinate system with axes aligned along the line of sight of the lightcone and parallel to the two edges of the square field of view, along with the redshift) to be output (see the documentation on the ``lightcone`` `nodePropertyExtractor `_), and is set to ``pruneLightcone`` to cause any merger trees which have no nodes within the lightcone volume to be pruned away (as there is no need to process them). Finally, the ``geometryLightcone`` parameter describes the geometry of the lightcone to be used—see `the documentation `_ for details.