CFDnet:Teaching Fluid Dynamics over the Internet

J. Militzer
F. E. Ham,

Department of Mechanical Engineering
Dalhousie University – DalTech

Abstract

Unlike conventional CFD software, students access CFDnet over the Internet and dynamically control the server’s meshing and solving routines from a Java Applet-based user interface running in their web browser. By using the platform-independent Java language to provide the user interface, student access to CFDnet is made independent of the type of client computer used. Additionally, by performing the computationally intensive meshing, solving, and visualization processes on a server-side network of powerful computers, this flow modelling tool is made available to users with relatively low speed, inexpensive computers. Classroom experience shows its usefulness in teaching sometimes very difficult Fluid Dynamics concepts, greatly reducing the need for expensive and cumbersome laboratory experiments and demonstrations. An earlier version of CFDnet was integrated into the Fluid Dynamics courses at U. of Victoria and Dalhousie University, with encouraging result.

1. Introduction

CFD simulation results can be presented as a visualization of the calculated flow field, making it a powerful educational tool, which gives students an appreciation for how fluid behaves under many different conditions. Although commercial CFD software packages have been available for many years, their penetration into the undergraduate engineering teaching of Fluid Dynamics and Heat Transfer has been quite limited.

To address some of these problems we undertook to develop a unique CFD program called CFDnet. The main goals of the development program were to create software accessible to the largest possible number of users, to develop a simple, modular user interface that minimizes both the learning time and the specialized knowledge required, and to provide, at least initially; free access to academic users (students and researchers).

The Internet – specifically the world wide web – was selected as the development environment. With the advent of Java, engineering applications can now be embedded in web pages as Java Applets. The Java programming language offers the additional attraction of platform independence, requiring the development of a single code for many different types of computers. Low Internet bandwidth, however, currently makes it impractical to develop large software packages such as an entire CFD software package as an embedded Java Applet. Even when Internet bandwidth and the resulting transfer speeds become significantly faster, other issues make it undesirable to download and run the software entirely on the user’s client computer. These issues include the advantage of allowing clients with less powerful computers to solve computationally intensive processes, and our desire to protect the software from piracy.

In consideration of these issues, CFDnet was developed with processing shared between three separate modules: 1) a small Java Applet-based user interface running on the client computer, 2) specialized server software to control the flow of information over the Internet between the server and client computers, and 3) relatively large, computationally intensive server-based programs to setup, solve, and generate visualizations of the resulting flows. The present version of CFDnet is limited to two-dimensional, laminar, incompressible flows, and is available on the Internet.

The Java Applet-Based User Interface

When a student accesses the CFDnet web site with a Java-enabled web browser the Java Applet-based graphical user interface (GUI) is automatically loaded along with the text and images of the web page. Once started by the student, the GUI has the look and feel of a native application, and can be used to input the geometry, select the type of problem, and specify the boundary conditions and solution parameters.

The GUI is also used to initiate and communicate with server-based processes including mesh generation, solution of the flow field, and the generation of visualizations. Once a problem is solved, the same GUI facilitates inspection of the solution.

Server-based Processes

CFD problems are traditionally slow to converge, and require a significant amount of computer memory. As such, they are normally run on very powerful computers. A network of UNIX-based workstations and PC’s at Dalhousie University has been made publicly available for testing CFDnet. In general, these computers are relatively powerful and fast, allowing for the quick and efficient solution of problems, independent of the client’s computer speed.

2. Using CFDnet – A Sample Problem

To make CFDnet a powerful educational tool for engineering students, the program described thus far is complemented by an expanding set of web-based help pages and tutorials. These pages are designed to be referenced by the students during their CFDnet session, and teach them how to use CFDnet through the setup and solution of some simple but illustrative Fluid Dynamics problems. Another tool made available for the students is a problem set up wizard. It automatically pops up when a GUI is loaded and guides the user through the necessary steps for the problem set up.

Figure 2 presents the geometry of a sample problem available as a tutorial at the web site: the laminar backward facing step flow or sudden enlargement in a channel. This is a well understood simple recirculating flow, and is useful to introduce students to the concepts of flow separation, reattachment, and recirculation, and the variation in all these with Reynolds number.

The fluid enters the calculation region with a uniform velocity distribution through the left boundary of the channel. As soon as the flow reaches the sudden enlargement it immediately separates from the boundary. At some distance down the channel, the bulk flow reattaches to the bottom boundary. Students are asked to use CFDnet to calculate the reattachment length as a function of Reynolds number (Re) for the range Re=100 to Re=800. At DalTech, students are given a 45 minutes introductory session, and then work in groups of two per computer. In a matter of minutes all the eight steps, namely: problem physics, geometry, meshing, physical properties, boundary conditions, and solution parameters, can be specified. After defining the problem the user triggers the beginning of the solution on the server computer. While performing the calculations the server computer sends back convergence data to indicate whether the calculation is converging towards a solution. If the data is such that the solution diverges the solver program suggests measures to change the parameters to increase the chance for convergence. After the solution is obtained student can then extract the data by clicking and holding the left mouse button and traversing the region of interest, for example a given cross section. The data is automatically posted in the window bellow the solution and can be copied and pasted into a spreadsheet or saved for future reference on the server computer. Students can also choose to store their solutions

Figure 3 shows one of the set up steps. The grid was obtained by using the very simple wizard window shown on top of the GUI.

Figure 4 illustrates the GUI as it might appear during the analysis of results phase. In general, students have no difficulties in obtaining the solution and comparing their results with the experimental data provided in the tutorial.

3. Conclusions

As part of the evaluation process over 100 Fluid Mechanics undergraduate students at Dalhousie University – DalTech (Halifax, Nova Scotia), and the University of Victoria (British Columbia) tested CFDnet. In general, student reaction was positive. CFDnet provided students with a sense of empowerment that allowed them to use their Fluid Mechanics knowledge to solve a flow problem and immediately visualize the solution

CFDnet has demonstrated the possibilities of integrating Java with server-based processing to significantly boost the interactive power of Internet for engineering students. After a short introductory session, undergraduate engineering students were able to solve relevant and interesting Fluid Mechanics problems. Our experience has clearly demonstrated the value of introducing CFD in the undergraduate teaching of Fluid Mechanics. Not only for the purpose of teaching the principles of CFD, but also more importantly as a tool to teach the principles of Fluid Mechanics and even as a tool to reduce the need for actual hands on laboratory experimentation, which in many cases can be simulated more effectively with CFDnet.

CFDnet is continually being improved. Currently there are approximately 500 registered users from all corners of the world. The objective is to make CFDnet into an effective teaching aid for Fluid Mechanics. With this is mind we are continually introducing new tutorials as well as improving the solver. We encourage colleagues to try it and would appreciate receiving their feedback.