Practice Workbook
This workbook is designed for use in Live instructor-led training and for OnDemand self-study. The explanations
and demonstrations are provided by the instructor in the classroom, or in the OnDemand eLectures of this course
available on the Bentley LEARNserver (learn.bentley.com).
This practice workbook is formatted for on-screen viewing using a PDF reader.
Getting Started
Last Update: May 2018
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 1
Description and Objectives
Course Description
In this workbook we will become familiar with how MOSES runs and how to interact with the software.
Skills Taught
• Gain familiarity with MOSES Editor.
• Start the MOSES Solver interface.
• Locate the output results.
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 2
Getting Started
Most MOSES installation files are in the directory C:\Program Files\Bentley\Engineering\MOSES CONNECT Edition VMM.mm\hdesk (where MM and mm are the major and
minor version numbers respectively). For the sake of brevity this path name will be shortened to “..\hdesk”.
The files for this exercise are:
• ..\hdesk\b_run\b_run.cif
• ..\hdesk\b_run\b_run.dat
In this exercise we will become familiar with the file structure and run a simple analysis. At this point, we are not interested in understanding every command, just the
concept of menus.
For a list and discussion of the commands please read MOSES Reference Manual in ..\hdesk\document\include\a4.pdf.
Double click on the b_run.cif file (this is the command file) to open the file in Moses Editor as shown in Figure 1. MOSES Editor color-codes the commands to facilitate easy
reading of the data and editing the contents.
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 3
Figure 1 The b_run.cif in MOSES editor
In the main menu of the editor there are two large green buttons. One is labeled “Run” the other is labeled “Re-Run”. Once “Run” is clicked, the MOSES Solver window
should appear and the analysis commands scroll by. This should take a few seconds, at most. When the MOSES window disappears, there should now be a b_run.ans (ans is
short for answers) and a b_run.dba (dba is short for database) folder in the working directory. By default, the *.ans and *.dba folders are created in the same directory
where the *.cif and *.dat files reside.
The b_run.dba directory is where the database is located. All contents of any *.dba folder are binary and so are readable by only the MOSES Solver. Only the data in the
*.ans directory are formatted so that they can be viewed. In this case the b_run.ans directory contains:
• log00001.txt – the log file
• out00001.txt – the output file
• gra00001.png – the graphics file
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 4
The log file contains the dialog that you and MOSES had during the run. What happened when you clicked on the green “Run” button was that you instructed MOSES to use
the "root" b_run. MOSES found b_run.cif and since there was no existing database, it read the commands in b_run.cif and executed them. The log contains the dialog. The
output file contains the MOSES output from the last run. This file only gets written to when you instruct MOSES to do so. More will be said of its contents later. Finally, the
graphics file contains a picture of the model. If you have set the default graphics for png or jpg you will have gra00001.png or gra00001.jpg respectively.
Note: To set your default graphics click on Customize>Edit Preferences>Printing> and set the Format for graphics to png or jpg.
After the analysis we will normally look at the log and the out file, which can both be found in the ans directory. The log file name usually begins with the characters “log”
and the output file name usually begins with the characters “out”. The log file is a log of the commands used to perform the analysis. The log file is important as it shows
the steps taken to arrive at the results. The out file contains the results of the calculations while Figure 2 shows the contents of the log file.
Figure 2 A view of the log file in MOSES editor
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 5
Interactive Mode
If you now click on the “Re-Run” button, something different happens! This time, you get a window and a prompt and nothing else. This time, MOSES detected that a
database exists and therefore did not execute the commands in b_run.cif. Instead, MOSES expected you to issue new commands to change the existing state of affairs. The
situation at the end of the first run is remembered, so you can pick up where you left off. In fact, the last few commands from the previous session are displayed, along with
the "MOSES Finished" message, and the new startup banner for this second session.
To obtain a picture of your system, click on the "Graphics" button on the top tool bar and select “Picture Options”. This will open a dialog box called "Picture Options". In
the Rendering Type selection box choose “Solid” and then click “OK”. A side view of the barge with cargo will appear as shown in Figure 3.
Figure 3 Graphical representation of barge with cargo
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 6
If you click on the cargo, the sidebar on the right of your screen will be filled with information as shown in Figure 4. You can move to different tabs to access different types
of information like weight, displacement, mass properties and much more.
Figure 4 Access to cargo properties
Interacting with MOSES
Return to the log file discussed earlier by clicking on the “Log” tab in the upper left-hand corner of your screen. Now type in
&status b_w
at the bottom of the window as shown in Figure 5 and press Enter. The log window will be updated with buoyancy and weight properties of the barge as instructed.
Note: Click the Help button on the top toolbar, then select "Manual Contents" and will you get the Help Menu. You can now page through the manual or use the tabs
at the bottom left to switch between the table of contents, commands index or options index.
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 7
Figure 5 Command input in the log file
Now, press Ctrl+G (the Ctrl key and G simultaneously) to view a picture of the model. Click on the “Reset View” icon at the top left corner of the display window. The left
arrow key will translate the picture to the left, the up arrow key will translate it away from you. You can save this view to a file by clicking on the "Save" icon, located at the
top left of the screen, just under the top toolbar. The result of this key combination appears in Figure 6 and can be found in the *.ans directory.
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 8
Figure 6 A view of the barge-cargo model
Note: You can click on the Change GL Mode icon at the left of the window to toggle between wireframe and solid views of the model.
You can exit the analysis by typing
&finish
in the log file, or by pressing Ctrl+F simultaneously.
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 9
Accessing Analysis Results
In the b_run.ans directory one can find two log files (with txt extension) and the out file (also in txt format). The first log file contains all the commands that were processed
during the analysis. The second log file contains anything that was requested after the analysis with the &STATUS B_W command.
The out file contains hydrostatic properties, hydrostatic coefficients, righting arm result and much more. A glimpse is given in Figure 7.
Figure 7 The contents of the out file
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 10
Discussion
In this analysis, a barge is set at a draft and trim, the weight necessary to be at equilibrium is computed and three sets of hydrostatic calculations are reported. The three
hydrostatic calculations are:
1. The curves of form are computed in the section beginning with the CFORM command.
2. Stability righting arm and heeling arm curves are computed in the section beginning with the RARM command.
3. Longitudinal strength is computed in the section beginning with the EQUI_H command.
After each calculation, MOSES automatically moves to the Disposition menu where the results can be reported to an output file, saved for later use or plotted on a graph
(among others). To view the variables available in the Disposition menu the VLIST command is issued. For the b_run.cif analysis this list can be found in the log file in the
answers directory (see Figure 8 for an example).
Figure 8 Variable map for curves of form calculation
After the full list of variables is displayed a plot can be generated using the PLOT command. The numbers after the PLOT command tell MOSES which variables to use as the
ordinate (vertical axis) and the abscissa (horizontal axis). In the Figure 8 example these variables are 1, 4, and 11, so plot should display displacement and KMT against draft.
The plot generated by this command is shown in Figure 9 and further examples of the plots generated with the shear and bending moment results can be found in Error!
Reference source not found.Figure 10 and Figure 11.
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 11
Figure 9 Curves of plot form
Finally, the REPORT command adds a pre-formatted table containing the results of the computation just performed to the output file. Once we have finished reporting, we
exit out of the Disposition menu by issuing an END command. MOSES will then return to the previous menu, in this case HSTATICS.
Note: The comments in the *.cif file tell show that the Hydrostatics menu has been entered. When MOSES is working, if you look at the upper blue bar, you will notice
that the words change from "Main Menu" to "Hydrostatic Menu" and "Disposition Menu".
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 12
Figure 10 Hog case for basic run Figure 11 Sag case for basic run
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 13
Exercise A
1. What are the values of KML and KMT for a 12 ft draft?
2. What is the righting arm at 28 degrees roll?
3. At what longitudinal location does the shear force cross the zero axis for the wave crest at location 0.0?
4. At what longitudinal location does the shear force cross the zero axis for the wave crest at location 200.0?
Note: The answers can be found in the b_run.ans directory in the out00001.txt file.
Exercise B
The number of stations defined affects the results. In the b_run.dat file change line 20 from
plane 0 100 200 300 400 -rectangular 0 25 100
to
plane 0 50 100 150 200 250 300 350 400 -rectangular 0 25 100
1. Save the changes.
2. Re-run the analysis
Did the results change? If so, why?
Copyright © Bentley Systems, Incorporated DO NOT DISTRIBUTE – Printing for student use is permitted 14