#ifndef AHF_HALOS_H
#define AHF_HALOS_H

/* This file only does something, if AHF or the Tracker is build. */
#if (defined AHF || defined TRACKER)


#  include <stddef.h>
#  include <stdlib.h>
#  include <stdio.h>
#  include <math.h>
#  include <string.h>
#  include "../tdef.h"

/* Those are the necessary conversion factors */
extern double r_fac, x_fac, v_fac, m_fac, rho_fac, phi_fac, Hubble;

int
HaloProfiles(HALO *);

void
rem_nothing(HALO *);

void
rem_unbound(HALO *);

void
rem_outsideRvir(HALO *, int);

void
merge_ll_and_ipart(HALO *);

void
sort_halo_particles(HALO *);


#  if (defined AHFrestart || defined WITH_MPI)
void
rem_boundary_haloes(void);

#  endif

#  ifdef AHFphspdens
/** Does the phase-space stuff */
int
HaloProfilesPhaseSpace(HALO *);

#  endif

#endif /* (defined AHF || defined TRACKER) */

#endif /* AHF_HALOS_H */
