src/OpenFOAM logo
The Open Source CFD Toolbox
  Search
  
  Back to OpenFOAM Home
 
  OpenCFD®
  Company profile
  OpenFOAM support
  OpenFOAM development
  OpenFOAM training
  Solutions
  Contact OpenCFD
  Recruitment
  Recommended links
 
  OpenFOAM®
  Features
  Download
  Documentation
  * User Guide
  * C++ Source Guide
  * README file
  * Release notes
  * Upgrading to 1.5
 
  Our trade mark policy
 
  © 2000-2008 OpenCFD Ltd
SourceForge.net Logo
OpenCFD® Solutions Contact OpenFOAM®
OpenFOAM 1.5 User Guide © 2000-2008 OpenCFD Ltd

A.3 The case browser

From the JAVA GUI, a case browser may be opened for a machine listed in the case panel by: either double-clicking on the host icon; or, highlighting the host with a single-click and selecting Open Case Browser (  \special {t4ht=) from a the menu buttons or right mouse button. This operation makes a call to the FoamXHostBrowser to open a FoamXCaseBrowser as shown in A.3 b). The FoamXCaseBrowser reads the ns.ref file to get a reference to the name server and registers itself. The JAVA GUI can then look up the FoamXCaseBrowser and make calls to it, e.g. to start up a FoamXCaseServer to start working on a case. The FoamXCaseServer registers itself on the name server, and so the process continues of registering services and making calls to them.

Note that a case browser may be opened automatically at launch of the JAVA GUI by executing runFoamX with the host as an argument


    runFoamX [host]

Starting the case browser on a host machine produces a directory tree list of root path directories in which OpenFOAM cases are stored as shown in A.5. The case roots specified in the user’s .OpenFOAM-1.5/controlDict file; for information on adding or removing case roots, please refer to A.5.2.



