MIT Java Pflow
User Guide for version 1.0 (rev 2.2)
Table of Contents
1. Introduction
1.1 Requirements
2. User Interface
2.1 Principles
2.2 Overview
3. Functionality
3.1 Singularities
3.1.1 Free Stream
3.1.2 2D Source
3.1.3 2D Vortex
3.1.4 2D Dipole
3.1.5 Corner Flow
3.2 Visualization
Options
3.2.1 Point
Evaluation
3.2.2 Vector
Field
3.2.3 Grid
and Grid Scale
3.2.4 Plot
Stream Lines
3.2.5 Pressure
Coefficient
3.3 Other Options
3.3.1 Zoom
3.3.2 Reset
3.3.3 Context
Menu
3.4 Adding
Singularities
3.4.1 Notes
4. Credits
Introduction
MIT Java Pflow is a Java applet that computes and visualizes the
potential flow function inputed by the user. The potential flow field
is
built as a superposition of basic flow singularities.
Requirements
MIT Java Pflow was implemented in standard Java under Sun Microsystems
1.4.1 JDK. Successfully running it requires at a minimum a Web
Browser and 1.4.1 Java Virtual Machine plugin correctly installed. A
three-button mouse is also strongly recommended to take full advantage
of the GUI functionality (an operating system emulating third-button
click such as Linux should also work).
User Interface
Mit Java Pflow fully utilizes the input capabilities provided by
point-and-click devices. Nothwithstanding, the interface can also be
driven via keyboard input and there are viable tab-navigation paths in
the user interface.
Principles
Left
click is used for the primary input of the visualization options
currently active. It also provides coordinates to the facility used to
input the basic flow singularities.
Right
click provides a secondary (optional) input point facility, used
to input as many secondary points as might be required by the selected
visualization options. Not all visualization options need or use
right-click secondary input points.
Center
click provides a way to the user to clear all the active
visualization options, Note that this leaves all the
visualization
options not active at the time completely unaffected, so the user can
selectively clear just the content of one visualization by deactivating
all other visualization options, center-clicking to clear only the option(s) remained active
and then re-activate the other options, which will have reatined their
previous state.
Overview
The MIT Java Pflow GUI is composed of three main sections: a display
panel at the top, a visualization/display option pane below it, and an
area dedicated to the insertion of new basic flow singularities at the
bottom.
The display panel is sensitive to all three types of clicking and it
responds according to the visualization options which are activated at
the time of the click. The display area is a four-quadrant display
within the domains described by the (x,y) pairs at the four corners of
it. The scale of the display area (and corresponding domains) are
affected by the zoom ratio selected in the ZOOM combo box in the option
pane, which effectively represents the ratio of display area pixels to
the effective units of the coordinate system.
left-clicking in the display panel updates the x,y values in the add
singularities area to match the location of the user's click:
similrly, hovering on the display panel results in the current mouse
coordinates being displayed in the left of the status bar located at
the
applet's bottom.
Functionality
The applet provides three distinct kinds of functionality: insertion of
the basic singularities, definition and handling of the visualization
options, and management of the input values stored in memory.
Singularities
Currently the system supports five types of basic
singularities and their respective subtypes:
Free
Stream
Free Stream is defined by a (strength, orientation)
pair which is printed to the screen in that order. Orientation is
measured in radians, counterclockwise from three o'clock. The
Free
Stream icon is also displaying the orientation angle by pointing in its
direction.
2D Source
The 2D Source singularity is defined by a location
and a strength. The latter one is printed near the icon representing
the
singularity for the user's convenience. A 2d Source is displayed as a
filled square, while a 2d Sink is represented by a hollow square.
2D Vortex
A 2d vortex is similarly defined by a strength
(circulation) and a location. A reminder of the strength of the vortex
is placed next to the icon for the user's convenience. Akin to the 2D
Source representation, the 2D Vortex icon (a circle) is hollow if the
strength value is less than zero.
2D Dipole
A 2D Dipole is defined by its strength, orientation
and coordinates, the first two of which the user is reminded of next to
the icon marking the dipole's location. Similarly to the previous two
singularities, a negative value in strength is plotted with a hollow
icon (a diamond in this case).
Corner Flow
Corner Flow is defined by its location and the
orientation parameter, which can assume only a specific set of
values. Corner flow is represented by a rectangular bracket whose orientation is independent the
orientation parameter.
Visualization
Options
Point Evaluation
The point evaluation visualization option
displays a vector representing the strength and direction of the
velocity field at the point of a user's click. Additional information
is
provided numerically in the form of the following pairs: (x,y), (u,v).
p, where p stands for the pressure at the given point ((1- (v^2 +
u^2))/
U) where U is the Free Stream strenght (or 1 if no Free Stream is
present).
The current set of Point Evaluations can be cleared
by clicking the middle mouse button while the option is enabled.
Vector Field
The Vector Field visualization option plots the
vectors composing the velocity field in the same way Point Evaluation
does, except that it does not provide the additional numerical
information that Point evaluation includes. Point Evaluation and Vector
Field are mutually exclusive, meaning that activating one option will
automatically disable the other if that was selected at that time.
State
is preserved, so it is possible to revert to the previous selection by
selecting it once again.
The vector field is plotted at the intersection
points of the grid, and its density can be manipulated by using the
Grid
Size scroller.
Grid and GridScale
The Grid checkbox enables a reference grid
which is used, among other things, to determine the plotting points of
the vector field. The Grid Scale scroller controls the density of the
grid. The Grid Scale scroller will not be enabled unless the grid is
enabled as well.
Plot Stream Lines
The Plot Stream Lines visualization option initiates
tracing of a streamline starting at a point given by the user with a
left-click on the display panel. This is done in two steps from
the initial point, and can take up to 10,000 iterations to complete.
The current set of Stream lines can be cleared by
clicking the middle mouse button while the option is enabled.
Pressure Coefficient
The Pressure Coefficient visualization option
initiates tracing of a streamline in exactly the same way the Plot
Stream Lines option. If the user whishes to visualize a pressure
contour
on this streamline, she must select two points on the streamline
between
which the pressure contour will be plotted - this is done with the
secundary input button, which is the right mouse button.
Please note that you can select endpoints of the
pressure contour only on the last streamline you traced.
The current set of Stream lines and any pressure
contour associated with them can be cleared by clicking the middle
mouse
button while the option is enabled.
Other
Options
Zoom
Zoom provides a number of levels of magnification on
the display panel. Zoom is always performed with respect to the origin
of the coordinate axis in the current version of MIT Java Pflow.
Information on the endpoints of the domain currently
being displayed by the graphic panel is provided in the four corners of
said panel in the form of (x,y) pairs corresponding to the extremities
of the drawing canvas.
Reset
The Reset button will clear the applet state in its
entirety, removing all streamlines, point evaluations, pressure
contours
or singularities that the user might have inputted. This is different
from using the middle mouse button as the latter only clears the
currently active visualization options and never affects the
singularities themselves.
Context Menu
The secondary mouse button triggers a context munu
in the option pane. When the user
right-clicks the following choices are presented:
The first selection brings up this help file in a
new browser window, while the second one brings up the
Authorship/copyright dialog.
Adding Singularities
Notes
None at this time.
Credits
MIT Java Pflow 1.0 (rev 2.2)
Written by Federico
Lucifredi
Original FORTRAN numerical routines by Karl P. Burr
(c) 2003, MIT Ocean Engineering Department