fish callback command
Syntax
- fish callback keyword
Add/remove functions to be executed in response to callback events.
Note
The whilestepping expression inside a FISH function automatically inserts the FISH function into the cycle sequence at f = -1.0.
The callback mechanism allows for the FISH function sf to be executed at a specific point in the cycle sequence during cycling — at point f in the sequence (if supplied) or when a specific callback event occurs (see the
fish list callbacks
command for a list of events).Three types of events can trigger the execution of a FISH function: 1) model entity creation/deletion; 2) contact model events;[1] and 3) solve termination events. In cases 1) and 2), values may be returned to sf as arguments, provided that sf takes arguments.
In case 1), the first argument passed to sf is a pointer to the entity that has been created or deleted. In case 2), the arguments depend on the contact model implementation. [CS: removing the following until it is true] and are detailed in :flag:nomenclature
If the remove keyword is given, then the first instance of sf is removed. [CS: removing the following until it is true] See the :flag:tuto_callbacks for examples of callback usage.
- add sf keyword
Adds a FISH function to be called. When the function is called depends on the following keywords:
- f <keyword>
The FISH function will be called every step at the location in the cycle sequence given by f. The following keywords are available to reduce the frequency of the callback.
- process keyword
If specified, then the function will only be called if the process indicated is active during that particular cycle.
- creep
The callback will only execute if the creep and mechanical process is active.
- dynamic
The callback will only execute if the dynamic and mechanical process is active.
- fluid
The callback will only execute if the fluid process is active.
- mechanical
The callback will only execute if the mechanical process is active.
- thermal
The callback will only execute if the thermal process is active.
Was this helpful? ... | PFC 6.0 © 2019, Itasca | Updated: Nov 19, 2021 |