Bijective Mapping Analysis to Extend the Theory of Functional Connections to Non-Rectangular 2-Dimensional Domains

This work presents an initial analysis of using bijective mappings to extend the Theory of Functional Connections to non-rectangular two-dimensional domains. Specifically, this manuscript proposes three different mappings techniques: (a) complex mapping, (b) the projection mapping, and (c) polynomial mapping. In that respect, an accurate least-squares approximated inverse mapping is also developed for those mappings with no closed-form inverse. Advantages and disadvantages of using these mappings are highlighted and a few examples are provided. Additionally, the paper shows how to replace boundary constraints expressed in terms of a piece-wise sequence of functions with a single function, which is compatible and required by the Theory of Functional Connections already developed for rectangular domains.


•
Projection mapping: a new method proposed in this paper to obtain simple bijective mappings that preserve the continuity through the transformation.

•
Polynomial mapping: based on the interpolation of the transformation using polynomial basis functions.
These three mappings are the subjects of the first three sections of this manuscript. These transformations are studied considering the direct and inverse mappings defined as:

2.
Inverse mapping: from domain W to domain Z.
The reason this paper is specifically interested in the mapping from/to the Z rectangular domain relies on the fact that the TFC has been fully developed for rectangular domains [1][2][3]. Therefore, the main purpose of this study consists of developing easy mappings between the unit-square domain and any other domain, where the flexibly can accommodate typical domains appearing in physics, science, and engineering problems. Examples of this include computation of structures with "C", "I", and "T" shapes, the simplification of differential equations, or its application in fluidynamics. In other words, by obtaining these mappings, the TFC framework is consequently extended to generic domains.
In addition, this work extends the application of the TFC to discontinuous boundary constraints, which appear in the projection mapping and may also appear in some other applications. This has been done by replacing the discontinuous sequence of boundary contraint functions with a single function. Finally, a least-squares method to approximate inverse transformations is provided for those mapping transformations with no analytical inverse.

Complex (Conformal) Mapping
In mathematics, a conformal mapping is a transformation that, locally, preserves angles, but not necessarily lengths. In particular, the conformal property is mathematically described in terms of the Jacobian of a coordinate transformation. If the Jacobian at each point is a positive scalar times a rotation matrix, then the transformation is defined as conformal. Since any function of a complex variable, w = f (z), provides a complex variable, then a complex function can be seen as a complex change of variables or, from a different point of view, as a mapping in a complex Euclidean plane [16]. In particular, any complex mapping, w = f (z), is mathematically proven to be conformal, i.e., it is a transformation preserving (signed) angles, meaning, local orientations.
Conformal (angle-preserving) and area/volume-preserving mappings are particularly important transformations since they are very interesting for their applications in physics, science, and engineering. For instance, these mappings are used to transform differential equations in order to simplify the system and make it easier to solve [16].
A generic complex analytical mapping can be expressed as, w = w r + i w i = f(z) = f z r + i z i = f r z r , z i + if i z r , z i , (2) where z, w ∈ ℂ, z r , z i , w r , w i ∈ ℝ represent the original and transformed points, and f : ℂ ℂ is the transforming function, where f r , f i : ℝ ℝ are the real and imaginary parts of the transformation. Examples of some basic complex mappings are: (1) Translation, w = z + z t , (2) Scaling, w = ρ z, (3) Rotation, w = e i ϕ z, (4) Affine, w = α z + β, (5) Inversion, w = 1/z, (6) Exponential, w = e z , (7), Squaring, w = z 2 , (8) Cayley, w = (z − 1)/(z + 1), and (9) Möbius (linear fractional), w = (α z + β)/(γ z + δ), which is subject to α δ ≠ β γ. In particular, the set of Möbius mapping includes, as a subset, translations, scalings, affines, inversions, and Cayley mappings. Figure 1 shows the effect of inversion (w = 1/z), exponential (w = e z ), squaring (w = z 2 ), and Möbius mappings for z = a + i b within the a, ∈ [−1, +1] domain. In particular, the Möbius mapping was selected with α = −3.8 + 4.4 i, β = 3.4 − 0.2i, γ = 1, and δ = −0.6 + 3.8 i. These values were obtained by selecting γ = 1 and imposing the mapping allowing the computation of α, β, and δ. The Möbius mapping can be seen as the stereographic projection from the plane to a rotated and translated unit-sphere. The Möbius mapping plays a particularly important role in the conformal complex mapping because: (1) it admits a closed-form expression for the inverse mapping and (2) is the composition or the most basic transformations of the space, including similarities, orthogonal transformations, and inversions. Also and for several dimensions equal or higher than 3, Liouville's theorem states that Möbius transformations are the unique transformations that are conformal.