\special {t4ht=


Figure A.5: Case root directory tree.


For the remainder of the manual:
It will be assumed that any operation in FoamX, described in the text, is selected either from the menu bar or button, or by a right button click on the mouse unless otherwise stated.



\special {t4ht=
(a) Case directory selection.

\special {t4ht=
(b) Case name selection.

Figure A.6: Case browser functions.


The case browser offers a range of functions as shown in A.6. By selecting a root directory icon, the user may open the directory, create a new case, import a case or run some utilities; by highlighting a case name icon, the user may open, delete, clone or unlock that case or run OpenFOAM utilities on the case.

A.3.1 Opening a root directory

The current set of cases within a case root directory can be viewed by selecting the the Open Root function by placing the cursor over the root directory and clicking the right mouse button to reveal the menu as shown in A.6 a), or by a double-click on the root directory icon. The directory opens to reveal a case tree for that root directory as shown in A.7.


\special {t4ht=


Figure A.7: Opening a case root.


A.3.2 Creating a new case

A new case is created by selecting the Create Case function (  \special {t4ht=) either from the menu buttons or by placing the cursor over the host icon or a case directory and clicking the right mouse button as shown in A.8. A small window appears with data entry boxes for the Class, Case Name and Case Root as shown in A.8.


\special {t4ht=


Figure A.8: Creating a new case.


The Class provides a scroll menu containing OpenFOAM solver names, such as icoFoam and turbFoam. FoamX generates the necessary data entries in the case files required by the selected solver; hence, it is essential to choose the correct solver. Case Name and Case Root are the directory path and directory name respectively, in which the case data is stored according to the file structure described in 4.1. Once the correct entries have been made, click OK. A case server for the new case is opened allowing the user to edit case files, run solvers and utilities, etc. as described in A.4.

A.3.3 Opening an existing case

The Open Case function (  \special {t4ht=) opens an existing case in a case server as shown in A.9. The case server allows the user to edit case files, run solvers and utilities, etc. as described in A.4.

                                Open  menu  with right mouse  button
Select case by clicking on it               or menu  bar button
\special {t4ht=


Figure A.9: Opening an existing case.


A.3.4 Deleting an existing case

The user may highlight a case and select the Delete Case function (  \special {t4ht=) to delete the case directory from the hard disk. As shown in A.10, the function prompts the user with a window asking whether he/she wishes to delete the case which the user may accept by clicking the Yes button or decline with the No button.


\special {t4ht=


Figure A.10: Deleting an existing case.


A.3.5 Cloning an existing case

The Clone Case function (  \special {t4ht=) creates a new case into which existing files from a selected case are copied. As shown in A.11, the user must first highlight the case that is to be cloned and select the Clone Case function. This opens a table in which the new case name must be specified and the root path and the applicationClass may be changed to something different to those of the case being cloned. Finally the times entry allows the user to choose the time directories that are copied during the clone operation. The options are listed in A.1.


Option Description


firstTime Copies the earliest time directory
latestTime Copies the most recent time directory
allTime Copies all time directories
noTime Copies no time directories



Table A.1: Options for copying time directories in a Clone Case operation.

On entering the correct information and clicking the Close button, the user is prompted to complete the clone operation. The new case can then be opened as described in A.3.3.



\special {t4ht=


Figure A.11: Cloning an existing case.


A.3.6 Unlocking an existing case

When a case is created or opened, a lock file is created to prevent the case being opened in a separate server. When the case is closed, the lock file is removed to allow it to be opened once more. In a few circumstances the lock file may not be deleted even though the case is no longer being processed in a case server, e.g. if the host browser is killed while the case is open in the case server. The Unlock Case function (  \special {t4ht=) therefore provides the option of deleting the lock file. As shown in A.12, it presents a window warning the user that the case may be being processed by another user. It is then the user’s responsibility to ensure that it is not being processed elsewhere before accepting to delete the lock file.


\special {t4ht=


Figure A.12: Unlocking an existing case.


A.3.7 The process editor

The Start Process Editor function (  \special {t4ht=) opens an editor in which the user can monitor all the OpenFOAM jobs that are finished and currently running. The editor is simply a GUI that reads the files in the runningJobs and finishedJobs directories, located in the $FOAM_LIC_DIR directory of the installation.


\special {t4ht=
(a) Running jobs table.

\special {t4ht=
(b) Finished jobs table.

Figure A.13: The process editor.


It consists of a window as shown in A.13. Tags allow the user to move between a runningJobs table and a finishedJobs table. The tables contain the details of jobs which are fairly self-explanatory. There are buttons above and to the left of the runningJobs table that perform the tasks listed in A.2. The user may select a job by clicking on it in the runningJobs table, which activates the buttons above right of the table. These buttons allow the user to control jobs as listed in A.2.


Main buttons


read Re-reads the jobs in the runningJobs and finishedJobs directories
status Contacts host machines to update the status of jobs
purge Removes jobs that are no longer running
Running jobs buttons


Info Displays an information panel about the job
endNow Forces the job to stop at the end of the next time step
end Forces the job to stop next time step the job outputs field data to file
kill Terminates the job immediately
suspend Suspends the job immediately
cont Restarts a suspended job
Check boxes


My Jobs Only shows the jobs of the current user
Compact Removes the jobs relating to FoamX from the list



Table A.2: Process editor buttons.

The finishedJobs table is an archive of information of jobs that were running in OpenFOAM but were terminated for one reason or another. The user is free to store the entries they find useful and delete those that are not. There are 2 buttons for deleting entries in the table: the purge button deletes finished jobs that are older than 7 days; the remove button simply removes a selected entry from the table.

There are two check boxes at the bottom of the process editor window that govern which jobs are listed in the runningJobs and finishedJobs tables as listed in A.2.

A.3.8 Running OpenFOAM utilities

The Foam Utilities function allows the user to run OpenFOAM utilities. This function is also offered in the case server and is more commonly used there; it is therefore described in A.4.