# A Virtual Prototype for Fast Design and Visualization of Gerotor Pumps
## 3 Methodology
### Software Tool  
The Digital Twin (DT) tool implements two functionalities: a _2D geometry configurator_ and a _3D data tool_. The 2D geometry configurator allows for the design engineer to define a new geometry for the profiles of the inner and outer gears according to a set of parametric variables. The 3D data tool converts the model that is defined in the 2D geometry configurator to a full B-Rep model for simulation and visualization purposes of both (i) data simulated from our pre-CFD simulation model and (ii) data imported from CFD simulations or test bench. Figure 10 shows the visualization of the parameterized pump in the interface of the 2D geometry configurator tool. The tool allows for the design engineer to input the desired set of values for the parametric variables of Equation (2). Our application automatically generates both the conjugated design (Figure 10a) and the classic design (Figure 10b). Both types of design, as well as other geometric configurations, are easily explorable in the 2D visualization canvas. Figure 9: Couette flow between adjacent control volumes. In addition to the discretized geometric model of the inner and outer gears, the geometry configurator calculates the shape of the resulting chambers for any given angle of the rotation of the pump. The configurator allows the user to interactively rotate the pump position with a slider, as well as to visualize and record the change in the area of each one of the chambers. The ports and chambers geometries must be well-aligned for the correct calculation of the intersection area between the chambers and the ports. The geometry of the input/output ports (shown in Figure 11) of the pump is calculated from the geometry of the inner and outer gear geometries in order to ensure the alignment. The geometries calculated by this application (gear, chamber, and port geometry) are automatically imported into the 3D data tool for simulation purposes. The CAD models are also exported to external files. Figure 11: Gerotor design with input/output ports. Figure 10: Visualization of parameterized pump in the two-dimensional (2D) geometry configurator interface: (**a**) pump with conjugated external profile and (**b**) pump with classic external profile. Figure 12 shows the interface that is devised for the toolkit that was introduced in [19; 20] to enable the virtual prototype. The interface is built with Qtt(tm) library and it comprises several panels: (i) the _3D visualization panel_, which allows for the visualization of the pump geometry (gears, ports, and chambers) and the animation showing the rotation of the pump through a pumping cycle, (ii) a _hierarchy panel_ that shows the hierarchy tree of the geometric model and allows the user to select and highlight geometric entities, (iii) a _settings panel_ in which the user inputs the fluid properties, operating conditions, and initial pressure conditions that are necessary to perform the fast pre-CFD simulation (see Figure 2), (iv) a _simulated data panel_ that displays the results from the fast simulation model, and (v) a _measured data panel_ that displays the results of the variables that are imported to the virtual prototype tool, whether measured in the test bench or simulated by the CFD software. The 3D visualization panel enables design engineers to examine the three-dimensional behavior of the pumps for the parameters that are defined in the Geometry Configuration interface. Notice that the shape of the chambers must be recalculated each time the pump is set to a new angle position. Figure 13 shows the high degree of flexibility that can be achieved in the visualization of the different components of the pump geometry. In Figure 13b, the color of each chamber is related to the pressure that is calculated by the simulation model. The tool also allows for the design engineer to import data from the CFD simulations and test bench tests with the objective of integrating and comparing performance data (both predicted and measured) in the same software environment.