Powerful Scripting

PYTHON

The Python programming language is embedded inside FLAC3D. Python is a general purpose programming language with good support for scientific and numerical programming. Python has been extended to allow models to be manipulated from Python programs. The Python modules NumPy, SciPy, and Pyside are included with FLAC3D for scientific computing, science and engineering tools (optimization interpolation, integration, etc.), and customizing the user interface, respectively.

With FLAC3D 9, Python has been updated to version 3.10.5 to let you work with the latest available modules.

LEARN MORE

FISH

FISH is an embedded programming language that enables the user to interact with and manipulate models, defining new variables and functions as needed. These functions may be used to extend, add to, or control the program.

FLAC3D 9 includes the latest version of FISH and updated documentation for working with multithreaded FISH splitting and operators.

MULTITHREADED FISH

If you are modeling using FISH, be sure to use splitting rather than loops and use operators in order to best utilize your multithreaded computer hardware and minimize your modeling time.

For example, taking the FLAC3D Hoek-Brown Slope example in the documentation, rather than using a constant value for the Hoek-Brown constitutive model property constant-sci, let's assign a value to each zone using a pseudo-random uniform distribution within 30 ±10 MPa, to provide a degree of rock strength variability across the model as shown below.

Slope model showing the value of the Hoek-Brown intact rock strength property after a uniform distribution has been assigned using loops, splitting, or operators.

A timing test was run five times for each of the FISH functions above by calling the time.clock intrinsic function at the start and end of the function and calculating the difference. The following figure shows the average time required for each approach discussed above (in hundredths of a second) for a model with 228,000 zones. The test was performed on an i9 CPU (3.7 GHz) with 64 GB RAM and 10 cores (20 logical processors).

Time (in hundredths of a second) required for each approach discussed above.

While any of the methods reviewed above are effectively instantaneous, the performance will become more important for very large models with millions or tens of millions of objects (zones, blocks, etc.) and/or if such functions are being called during cycling (i.e., each step). As such, a method (operators) that is over 260,000 times faster than another (loop while) becomes highly desirable.

MORE INFORMATION


Latest News
  • ITASCA Releases MassFlow version 9.0 ...
    Read More
  • Introducing IMAT (ITASCA Mining Analysis Toolbox): Transforming Mining Analysis Solutions ...
    Read More
  • 3DEC 9 Officially Released ITASCA announces the release of 3DEC v9, an advanced three-dimensional, hybrid discontinuum and continuum modeling...
    Read More

Upcoming Events
22 Apr
FLAC2D In-Person Introductory Course
Live in-person introductory training course. This 3-day course provides a general overview of FLAC2D and covers many basic concepts and... Read More
29 Apr
PFC In-Person Introductory Course
Live in-person introductory training course. This four-day course provides guidance in the use of the Itasca codes PFC2D and PFC3D to s... Read More
29 May
Getting Started with FLAC2D/FLAC3D
Objectives of the training: •Understand the FLAC2D/ FLAC3D numerical approach and the types ofproblems it can solve•Know how to manipul... Read More