# Meshfree Variational-Physics-Informed Neural Networks (MF-VPINN): An Adaptive Training Strategy
## 2 Problem Formulation
### Problem Discretization
Moreover,since in [47] it has been proven that the VPINN convergence rate with respect to mesh refinement decreases when the order of the test functions is increased, we are interested in a space \(V_{h}\) that only contains piecewise linear functions. For the sake of simplicity, we only consider the case where \(n=2\); the discussion can be directly generalized to the more general case \(n\in\mathbb{N}\). Let \(\hat{P}\subset\mathbb{R}^{n}\) be a reference patch. In the following discussion, \(\hat{P}\) can be any arbitrary star-shaped polygon with \(N_{\hat{P}}\) vertices and the dimension of its kernel strictly greater than zero. Nevertheless, in the numerical experiments, we only consider the reference patch \(\hat{P}=[0,1]^{2}\) to avoid any unnecessary computational overhead. Let \(\mathcal{M}=\{M_{i}\}_{i=1}^{n_{\text{patches}}}\) be a set of affine mappings such that \(M_{i}:\hat{P}\to P_{i}\subset\Omega\), where we denote as \(P_{i}\) the patch obtained transforming the reference patch \(\hat{P}\) through the map \(M_{i}\). We assume that \(\mathcal{P}=\{P_{i}\}_{i=1}^{n_{\text{patches}}}\) is a cover of \(\Omega\), i.e., \(\cup_{i=1}^{n_{\text{patches}}}P_{i}=\Omega\), and we admit overlapping patches. Let us consider the triangulation \(\hat{\mathcal{T}}=\{\hat{T}_{j}:1\leq j\leq N_{\hat{P}}\}\) of \(\hat{P}\) obtained by connecting each vertex with a single point \(\mathbf{c}_{\hat{P}}\) in its kernel. It is then possible to define a piecewise linear function \(\hat{\varphi}\) vanishing on the border of \(\hat{P}\) such that \(\hat{\varphi}(\mathbf{c}_{\hat{P}})=1\) and \(\hat{\varphi}_{|\hat{T}_{j}|}\in\mathbb{P}_{1}(\hat{T}_{j})\), for any \(j=1,\ldots,N_{\hat{P}}\). Then, we define the discrete test space \(V_{h}\) as \(V_{h}=\text{span}\{\varphi_{i}:i=1,\ldots,n_{\text{patches}}\}\), where \(\varphi_{i}\in V\) is the piecewise linear function:  
\[\varphi_{i}(\mathbf{x})= \begin{cases}\hat{\varphi}(M_{i}^{-1}(\mathbf{x})),&\mathbf{x}\in P _{i},\\ 0,&\mathbf{x}\
otin P_{i}.\end{cases}  \tag{7}\]  
We remark that the only required triangulation is \(\hat{\mathcal{T}}\), which contains only \(N_{\hat{P}}\) triangles (in the numerical tests in this paper, \(N_{\hat{P}}=4\)). Instead, there exists no mesh on \(\Omega\) and the test functions \(\varphi_{i}\) and their supports \(P_{i}\) are all independent. Therefore, the proposed method is said to be meshfree. A simple example of a set of patches \(\mathcal{P}\) with \(n_{\text{patches}}=7\) on the domain \(\Omega=[0,1]^{2}\) is shown in Figure 1. For the sake of simplicity, in this work, we consider a squared reference patch \(\hat{P}\) with \(\mathbf{c}_{\hat{P}}\) coinciding with its center, and we let each mapping \(M_{i}\) represent a combination of scalings and translations. Using the introduced finite-dimensional set of functions \(V^{\mathcal{N}\mathcal{N}}\) and \(V_{h}\), it is possible to discretize Problem (4) as follows: Find \(u^{\mathcal{N}\mathcal{N}}\in V^{\mathcal{N}\mathcal{N}}\) such that  
\[a(u^{\mathcal{N}\mathcal{N}},v)=F(v)\qquad\forall v\in V_{h}\,. \tag{8}\]  
Figure 1: Graphical representation of a set \(\{P_{i}\}_{i=1}^{n_{\text{patches}}}\) obtained from a squared reference patch \(\hat{P}\) with \(\mathbf{c}_{\hat{P}}\) in its center covering the domain \(\Omega=(0,1)^{2}\).