## 2 Materials and Methods
### Gaussian Process Modeling  
In the study, we employ mask projection stereolithography technique as a model AM process [15,16]. The layer-by-layer nature of the process inevitably yields a staircase sidewall profile of the part, leading to geometric difference between the manufactured part and the planned geometry (or the 3D computer model). Furthermore, when high-aspect-ratio structures, such as thin struts or beams, are manufactured, the geometric difference can also be affected by the angle between the substrate and the strut [26]. This problem is universal and found in most AM processes. In order to quantify the deviation, we consider the sidewall profiles of the AM part captured using a digital camera attached to a microscope. We assume that the extracted edge roughness profiles of AM parts result from the following two parts: (1) **staircase profile**: consistent curing behavior from the printing apparatus (consistent deviation between the planned geometry and actual printed geometry) and (2) **spatial uncertainty** (small variations): stochastic roughness variations from the AM process arising from inherent uncertainties, such as light scattering, mask projection not perfectly focused on the curing plane, perturbation on the liquid resin surface, and uncontrolled external environmental factors including fluctuations of temperature or oxygen level. After separating the effects from both the aforementioned factors, we focus on the second part, namely the spatially varying stochastic roughness uncertainty that is not a function of the printed angle. Spatial uncertainty is often represented by a random process that is defined as a collection of random variables in space or time. In the study, we assume that the random process behind the spatial roughness uncertainty is represented by a Gaussian process [27]. The advantage of using a Gaussian process is that the random process is fully described by the mean and covariance functions, and thus it is possible to obtain the full probabilistic prediction as well as the estimation of uncertainty in the prediction. We define the spatial uncertainty in the sidewall profile as the roughness \(d\) and assume that this uncertainty is the realization of a Gaussian process (\(\
ot{f}\)). The Gaussian process is a statistical model that produces a set of random variables; and the finite selection of the random values within the set follows a multivariate Gaussian distribution [27]. The Gaussian process is fully described in terms of its mean \(M\) and covariance \(C\), and its realization is also fully specified by \(M(X)\) and \(C(X,X)\) in which \(X\) denotes the domain of the realization [28]. The stationary Gaussian process model for roughness spatial uncertainty is defined as follows:  
\[ \begin{gathered} f|M,C\sim GP(M,C),\\ d|M,C\sim N(M(X),C(X,X)),\\ M:X,\alpha,t_{M}\rightarrow\sum_{i}\alpha_{i}B_{i,k}(X;t_{M}),\\ C:X,X^{\prime},\
u,\phi,\theta\rightarrow\mathit{Matern}(X,X^{ \prime},\
u,\phi,\theta),\end{gathered}  \tag{5}\]  
where \(GP\) and \(N\) stand for the Gaussian process and normal distribution, respectively. \(B_{i,k}\) denotes the B-spline basis function of order \(k\), \(\alpha_{i}\) denotes the corresponding weight factor at \(i^{\text{th}}\) location, and \(t_{M}\) denotes the knot vector for the mean function [29]. The B-spline representation is used as the mean function to model the local variability in roughness. This is especially useful when the shape of the mean function is not known a priori. The Matern covariance is used because it represents a diverse class of covariance functions that belong to the exponential family, which is commonly used to model physical stochastic processes [27]. The Matern covariance includes three hyperparameters, namely \(\
u,\phi\), and \(\theta\) that control its differentiability, correlation length, and amplitude, respectively. In order to determine the stationary Gaussian process properly, we applied the Bayesian inference approach to estimate the probability density functions (PDFs) of unknown parameters.