Sunday, 25 December 2022

Datacenter Visualization (Verified and Validated)

     This simulation is done to create an aero-thermal digital twin of a datacenter using CFD. The details of datacenter are taken from [1]. The datacenter CAD model is shown in Fig. 1.

     The simulation employs κ − ε turbulence model with damping functions, SIMPLE-R (modified), as the numerical algorithm and second-order upwind and central approximations as the spatial discretization schemes for the convective fluxes and diffusive terms. The time derivatives are approximated with an implicit first-order Euler scheme. Flow simulation solves the Navier–Stokes equations, which are formulations of mass, momentum, and energy conservation laws for fluid flows. To predict turbulent flows, the Favre-averaged Navier–Stokes equations are used.


Fig. 1, Datacenter CAD

     A Cartesian mesh with octree refinement, cut-cell method and immersed boundary methods is used. Special mesh refinements are deployed in the areas of interest i.e. inlets and outlets and sharp edges of server racks and CRAH units to accurately capture aero-thermal gradients and vortices. The resulting computational mesh has 2,698,156 cells. The computational domain and mesh are shown in Fig. 2.


Fig. 2, Computational mesh and domain


     The results from the numerical analysis were compared with [1]. The results are in excellent agreement with previously published data. The animation in Fig. 3 shows thermal distribution inside datacenter using cut-plots. Fluid velocity distribution is also shown. The cut-plots are superimposed with streamlines and velocity vectors. These post processing features help identify hot-spots and recirculation zones. Design improvements can be made to reduce thee unwanted flow features. Within Fig. 3, Flow trajectories colored by air temperature are also shown. These show path the fluid takes between various inlets and outlets in the datacenter such as the CRAH system supply and return zones and inlets and outlets of servers. Fig. 4 shows various post processing tools available for diagnosing various issues from the aero-thermal perspective. These include iso-surfaces, cut-plots, flow trajectories and surface plots etc.

Fig. 3, The post processing animations

Fig. 4, The post processing images


     A comparison of the results from present simulations with previously published literature is shown in Fig. 5. it can be seen that out results are in close agreement with previously published numerical and experimental data [1]! The locations at which the data is extracted is shown in Fig. 6. Within Fig. 5, solid lines indicate present study, dashed lines indicate published numerical results and filled circles represent published experimental results.

Fig. 5, Comparison of results

Fig. 6, Location of data extraction

     If you want to collaborate on the research projects related to turbomachinery, aerodynamics, renewable energy, please reach out. Thank you very much for reading.

References

[1] Wibron, Emelie, Anna-Lena Ljung, and T. Staffan Lundström. 2018. "Computational Fluid Dynamics Modeling and Validating Experiments of Airflow in a Data Center" Energies 11, no. 3: 644. https://doi.org/10.3390/en11030644

Friday, 30 September 2022

Aperiodic Aero-foil Kinematics

     This post is about a 2D NACA 0012 aero-foil undergoing forced aperiodic heavingHeaving motion is achieved by the plot shown in Fig. 1. Plot within Fig. 1 represents position of airfoil at various time steps.


Fig. 1, The position of aero-foil

     The animation of the vorticity contours are shown in Fig. 2. The velocity, pressure and vorticity for aperiodic heaving is shown in Fig. 3. A comparison will be made with heaving later, if ever 😀. As far as aerodynamic forces are concerned, per-cycle Cl, avg is at 0.63 as compared to 0.0 for periodic heaving. Cd, avg aperiodic heaving is at 0.162 as compared to 0.085 for periodic heaving. Of course, this is done on a coarse mesh. If ever I write a paper about this... 😀

Fig. 2, Top Row, Aperiodic, periodic heaving airfoil 

     
Fig. 3, Top Row, L-R, Vorticity, pressure. Bottom Row, Velocity 

     If you want to collaborate on the research projects related to turbomachinery, aerodynamics, renewable energy, please reach out. Thank you very much for reading. 

