Cyclops Control

This module provides a dictionary through which all computational and physical parameters are organised and accessed. All have semi-reasonable default values and may be chosen by the user via the command-line interface.

Functions

  • make_control : Creates a control object with the default values
  • setup_control : Updates the default control object with user selections

Parameters

  • filename : Filename root for input initial conditions <str>
  • Nx : Number of gridpoints along one direction. Domain is Nx X Nx square <int>
  • Nt : Number of coarse timesteps. In practice set to number of processes <int>
  • coarse_timestep : Coarse timestep length <float>
  • fine_timestep : Fine timestep length <float>
  • Lx : Side length of the square domain <float>
  • conv_tol : The convergence criterion for iterative error <float>
  • HMM_T0 : The length of the averaging window (absoltue) <float>
  • mu : Hyperviscosity coefficient <float>
  • outFileStem : Optional stem for output filenames <str>
  • f_naught : Coriolis parameters <float>
  • H_naught : Mean water depth <float>
  • gravity : Gravitational acceleration, g <float>
Author: Adam G. Peddle
Version: 1.0
cyclops_control.make_control()[source]

Initialises the control object to the default values. New defaults should be placed here.

Returns

  • control : Default control object
cyclops_control.setup_control(invals)[source]

Creates and updates the default control object with user selections. Input should come via stdin and relies on sys.argv for parsing.

Parameters

  • invals : command-line input values in Unix-style

Returns

  • control : Default control object