Control Points in Complex Conformal Mapping
Given a set of n complex control points, w i with i ∈ {1, …, n}, in the W domain associated with n corresponding boundary reference points, z j with j ∈ {1, …, n}, in the unit-square Z domain, the transformation, is a n-point complex conformal mapping. In this equation, ϕ i (z) are a set of switching functions related to the reference points, z j . In particular, Let select n = 4 control points (red markers on the top-left plot of Figure 2) defined by, . (4) The switching functions, ϕ i (z), are expressed as a linear combination of n complex support functions. For the sake of simplicity, let the support functions be selected as complex monomials. The main reason for that is the simple closed-form expression of derivatives and integrals for this set of functions. Please note that since any set of n linearly independent functions can be selected as support functions, this provides additional degrees of freedom that are not analyzed in this study. Therefore, using complex monomial, the switching functions are expressed as, where c ij are a set of constants to be found. Since the switching property states that ϕ i (z j ) = δ ij , we can derive the following expression,  It is important to outline that in general complex mapping may not be bijective, which makes impossible to find an inverse transformation for the whole domain. However, due to the switching functions, the inverse mapping always exists for the control points. When the complex mapping is bijective, then a least-squares approximated inverse mapping using a basis of complex orthogonal polynomials and presented in Section 5 can be used.