Monday, 18 July 2022

High Lift Common Research Model (CRM-HL) CFD Simulation (with validation from Stanford CTR and NASA) Update 01: Formation Flight

     This post is about the CFD analysis of the nominal (2A) configuration of the Boeing / NASA CRM-HL with flap and slat angles at 40 and 37 degrees. The configuration is shown in Fig. 1.




Fig. 1, CRM-HL CAD

     The dimensions are mentioned in [1] and is available here and here. The numerical simulations are validated with published literature [3, 4]. SolidWorks Flow Simulation Premium software is employed for the CFD simulations. The flight conditions are Mach 0.2 at 289.444 K and 170093.66 Pa [2].

     Fig. 2 shows the computational mesh along with the computational domain. The surface mesh is also shown with Fig. 2. It can be seen that the mesh is refined in the areas of interests and in the wake of the aircraft to properly capture the relevant flow features. The Cartesian mesh with immersed boundary method, cut-cell approach and octree refinement is used for creating the mesh. The mesh has 6.5 million cells, of which around 0.71 millions cells are at boundary of the aircraft.

     The simulations employ κ-ε turbulence model with damping functions and two-scales wall functions. SIMPLE-R (modified) as the numerical algorithm. Second order upwind and central approximations as the spatial discretization schemes for the convective fluxes and diffusive terms. The software solves the Favre-averaged Navier-Stokes equations to predict turbulent flow. The simulations are performed to predict three-dimensional steady-state flow over the aircraft


Fig. 2, Dashed lines indicate symmetry boundary conditions

     Angle of attack of 7 and 17 degrees are considered. At 7 degree angle of attack, the drag life and moment coefficients are within 6, 8 and 12% of the published data, respectively. For 17 degree angle of attack, the coefficients are within 4, 7, 33% of the published data [3, 4]. On average, the results of the present simulations are within 6% of the published data for force coefficients and within 12% in terms of pitching moment coefficient. The pitching moment coefficient will improve with refinement of the mesh, as shown by [3]; which I will do if ever I convert this into a manuscript 😂. The post processing from CFD simulations is shown in Fig. 3-4. Within Fig. 3, the iso-surfaces represent vorticity in the direction of flow, colored by pressure. The direction of flow is shown by black arrows. Streamlines colored by vorticity are also visible. It can be seen from Fig. 2 that the simulation captures important flow features such as vortex formation very accurately, in such small number of mesh cells. Fig. 4 shows wing of the velocity iso-surfaces colored by vorticity in the direction of flow, focused around the wing.


Fig. 3, Alternating 7 and 17 degree angles of attacks


Fig. 4, Top-Bottom, 17 and 7 degrees angle of attack

     The simulations are solved using 10 of 12 threads of a 4.0 GHz CPU with 32 GB of total system memory of which almost 30 GB remains in use while the simulations are in progress. To solve each angle of attack, 3 hours and 47 minutes are required.

Update 01

     Formation flight simulation is performed with 7.3 million cells (limited by RAM). Symmetry boundary condition is used to simulate only the area of interest. The mesh and computational domain is shown in Fig. 5. Within Fig. 5, dashed lines indicate symmetry boundary condition.

Fig. 5, Airliners in formation flight mesh and computational domain

     The results show that the leading aircraft has 16.52% more drag than the trailing aircraft. The results also show that the the leading aircraft has 5.4% less lift than the trailing aircraft. However, the leading aircraft produces 2.4% more lift than the airliner flying without the trailing aircraft (flying solo). The leading aircraft also produces 3% less drag than the airliner flying solo. These results are at 7 degree angle of attack. Whether these results are fruitful aero-structurally, remains to be seen. The post processing from simulations are shown in Fig, 6.

