## 4 Numerical Implementation of the Nonlinear Creep Model of AS
### Numerical Implementation in FLAC3D  
FLAC3D numerical simulation of the nonlinear creep model of AS was achieved using the C++ programming language to connect it to the secondary development interface of FLAC3D. Its process included main three steps: modifying the header file (.h file), modifying the program source file (.cpp file) and generating the dynamic connection or linking library file (.dll format).  
(1) Modifying the header file  
This part mostly modified some basic information about the new constitutive model. The modification included mainly the name of the model, the ID version, basic parameters of the nonlinear creep model and the intermediate variables during the operation of the program. The primary purpose of the above modifications was to ensure that the embedded files and parameters were correctly identified by the FLAC3D software. In the current secondary development process, the model header file was named HKBN.h, the file was named HKBN, and the model ID was changed to 336.  
(2) Modifying the source file (.cpp file)  
At this stage, the Properties function, the Strata function, the Getproperty function, the Initialize function, and the Run function were modified so that essential functions, such as identification and initialization, could be used. Its main contents included the following steps:  
Modify the model structure: The constitutive model is actually an empty function. The main purpose is to assign the initial value to the derived new member in the custom HKBN.h header file. In general, the initial value is set to 0.  
Customize the Properties function: This function converts creep parameters in the nonlinear creep model into a series of strings. During FLAC3D operation, new parameters can be assigned to the relevant definitions through the string.  
Modify the Strata function, Getproperty function and SetProperty function: The Strata function is the unit status indicator, which realizes the precise positioning of the unit state. The main function of the Getproperty function and SetProperty function is to realize the assignment of creep parameters to the model parameters in the derived class.  
Modify the Initialize function: The main function of this function is to initialize the unit status indicator and related parameter assignments and assign values to the private variables of the custom nonlinear creep model defined in the derived class.  
Modify the Run function: The main purpose of this function is to realize the cumulative calculation process of defining a new model; that is, to calculate the strain increment in each cycle and convert it into a stress increment. Then, the new stress value of the calculation unit body is superimposed.  
Modify the Save.Restore function: The calculation results can be saved after this modification.  
(3) Generating dynamic link library (.dll format) file of nonlinear creep model  
The dynamic link library is a necessary part of the normal call of the nonlinear creep model. The main steps are as follows. First, the user defined map (UDM) folder is named HKBN and copied to the FLAC3D installation location. Then, the Visual Studio software is run, and the udm.veproj file is opened. Second, the UDM command is executed to modify the output file named Debug/HKBN.dll. The file is a dynamic connection library of the nonlinear creep model. Finally, the solution command is run to check whether the dynamic library file has been successfully exported. If the export is successful, it is copied to the FLAC3D installation location and invoked directly during simulation. Otherwise, it is checked and modified, and the above steps are repeated after modification. The entire process is shown in Figure 11.