DOCUMENTATION 2600
SYNOPSIS
PROGRAM NAME: immodpg (interactive ray trace modeling)
AUTHOR: Juan Lorenzo
CHANGES and their DATES
DATES: Feb 7 2020
April 4 2021
Version 0.0.1 , 0.0.2
DESCRIPTION
Interactively model first arrivals using raytracing approximation
USE
Examplesoff
SEISMIC UNIX NOTES
STEPS
NOTES
We are using Moose.
Moose already declares that you need debuggers turned on
so you don't need a linew like the following:
use warnings;
When program starts change file is initialized to "no". --change file
is deleted and reset to a default "no" at the start.
change file is set to yes in Perl.
however we are careful only to do so when the file indicates a previous 'no'
and reset to no in fortran after fortran uses the setting
When exiting the change file contains a "yes"
Avoids asynchronous reading and writing crashes
Lock files are not failsafe
There are two types of methods:
One method type only sets the message type (immodpg->set_option(message #)) and
indicates a forced change (immodpg->set_change(yes)) for use with fortran
program immodpg.for
e.g., _setVbot_plus, _set_move_down.
The gui shows a symbol for these cases
A second type of method manages changing values for a parameter as well
as the functions of the first method. These actions are relegated to
immodpg
eg., _setVbot, _setVtop_upper_layer, _setVincrement, _set_clip, _set_layer
The gui shows a parameter value that can be changed by the user.
The Entry widget is configured to recognize text value changes and
a return(1) is needed to indicate a successful validation
immodpg must follow premmod to prevent logical circularity as a result of the use of the 'aliased' syntax
April 2021, removed commented lines
private anonymous hash Hands off variables for external printing Stores GUI widget references for immodpg
Instantiate classes:
Create a new version of the package
with a unique name
Declare variables in local memory space
DEFAULT VALUES
Default values for screen when the configuration file is missing
initialize:
Useful variables with defaults
Create Main Window
Start event-driven loop
Interaction with user
immodpg requires Main window widget to display
error messages
Decide whether to
Start Main widget but temporarily withdraw
until checks are complete
Window is needed for error messages
Clean old files
from past sessions
Initialize files
After cleaning trash
Initialize values
In modules
Get starting configuration
Parameters from a configuration file
Error checks
Adjust working, upper, and lower layer for extraneous values
Get model values
of Vp, thickness, and error switch from immodpg.out for initial settings in GUI
Prepare su file for input to immodpg.for generate a binary file
Establish Main Window
tTp_settings frame
Contains: (1) working layer (2) z inc and V inc in m/s
help goes to superflow bindings
Font Registry
Font types
Entry widgets
VbotEntry
VbotEntry MUST first be created before it can be used by a callback subroutine
Vbot_upper_layerEntry
Vbot_upper_layerEntry MUST first be created before it can be used by a callback subroutine
VincrementEntry
VincrementEntry MUST first be created before it can be used by a callback subroutine
VtopEntry
VtopEntry MUST first be created before it can be used by a callback subroutine
VbotNtop_factorEntry
VbotNtop_factorEntry
MUST first be created before it can be used by a callback subroutine
Vtop_lower_layerEntry
Vtop_lower_layerEntry MUST first be created before it can be used by a callback subroutine
clip4plotEntry
clip4plotEntry MUST first be created before it can be used by a callback subroutine
layerEntry
layerEntry
MUST first be created before it can be used by a callback subroutine
lower_layerLabel
lower_layerLabel widget will be updated in immodpg
Entry _thickness_increment_mEntryEntry
thickness_increment_mEntry
MUST first be created before it can be used by a callback subroutine
thickness_mEntry
thickness_mEntry
MUST first be created before it can be used by a callback subroutine
thickness_mLabel
upper_layerLabel
upper_layerLabel widget
Is updated in immodpg
Row index=0
Row index
Row index
Row index
Row index
Row index 1-2 col 3
Row index 3-4 col 4
Row index 2, col 6
Row index
row index
row index
row index
VbotNtop_multiply_button row index = 1 col 2
row index = 1 col 2
row index = 2 col 7
row index = 3 col 7
Row index
Row index
Row index=5
zoom_minus_button row index 1-2 col 3
zoom_plus_button row index 1-2 col 3
Label
Widget box for Vbot of upper layer
Label
Widget box for Vincrement
Label
Widget box for Vtop
Label
Widget box for Vtop of lower layer
Label
for Vbot
Label
factor
Label
clip4plot
Label
Widget box for thickness increment
Label empty
Label
Widget box for Layer number
Label
Widget box for Layer number
Label
Widget box for velocity m/s
Label
Widget box for Layer number
Row index = 0 col8
Row index = 0 col 9
Row index = 0 col 10
Row index = 1-2 col 3
Row index = 1-2 col4
Row index = 1 col 8
Row index = 1 col 9
Row index = 2 col 8
Row index = 2 col9
Row index = 2 col10
Row index = 2 col11
Row index = 3 col11
Row index = 3 col 8
Row index = 4 col 8
Row index = 4 col 9
Row index = 3-4 col 3
Row index = 3-4 col 4
Row index = 1 col 5
Row index = 2-3 col0
Row index = 2-3 col 1
Row index = 2-3 col2
Row index 2 col 5
Row index 2 col 6
Row index 2 col 7
Row index 3 col5
Row index 3 col 6
Row index 3 col 7
Row index 4 col 5
Row index 5 col 8
Row index = 5 col 4
Row index = 0 col 0
Row index = 8 col 1
Row index = 7 col 0
Row index = 7 col 3
Row index = 6 col 1
Row index = 7 col 1
Row index = 7 col 5
Row index = 6 col 5
Row index = 8 col 5
Row index = 6 col 8
Row index = 7 col 8
Row index = 8 col 8
Row index = 9 col 9
Row index = 9 col 8
Row index = 6 col 9
Row index = 7 col 9
Row index = 9 col 8
sub _setVincrement
Sets interaction with immodpg.for Writes out Vincrement for immodpg to read return(1) validates command for Entry
sub _setVbotNtop_factor
Sets interaction with immodpg.for Writes out VbotNtop_factor for immodpg to read return(1) validates command for Entry
sub _set_clip _set_clip sets interaction with immodpg.for Writes out clip for immodpg to read return(1) validates command for Entry' print("immodpg.pl,_set_clip,$immodpg_Tk->{_clip4plotEntry}\n");
sub _set_layer _set_layer Write out message for mmodpg.f Writes out layer for immodpg to read return(1) validates command for Entry
sub _setVbot
Callbacks:
Write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
return(1) validates command for Entry
sub _setVbot_upper_layer
Callbacks write out message for mmodpg.f
set_option and set_change
Set interactions with immodpg.f
return(1) validates command for Entry
sub _setVtop
Callbacks write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
return(1) validates command for Entry
sub _setVtop_lower_layer
Callbacks write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
return(1) validates command for Entry
sub _setVbotNtop_multiply
Callbacks:
- provide widgets to immodpg
-refocus allows other Entries to update (focus)
-update the gui for factor (_setVbotNtop_factor)
_setVbotNtop_factor ALSO provides widgets to immodpg
-update gui velocities (->setVbotNtop_multiply)
-Write out message for mmodpg.f:
set_option
set_change
set interactions with immodpg.f
sub _setVbot_minus
Callbacks write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
print("write Vbot_minus_opt -, $Vbot_minus_opt\n");
sub _setVbotNVtop_lower_layer_minus
Callbacks write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
print("write VbotNVtop_lower_layer_minus -, $VbotNVtop_lower_layer_minus_opt \n");
sub _setVbotNVtop_lower_layer_plus
Callbacks write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
print("write VbotNVtop_lower_layer_plus +, $VbotNVtop_lower_layer_plus_opt \n");
sub _setVbot_plus
Callbacks write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
print("main _setVbot_plus,Vbot_plus_opt +=$Vbot_plus_opt\n");
sub _setVtop_minus
Callbacks
setVtop_minus:
modify gui
set_option:
Write out message for mmodpg.f
set_change:
set interactions with immodpg.f
print("write Vtop_minus_opt -, $Vtop_minus_opt\n");
sub _setVtop_plus
Callbacks
setVtop_plus:
modify gui
set_option:
Write out message for mmodpg.f
set_change:
set interactions with immodpg.f
print("write Vtop_plus_opt +,$Vtop_plus_opt\n");
sub _setVbotNtop_minus
Callbacks
setVtop_plus:
modify gui
set_option:
Write out message for mmodpg.f
set_change:
set interactions with immodpg.f
create pause between Vbot and Vtop changes
sub _setVbotNtop_plus
Callbacks write out message for mmodpg.f
set_option and set_change
set interactions with immodpg.f
print("write VbotNVtop_plus +\n");
sub _setVtopNVbot_upper_layer_minus
Callbacks
setVtop_plus:
modify gui
set_option:
Write out message for mmodpg.f
set_change:
set interactions with immodpg.f
print("main,_setVtopNVbot_upper_layer_minus, write VtopNVbot_upper_layer_minus -,$VtopNVbot_upper_layer_minus_opt \n");
sub _setVtopNVbot_upper_layer_plus
Callbacks
setVtop_plus:
modify gui
set_option:
Write out message for mmodpg.f
set_change:
set interactions with immodpg.f
print("write VtopNVbot_upper_layer_plus +, $VtopNVbot_upper_layer_plus_opt \n");
sub _set_exit
Callbacks write out message for mmodpg.f
Write out
saying goodbye
clear old images
kill window
stop script
print("write_set_exit\n");
$exit_button->focus;
sub _set_move_down
Callbacks write out message for mmodpg.f
Write out
$move_down_button->focus;
print("write _set_move_down -\n");
sub _set_move_left
Callbacks write out message for mmodpg.f
Write out
$move_left_button->focus;
print("write_set_move_left -\n");
sub _set_move_right
Callbacks write out message for mmodpg.f
Write out
$move_right_button->focus;
print("write_set_move_right -\n");
sub _set_move_up
Callbacks write out message for mmodpg.f
Write out
print("write_set_move_up -\n");
$move_up_button->focus;
sub _set_update
New focus is needed within set_update, specifically: immodpg,_check_update print("immodpg.pl,_set_update\n");
sub _set_zoom_minus
Callbacks write out message for mmodpg.f
Write out
print("write_set_zoom_minus -\n");
sub _set_zoom_plus
Callbacks write out message for mmodpg.f
Write out
print("write _set_zoom_plus +\n");
sub _set_thickness_m
print("main,_set_thickness_m, change_thickness_m_opt=$change_thickness_m_opt\n");
sub _set_thickness_m_minus
print("write _set_thickness_m_minus - \n");
sub _set_thickness_m_plus
print("write _set_thickness_m_plus -\n");
sub _set_thickness_increment_m
print("immodpg.pl,_thickness_increment_m,$immodpg_Tk->{_thickness_increment_mEntry}\n");