# Physics-Informed Neural Networks for Cantilever Dynamics and Fluid-Induced Excitation
## 3 Experiments
### Vibration of a Cantilever
#### 3.1.3 Neural Networks' Architecture  
Figure 1b shows the PINN architecture used to solve the free vibration of a cantilever. The model is designed to take two input variables, \(x\) and \(t\), defined in the ranges \([0,\ L]\) and \([0,\ \tau]\), respectively, where \(\tau\) is the characteristic time scale used in the configuration. A time-marching strategy is applied to extend the time horizon of the solution [14; 15]. This involves training a sequence of independent PINN models with a time step, \(\tau\), using the predictions of the previous model as the initial conditions for the next one.  
To separate the scales of trainable weights by physical dimensions, the PINN model has adopted two different global scaling layers at the top and bottom of the architecture. In the global scaling layers, the scaling constants are fixed by design, leading to zero trainable weights in those layers. The global scaling layer at the top adjusts the scales of the input variables (\(x\) and \(t\)) in the range of \(-1\) to \(+1\) with respect to \(L\) and \(\tau\). The scaled inputs are denoted as \(\widetilde{x}\) and \(\widetilde{t}\), respectively. Meanwhile, the global scaling layer at the bottom linearly increases the output with a proportionality constant equal to the characteristic deflection scale \(\omega_{\text{Ref}}\).  
The hidden layers between the two global scaling layers are constructed based on STD. The hidden layers consist of two parallel structures that reflect STD, denoted as \(G(\widetilde{x}|\ \theta)\) and \(H(\ \widetilde{t}|\ \theta)\). Each decomposed structure has two fully connected layers with ten neurons each at the top. The \(x_{j}+\sin^{2}x_{j}\) activation is employed with a local scaling layer, \(wx_{j}\). The constructed architecture is schematically illustrated in Figure 1b. The proportional constant in the local scaling layer \(w\) is determined by training. The outcomes of these fully connected layers are combined using an additional fully connected layer without activation, which produces single numeric valued outcomes \(g(\widetilde{x})\) and \(h(\widetilde{t})\) for structure \(G\) and \(H\), respectively. \(g(\widetilde{x})\) and \(h(\widetilde{t})\) are merged via multiplication, resulting in \(\widetilde{\omega}(\widetilde{x},\widetilde{t})=g(\widetilde{x})h(\widetilde{t})\). Therefore, the final prediction can be expressed as \(\omega(x,t)=\omega_{\text{Ref}}\widetilde{\omega}\) from the global scaling layer at the bottom. The constructed STD-PINN has a total of 286 trainable weights, which is orders of magnitude less than regular PINN architectures that have \(O\big{(}10^{3}\big{)}\) to \(O\big{(}10^{4}\big{)}\) trainable weights [1]. The regular PINN is constructed with fully connected layers and tanh activation, where three hidden layers of eleven neurons each are adopted, resulting in a similar size to the STD-PINN, with a total of 309 trainable weights.  
The collocation points were randomly sampled from the simulation domain, with 300, 300, and 5000 points selected for ICs, BCs, and PDE losses, respectively. The training process began with the Adam optimizer [37], using a learning rate of \(10^{-2}\) for 200 epochs, which successfully initiated the learning procedure. Afterwards, the optimizer was switched to the L-BFGS-G algorithm using the Scipy implementation [38; 39].