Complex TFC Mapping
We can generalize the previous result by using the Theory of Functional Connections. In particular, the functional, where g(z) is a free complex function (where the g(z i ) must be defined), can be seen as the most general expression that defines the conformal mapping between the control points in Z and W. In fact, Equation ( Figure 2 shows a grid of orthogonal lines in the Z domain, while the top-center plot shows the lines mapped in the corresponding W domain using g(z) = 0, i.e., using Equation (3), and the control points given in Equation (4).
The free function does not change the mapping of the control points. The points mapping is the constraint embedded in Equation (5). The top-right plot shows the mapped W domain obtained using the free function g(z) = sin(3z/2) + cos(3z/2), i.e., applying Equation (5). This shows the free function "rubber" effect on the W domain. While the top figures use four control points (red dots), the bottom plots are obtained for eight control points distributed along a circle and using for the free function, the expression g(z) = sin(z 2 ) e −z2 .
This example highlights that the selection of control points is not completely free because they often produce non-bijective mappings (points in the W domain may be associated with multiple points in the Z domain). Non-bijective mappings may occur when one or more control points fall inside the W domain.
Equation (5) highlights the fact that the free function can be used not only to derive functional satisfying constraints, but also to warp domains (rubber effect). The free function, however, is not anymore completely free if the important bijective property (see the bottomright of Figure 2) must be preserved.

Projection Mapping
In this section, a transformation method based on a projection that preserves the continuity of the space and provides both the direct and the inverse mappings is presented. However, and due to its nature, the conformal property is not maintained by this mapping approach.
Projection mapping is based on the selection of a set of points (the projection points) inside the boundaries of the domain in such a way that a straight segment can be defined between any point in the domain and at least one projection point, where this segment does not cross at any moment any of the boundaries of the domain. This means that the distances from these projection points to the points at the boundary can be expressed as a continuous function, or in other words, if δΩ represents the boundary of the domain, the projection is well defined if and only if δΩ = δΩ(θ) is a bijective function where q is the polar angle coordinate of a given point in δΩ with respect the projection point.
The most interesting feature of the projection mapping is that, using an identical formalism, the direct and the inverse mapping transformations can be derived (isomorphism). If the projection points are selected properly, the continuity of the transformation can be assured; however, in general, the derivative of this transformation is not defined in the whole domain and thus, the transformation is not conformal.
To show the methodology in a clearer manner, we first present the case of a single projection point. Then, we use this result to generalize the methodology for the case of multiple projection points.

Single-Point Projection Mapping
The idea of this methodology is to perform a linear transformation in polar coordinates with respect to a projection point that lies inside the domain. While the projection mapping can be applied to any dimensional domains, to be consistent with the complex conformal mapping, the analysis is here restricted to bivariate domains.
Let {r, θ} be the polar coordinates with respect to the projection point defined in the space Z of a given point inside the domain, and let {d, ϕ} be the polar coordinates of that point with respect to the transformed projection point in the space W. As said before, the projection points are selected in such a way that it is possible to connect univoquely and with a straight line any point in the boundary with the selected projection point. Therefore, for any point inside the square boundary of Z, the distance from the projection point to the boundary can be defined as r b (θ) = f (θ) where f is a continuous but not differentiable function. In the same way, if the distances from the projection point to the boundaries in W can be expressed as d b (ϕ) = g(ϕ), then, the following direct transformation can be defined: . (6) This represents a transformation that maintains both the polar angle to the point as well as the ratio between the distances from the projection points to the point to transform and to the point in the boundary located at a polar angle θ from the projection point, i.e.,: d/d b (θ) = r/ r b (θ). In the same way, the inverse transformation can be defined by inverting the previous relation, or by applying the same formalism for the inverse transformation: Equations (6) and (7) allow performing a the projection transformation using a simple transformation. Nevertheless, in some applications it is useful to define the boundary in W as a given polygon defined by a set of control points. Therefore, we include in this section the algorithm to generate a transformation mapping between a set of n control points. In this case, and since we are using the control points as the reference to perform the transformation, the angles in both mappings are in general not equal as in the previous equations. In particular, a linear interpolation in the angle between the control points and the projection point is performed in order to maintain the continuity of the transformation.
Let a and b be the coordinates in Z of a given point inside the original domain that is required to be transformed, and x and y be the coordinates in W of the transformed point. Moreover, c = {c a , c b }, υ = {υ x , υ y } are the coordinates of the projections points in Z and W respectively, while {p a (j), p b (j)}, and {q x (j), q y (j)}, with j ∈ {1, …, n + 1}, are the coordinates of the n control points defined in Z and W respectively plus the first one repeated in order to close the polygon. Please note that the control points have to be consecutive, i.e., it must be possible to generate the polygon by linking the control points in the order provided.
The transformation process follows these steps:

1.
The polar coordinates of the point with respect to the projection point in Z are computed.

2.
We determine the region from the domain in Z in which the point is located. In that regard, each region is defined by the triangle formed between the projection point and two consecutive control points in Z. This is done using the polar angle boundaries of the region.

3.
We compute the distance from the projection point in Z to the intersection between the straight line passing through the projection point and the point to transform, and the boundary of the domain in Z. This provides the value r b .

4.
We determine the transformed region in W. This is done knowing that the control points {p a (j), p b (j)}, are the transformed versions of {q x (j), q y (j)} in their respective spaces.

5.
A linear interpolation in the polar angle is performed between the original point and the angle boundaries of the regions in which the point is located. This step provides the polar angle ϕ.

6.
We compute the distance between the projection point in W and the intersection between the straight line with angle ϕ passing through the projection point, and the boundary of the domain in W. This provides the value d b .

7.
The distance of the transformed point to its projection point d is obtained by applying the relation seen in Equation (6).
A more in detail description of the operations required to transform {a, b} into {x, y} is presented in Algorithm 1. On the other hand, the inverse transformation is equivalent to the process presented so we do not repeat it in here. Finally, it is important to note that since the transformations used in the projection mapping are in fact linear transformations, the transformation is always bijective if the condition about the definition of the projection point with respect to the boundary is met.
As an example of this method, Figure 3 (right) presents the result of applying the transformation (direct and inverse) to the control points provided by Table 1 and the projecting points c = {0, 0} and υ = {0, 0}. As it can be seen, the polynomial in W resembles a "T" shape, where each consecutive pair of control points generates a region where the transformation is continuous and differentiable. However, at the boundaries between regions the transformation stops to be differentiable, although it maintains the property of continuity.

Multiple-Point Projection Mapping
There are cases in which it is not possible to generate a function d b (ϕ) = g(ϕ) as in the previous case due to the shape of the domain in W. This happens for instance when the domain boundary cannot be represented as a function in polar coordinates from the projection point. Nevertheless, in these situations it is possible to solve this problem using a set of projection points instead of just one; however, some considerations regarding the continuity of the transformation must to be taken into account first. In that regard, and as a first approach to deal with this situation, we could think on finding the smallest number of projection points required to cover the whole domain. This represents in effect the so-called "art gallery problem". The "art gallery problem" (known also as the museum problem) is a problem in computational geometry providing the solution for the minimum number of required points to cover the complete domain. Its name comes from the real-world problem of placing the minimum number of guards in an art gallery such that, all together, can observe the whole gallery. This problem was first solved by Chvátal in 1975 [17], but Fisk, in 1978, provided such a brilliant and short proof [18] that Paul Erdős decided to include it in "The BOOK", an imaginary book in which God keeps the most elegant proof of each mathematical theorem. This book was then published after Erdős dead [19]. The solution to this problem states that ⌊n/3⌋ guards are always sufficient and (sometimes) necessary to guard a simple polygon with n vertices. In general these points are in the boundary of the polygon and thus, although the theorem is interesting, it is not really practical for most applications since it distributes points more densely in the boundaries of the domain in W rather than obtaining a more uniform distribution of points.
Therefore, instead of focusing on identifying the smallest number of projection points required, in this work we deal with the problem on how to separate both domains (in Z and W) in a set of regions, one for each projecting point, in such a way that the property of continuity is preserved through the transformation. Once these regions are defined, we proceed as in the case of single-point projection mapping. Please note that by doing that, each time that a point is transformed, the method requires to determine the region, from the ones defined, to which it belongs. This can be done, for instance, by using the transformation for each of these regions checking if the point is inside the region in the Z space.
Let δΩ be the boundary in W of a given domain. Then, connecting with a line two points in δΩ implies connecting two points in the boundary of Z since during the transformation the boundary in one space transforms into the boundary on the other space. For instance, from Figure 4, if we select the points A and B from W, we know that both points belong to the boundary in Z and also, both points can be connected through a curve in Z and W. Then, if we use just straight lines as curves, this means that A and B in Z must be in a different side of the square boundary in order to define a region of area different to zero. The same can be said with the points C and D. Following this procedure, it is possible to generate four regions in which each projection point can cover completely its own region. At this point, it is important to note that the boundary between regions 1 and 4 is the curve between A and B in both spaces. In the same way, regions 3 and 4 have a boundary in the curve between A and C, while in regions 2 and 4 the boundary in common is defined by the curve between B and D. This means that since the transformation is continuous inside the regions and at the boundaries of these regions, then, the whole transformation is continuous in the whole domain. This process can be continued even using the boundaries between these defined regions. This means that, for instance, if region 4 is split in half vertically, a point in the curve between A and B will be part of the new boundary created between regions 4' and 4", while another point in the boundary should be in δΩ between C and D.
To present an example of application for the case of multiple projection points, we apply this methodology to the "C" and "I" beam transformations shown in Figure 3. To that end, we know that for these cases we can cover all the domain with two projection points. Moreover, and since both figures are symmetric with respect b = 0 and y = 0 respectively, we use this line as the boundary between the two regions in which to apply Algorithm 1. In particular, for the case of the "C" beam shape, we define the control points for the two defined regions in Table 2, where the projecting points used are c 1 = {0, 0.5}, c 1 = {0, −0.5}, υ 1 = {0, 3i}, and υ 2 {0, = −3i}. Figure 3 shows the result of the transformation.

Maintaining the Density of Points during the Transformation
In some applications it is of interest to maintain the density of points through the transformation between W and Z. This can be achieved easily using the projection mapping Mortari   Let n be the number of uniformly distributed points in W that are inside the problem domain of area A. Let n p be the number of points in a given region in W of area A w that is defined by two consecutive control points and the projection point. Then, since the points are uniformly distributed: n p /n = A w /A. This argument can be also applied to the square domain in Z leading to: n p /n = A z /A s where A z is the area defined by the transformed control points and the projection point in Z, and A s is the area of the square. This means that, since n p /n is a fixed value in the transformation, we have to impose that A z = A s A w /A in order to maintain the density of points. In other words, the proportion of the area of each region with respect to the area of the domain must be equal in both domains. Therefore, it is possible to select the two control points in the boundary of Z in such a way that this area is maintained. For instance, if the area of a given region in W is 10% of the domain area, and one of the control points in Z was already in the position {1, 0}, this means that the second control point for that region should be {1, 0.8}. It is important to note that in general, these new control points will coincide with the corners of the square, and thus, additional control points in the square (and their transformed equivalents in W) must be generated in order to define completely the domain in Z.

Merging a Sequence of Boundary Functions into a Single Function
The strength of the projection mapping consists of providing the direct and inverse transformations with the same formalism and with no approximation. This section solves a problem arising from the application of the projection mapping when mapping the boundaries of the W-domain back to the Z-domain. This may create a sequence of functions with no C 1 continuity. This problem appears, for instance, when we perform a transformation between polygons with different number of sides. As a result of that, the continuity is lost for Newmann constraints. Because of this, there is the need for representing a sequence of functions by a single boundary function, as required by the TFC framework.
In this subsection using the Heaviside step function, we show how to replace, with no approximation, a set of n contiguous piece-wise functions by a single function that can be used in the TFC framework. In particular, no C 0 continuity is also considered as it can be generated by imposing Newmann boundary constraints in the Wdomain.
Consider, for example, the boundary constraints described by the following set of four piecewise functions, each defined in contiguous ranges, This piece-wise function is shown in the top plot of Figure 5; while the equivalent single function, f (x), which is derived by the general equation, (9) applied for n = 4 piece-wise functions, is shown at the bottom plot of Figure 5. In particular, this example includes, C 0 continuity (black marker) at x 2 = −1/2, discontinuity (blue dashed line) at x 3 = 0, and C 0 and C 1 continuity (red marker) at x 2 = 1/2.
The function, f (x), computed using Equation (9) can be used, for instance, to describe a boundary constraint at y = −1 in the 2-dimensional TFC matrix formulation [2,3], f(x, y, g(x, y)) = g(x, y) + v T (x)[ℳ(f(x)) − ℳ(g(x, y))]v(y) (10) where the matrix tensor is simply, (11) and the switching vectors are, v(x) = 1 and v(y) = 1 2 2 1 − y (12) Therefore, the TFC functional is, f(x, y, g(x, y)) = g(x, y) The single function, f (x), can be used in the TFC framework to represent a boundary constraint. Figure 6 shows two TFC surfaces using the single constraint boundary function, f (x), shown in red and for two different expressions of the free functions: g(x, y) = 0 (left figure, most simple interpolating surface) and g(x) = sin(5 x) e x cos(5 x) (right figure).

Polynomial Mapping
The polynomial mapping presented in this section is a well known mapping between two real domains. This mapping is performed using a set of n polynomial (switching) functions and a set of n boundary (control) points in the Z and W domains. While the proposed mapping can be applied to any dimensional domains, to be consistent with the complex conformal mapping, the analysis is here restricted to the bi-variate domains only.
Let the boundaries of two domains, Z and W, be identified by the following sequence of n control points, z k = a k b k and w k = x k y k where k ∈ 1, …, n (14) then, the direct mapping is provided by, Mortari and Arnas Page 13 Mathematics (Basel). Author manuscript; available in PMC 2020 October 13.
is also linear. This is shown in Figure 7, where the direct mapping of a grid of points on the Z-domain (small black dots, left plot) are mapped to the W-domain (red cicles, right plot) and then mapped back to the Z-domain (red cicles, left plot).
Please note that in the polynomial mapping the linearity holds in all the cases when the number of control points is equal to the dimensions of the mapping domain plus one. However, in the more interesting general case, when the number of control points is greater, then the mapping becomes nonlinear, with no closed-form inverse mapping expression. However, the mapping becomes more flexible to describe complex domains. This is shown in the next subsection where the domain is identified by four points.

4-Points Polynomial Mapping
The polynomial mapping using n = 4 points on bi-variate domains (quadrangular polygons) is nonlinear. However, an inverse mapping is still possible to derive, as shown in Section 4.2. This means that this non-linear mapping is bijective. Since this mapping transform lines to lines, the generic polygon side can be obtained simply by, w ij (t) = w i + t w j − w i where t ∈ [0, + 1]

4-Points Inverse Mapping
The inverse mapping, (x, y) → (a, b), can be obtained using the four boundary lines, w 12 t 1 = w 1 + t 1 w 2 − w 1 w 43 t 1 = w 4 + t 1 w 3 − w 4 and w 14 t 2 = w 1 + t 2 w 4 − w 1 w 23 t 2 = w 2 + t 2 w 3 − w 2 to obtain the two lines passing through the point (x, y), which can be written as, Setting, allows to write the solution in terms of a quadratic equation, Please note that if C x3 C y2 = C x2 C y3 , i.e., when A = 0, the problem becomes linear. For instance, if C x3 = C y3 = 0, then the solution is simply provided by, As it can be easily verified, this degeneration to a linear problem occurs when the W-domain is rectangular and rotated by any angle.

8-Points Polynomial Mapping
Constrained expressions for cubic quadrangular domains can be obtained by mapping the domain (a, b) ∈ (−1, 1) × (−1, 1) unit-square domain to a cubic quadrangular domain (x, y), where each quadrangular side is identified by three points. This non-linear mapping is given by, x k f k (a, b) and y = ∑ where the cubic polynomials functions f k , (a, b) are the switching (f i (a j , b j ) = d ij ) functions, The quadrangular boundaries can be obtained by setting a = ±1 and b = ±1, respectively.
Mortari and Arnas Page 16 Mathematics (Basel). Author manuscript; available in PMC 2020 October 13. Unfortunately, the inverse of the polynomials mapping using 8 points has not been found. Because of this, the following section provides a least-squares procedure to estimate an approximated inverse mapping for the 8 (or more) points polynomial mapping as well as for complex conformal mapping with no inverse mapping.

Approximate Least-Squares Inverse Mapping
Inverse mappings always exist for the projection mapping, only. In fact and in general, complex and polynomial mappings do not admit closed-form inverse. However, when the direct mapping considered is bijective, then an approximated least-squares inverse mapping is proposed in this section. The inverse mapping is needed because the existing TFC methodology has been developed for any dimensional space and for a wide set of constraint types, but for rectangular domains, only. Therefore, in order to apply the TFC framework to generic domains, an inverse mapping function is required to map the problem domain into the Z rectangular domain where to apply the TFC framework.
To that end, a least-squares approximate inverse mapping is proposed as a linear combination of orthogonal polynomials, z = ξ k ψ k (w) (27) where ψ k (w) is the k-th orthogonal polynomial and where z and w are the complex coordinates that can be used, for real mapping, as z = a + i b and w = x + i y.
Let z be the vector of N discretized points (e.g., grid or uniformly distributed) in the Z domain and w = f (z) be the direct mapping. Then, Equation (27) can be specified for all the points and a least-squares solution of the unknown coefficients vector, ξ, can be estimated. It is important to outline that before applying this least-squares approach, translation and scaling might be necessary to contain all the w points in a scaled domain in which the polynomial basis functions are defined as, for instance, in the [−1, +1] range for Legendre or Chebyshev orthogonal polynomials. Figure 10 shows the accuracy results for the proposed approximate inverse mapping using the least-squares estimate. In this example, the same control points defined in Equation (4)  To numerically validate the accuracy of this approximated inverse mapping, 100,000 Monte Carlo tests were made with (uniformly distributed) random points in the Z domain. The histogram of the error, z i − z i is shown in the right figure. The mean error, μ = 8.6464 × 10 −6 , and 3σ = 4.0756 × 10 −5 error can be considered pretty good for most of the accuracy requirements in practical applications. Please note that the approximate inverse transformation must be computed just once.
Also, various distributions of points can be selected by embedding the W domain into a slightly larger rectangular domain. A grid distribution of points can be easily obtained for any convex W domains and, using a more complex algorithm, for non-convex domains. Note also that, in general, the bijection property of the transformation has to be checked for each particular mapping defined. This is due to the impossibility to derive a general proof for all possible transformations that can be generated using these approaches. Figure 11 shows, for 57, 162, 488, and 1453 points, respectively, the selection of grid of points for the top-center domain shown in Figure 2. Using a simple algorithm it is possible to obtain collocation-type of points. This is show in the bottom plots of Figure 11 using the same number of points.

Rectangular Domain
This section summarizes, step-by-step, how to derive a constrained expression in the W domain using the direct mapping function, w = f (z). In this section, z and w indicate either, the complex or the (z ≡ [a, b] and w ≡ [x, y]) real coordinates in the Z and W domains.

1.
The W domain (or subdomain, as those shown in Figure 4) is identified by four boundaries, c i (w) = 0, along which the Dirichlet constraints are defined by the four functions, υ i (w).

2.
A set of N g grid (or collocation-type) points within the W domain, w k , is computed (see Figure 11),

3.
If the inverse function, z = f −1 (w), is available (as, for instance, when using the projection mapping or an invertible complex mapping) then the w k points are mapped back to the Z domain, z k = f −1 (w k ). In the case the inverse mapping function is not available, then a least-squares approximated inverse function, (w), can be derived as described in Section 5.

4.
A set of points, w b , belonging to the boundary, c i (w b ) = 0, are computed. At these points/coordinates the Dirichlet constraint has value υ i (w b ).

5.
Using the inverse (or the approximated inverse) mapping function, z b = f −1 (w b ), the boundary coordinates in the Z domain are computed. At these corresponding points the constraint values are υ i (w b ).

6.
The boundary constraints in the Z domain are obtained by interpolating the points [z b , υ i (w b )] and using a constrained expression to guarantee the continuity at the four corners, as explained in [1].

7.
A Coons patch [20] is then used to obtain the simplest interpolating surface satisfying the Dirichlet boundary constraints in the Z domain. This means obtaining the surface, S c (z), providing the value at coordinate z.

8.
A grid of points of the S c (z) surface is then mapped to the W domain, w c = f (z c )

9.
Finally, the TFC functional in the W domain is then given by, S(w, g(w)) = S c f −1 (w) + g(w) ∏ i = 1 4 c i (w) (28) Figure 12 presents an example using the W domain shown in the top-center of Figure 10 and defined by Equation (26). To guarantee continuity at the W-domain corners, the four boundary functions, c i (x, y) = 0, were derived using the surface, V (x, y) = sin(π(x − y)/6) + cos(π(x − y)/5) + 2 This means that the equations, c i (x, y) = 0, describing the boundaries of the W-domain defined by Equation (26) were used to derive the boundary constraints using the V(x, y) surface. For this specific case, g(x, y) = 0, was used as free function.

Conclusions
This study consists of an initial investigation on how to apply the Theory of Functional Connections, which was developed for rectangular domains in any dimensional space, to generic domains in 2-dimensional spaces. This has been done by three distinct approaches: (1) complex (conformal) mapping, (2) projection mapping, and (3) polynomial mapping.
Discussions and examples are provided to highlight the features of each one of these three mappings, such as, conformal property, invertible property, or flexibility to describe different domains.
For the cases of bijective mappings where no analytical inversion is known, such as for some complex mapping and for the polynomial mapping, a method to derive least-squares approximate inverse mapping is provided. In addition, this study also describes how to replace constraint boundaries defined by a sequence of different functions by a single equation. This is required to derive a Coons patch in the Z domain.
This manuscript represents the first generalization of the Theory of Functional Connections for non rectangular domains. As such, there is additional research to be performed to better clarify details and to extend the methodology even more and to study its potential applications. For instance, given a generic W domain (typically, polygonal or circular) of a real application, it would be interesting to derive a general methodology to obtain the mapping that approximates the W domain boundaries by least-squares or by some other optimization techniques. Another possible future research includes the study of optimization techniques to search for the free function, g(w), which allows describing the set of four Dirichlet boundary constraints.
In other word, this incomplete study has the purpose to initiate the extension of the Theory of Functional Connections to non-rectangular domains.

Funding:
This research was funded by NASA, grant #: 80NSSC19K1149.

PDE
Partial Differential Equation

TFC
Theory of Functional Connections Example of the surfaces in the Z-domain (left) and in the W-domain (right). Mortari  Control points for the "T" beam shape transformation.