Fig. 6, Top-Bottom, 17 and 7 degrees angle of attack

     Within Fig. 7, surface plots represent pressure, velocity streamlines indicate vortices, iso-surfaces show vorticity magnitude in the direction of flight.

     Thank you for reading, If you would like to collaborate on projects, please reach out.

References

[1] Doug Lacy and Adam M. Clark, "Definition of Initial Landing and Takeoff Reference Configurations for the High Lift Common Research Model (CRM-HL)", AIAA Aviation Forum, AIAA 2020-2771, 2020 10.2514/6.2020-2771

[2] 4th AIAA CFD High Lift Prediction Workshop Official Test Cases, https://hiliftpw.larc.nasa.gov/Workshop4/OfficialTestCases-HiLiftPW-4-2021_v15.pdf

[3] K. Goc, S., T. Bose and P. Moin, "Large-eddy simulation of the NASA high-lift common research model", Center for Turbulence Research, Stanford University, Annual Research Briefs 2021

[4] 4TH High Lift Workshop Results, ADS, https://new.aerodynamic-solutions.com/news/18

Sunday, 24 April 2022

1D Laplace's equation using Finite Difference Method

This post is about FDM for Laplace Equation with various boundary conditions.

MATLAB Code (1D, Dirichlet Boundary Conditions)

%% initialize the workspace, clear the command window


clear; clc


%% finite difference 1D laplace dirichlet boundary conditions %% d2u/dx2 = 0 %% u(o) = 10, u(L) = 4 %% Ax=b%%


N = 4 ; %number of grid points

L = 1; %length of domain

dx = L/(N-1); %element size


%% initialize variables %%


l = linspace(0,L,N); %independent

u=zeros(1,N); %dependent


%% boundary conditions %%


u(1)=10;

u(end)=4;


%% b vector %%


b=zeros(N-2,1);

b(1) = b(1) - u(1);

b(end) = b(end) - u(end);


%% A matrix


A = -2*eye(N-2,N-2);

for i=1:N-2

    if i<N-2

        A(i,i+1)=1;

    end

    if i>1

        A(i,i-1)=1;

    end

end


%% solve for unknowns %%


x = A\b;


%% fill the u vector with unknowns %%


u(2:end-1) = x;


%% plot the results %%


hold on; grid on; box on, grid minor

set(gca,'FontSize',40)

set(gca, 'FontName', 'Times New Roman')

ylabel('u','FontSize',44)

xlabel('l','FontSize',44)


plot(l,u,'-o','color',[0 0 0],'LineWidth',2,'MarkerSize',20)


MATLAB Code (1D, Mixed Boundary Conditions)

%% initialize the workspace, clear the command window

clear; clc

%% finite difference 1D laplace mixed boundary conditions %% d2u/dx2 = 0 %% u(o) = 10, du/dx(L) = 4 %% Ax=b%%

N = 5; %number of grid points
L = 1; %length of domain
dx = L/(N-1); %element size
a = 4;
%% initialize variables %%

l = linspace(0,L,N); %independent
u=zeros(1,N); %dependent

%% dirichlet boundary condition %%

u(1) = 10;

%% b vector %%

b=zeros(N-1,1);
b(1) = b(1) - u(1);
b(end) = b(end) + dx*a; %neumann boundary condition added to b vector

%% A matrix

A = -2*eye(N-1,N-1);
for i=1:N-1
    if i<N-1
        A(i,i+1)=1;
    end
    if i>1
        A(i,i-1)=1;
    end
end
A(N-1,N-1) = -1; %neumann boundary condition added to A matrix
%% solve for unknowns %%

x = A\b;

% fill the u vector with unknowns %%

u(2:end) = x;

%% plot the results %%

hold on; grid on; box on, grid minor
set(gca,'FontSize',40)
set(gca, 'FontName', 'Times New Roman')
ylabel('u','FontSize',44)
xlabel('l','FontSize',44)

plot(l,u','-o','color',[0 0 0],'LineWidth',2,'MarkerSize',20)