## 3 CFD Applied to Compost-Bedded Pack Barn Systems
### CBPs Typology and Computational Domain  
Ventilation is the main strategy used to control the thermal environmental conditions inside CBP systems. Through its use, it is possible to control, within certain limits, the air temperature levels, relative humidity of the air, and bedding moisture, as well as to maintain adequate oxygen concentrations and remove gases, dust, odors, and pathogens [70]. Given the ventilation importance, the architectural design of CBP systems varies according to the type of ventilation system and can be didactically classified into two types: CBPs with open sides, positive pressure ventilation, with the use of natural air flows and supplementation via mechanical ventilation (Figure 2a); closed CBPs, with negative pressure mechanical ventilation, usually associated with evaporative cooling (Figure 2b). Based on the typology, the computational domain to be used in the modeling of this type of facility is defined. According to [PERSON] et al. [23], three approaches can be used to represent the model of an animal facility in a computational domain of a CFD study:  
Figure 1: Schematic representation of a Compost-Bedded Pack Barn system (emphasis on the bedding). C—carbon; H\({}_{2}\)O—water; N—nitrogen; and O\({}_{2}\)—oxygen. Source: Adapted from [PERSON] [66]. Figure 2: Representation of open Compost-Bedded Pack Barns systems with positive pressure mechanical ventilation (**a**) and closed with negative pressure mechanical ventilation and evaporative cooling (**b**). t\({}_{\rm db}\)—dry air bulb temperature. Source: The authors. (1) indoor and outdoor environments of the facility represented in a single computational domain; (2) internal and external environments divided into two computational subdomains, with independent resolution in each one and interpolation of interface results; and (3) only the facility's internal environment represented in the computational domain. Approach (1) is considered more advantageous in terms of approximation with a real situation of animal facilities with open sides or with a large opening's presence, as it performs the direct coupling of the internal and external environments. However, it demands higher computational cost since the necessary mesh must satisfactorily represent the environments of the internal (must be more refined) and external (may be less refined but is large scale) facilities. From the technological development that occurred in recent decades, the computational cost is no longer a problem in CFD since the advance in computational power has made the solution of complex flow problems more accessible [71]. This type of approach has been used for modeling facilities for dairy cattle with open sides [15, 16, 31, 47, 49, 72], including CBP facilities. In approach (1), the size of the computational domain is a function of the building dimensions, always being necessary to include a sufficient surrounding volume for the flow to be fully developed windward and leeward [22, 48]. Whenever this type of approach is used to represent the model of an animal facility in the computational domain, the computational volume of a height \(\geq\) 5 \(\times\) H (H = highest height of the facility within the computational domain), as well as the distance to the ends \(\geq\) 10 \(\times\) H (upstream and downstream of the interesting facility), as shown in Figure 3[22, 73]. Another form to define the required computational domain is via the blockage rate, obtained from the ratio between the projected frontal area (windward) of the obstacles and the cross-section of the computational domain [74]. It is recommended that the blockage rate be less than 3% to avoid artificial flow acceleration [16]. It is important to highlight those surrounding facilities and/or other types of physical obstructions to air flow, which must always be included in the computational domain, as well as considered for the calculation of minimum distances to the extremities and/or the blockage rate. If this is not carried out, the artificial acceleration of the air flow may occur.