Non-injective gas sensor arrays: identifying undetectable composition changes

Metal-organic frameworks (MOFs) are nanoporous materials with good prospects as recognition elements for gas sensors owing to their adsorptive sensitivity and selectivity. A gravimetric, MOF-based sensor functions by measuring the mass of gas adsorbed in a MOF. Changes in the gas composition are expected to produce detectable changes in the mass of gas adsorbed in the MOF. In practical settings, multiple components of the gas adsorb into the MOF and contribute to the sensor response. As a result, there are typically many distinct gas compositions that produce the same single-sensor response. The response vector of a gas sensor array places multiple constraints on the gas composition. Still, if the number of degrees of freedom in the gas composition is greater than the number of MOFs in the sensor array, the map from gas compositions to response vectors will be non-injective (many-to-one). Here, we outline a mathematical method to determine undetectable changes in gas composition to which non-injective gas sensor arrays are unresponsive. This is important for understanding their limitations and vulnerabilities. We focus on gravimetric, MOF-based gas sensor arrays. Our method relies on a mixed-gas adsorption model in the MOFs comprising the sensor array, which gives the mass of gas adsorbed in each MOF as a function of the gas composition. The singular value decomposition of the Jacobian matrix of the adsorption model uncovers (i) the unresponsive directions and (ii) the responsive directions, ranked by sensitivity, in gas composition space. We illustrate the identification of unresponsive subspaces and ranked responsive directions for gas sensor arrays based on Co-MOF-74 and HKUST-1 aimed at quantitative sensing of CH4/N2/CO2/C2H6 mixtures relevant to natural gas sensing.


Introduction
Gas sensors [1] have a wide range of applications in the chemical industry and in emerging domains such as air quality monitoring [2], diagnosis of disease [3], food quality assessment [4], detection of chemical warfare agents and explosives [5,6], and crop monitoring [7].
Metal-organic frameworks (MOFs) [8] are nanoporous materials with high prospects as recognition elements for enhanced gas sensors [9][10][11][12] owing to their adsorptive sensitivity and selectivity. More, many MOFs exhibit chemical, thermal, and mechanical stability, making them suitable for sensing in practical conditions [13,14]. MOFs offer large  [25] (the recognition element), in this case HKUST-1 [37], mounted on a QCM [24,38] (the signal transducer). The QCM measures the (total) adsorbed mass of gas, m, in the thin film of MOF. The QCM-MOF functions as a sensor because changes in the gas composition are expected to cause changes in m.
internal surface areas and, often, expose functional groups and open metal sites to the pore space. As a result, gas molecules concentrate inside the pores of the MOF by (selectively) adsorbing onto the pore walls. The amount of gas adsorbed in a MOF at thermodynamic equilibrium depends upon the chemical potential of each component in the gas phase (and the temperature). Therefore, observation of the total mass of gas adsorbed in a MOF [15]-or some other property that depends on the gas adsorbed in the MOF, such as electrical resistance [16,17], color [18], luminescence [19,20], or strain [21,22]-provides information about the composition of the gas. Figure 1 illustrates a miniaturized gravimetric, MOF-based sensor composed of a quartz crystal microbalance (QCM) coated with a thin film of MOF [23,24]-a surface-mounted MOF [25]. Nanogram-scale changes in the adsorbed mass of gas in the MOF film can be inferred from changes in the resonant frequency of the piezoelectric quartz crystal, forced by an alternating voltage [9,10]. Several gravimetric, MOF-based sensors have been experimentally demonstrated using QCMs [15,[26][27][28][29][30][31][32] and surface acoustic wave devices [33][34][35] as electromechanical signal transducers [36].
Cross-sensitivity plagues gas sensors in practical applications where the gas contains multiple components that vary in concentration [39]. In the case of MOF-based gas sensors, interfering gas species, in addition to the analyte species, adsorb into the MOF and contribute to the response (i.e. the total adsorbed mass of gas). As a consequence, the inverse problem [40] of inferring the concentration of the analyte from a single-sensor response is underdetermined [41]. To address the problem of cross-sensitivity, one might propose to design a MOF with a very high adsorptive selectivity for the analyte. However, this strategy may be difficult or impossible, and it requires a different MOF highly tailored to each sensing task.
Gas sensor arrays tackle the issue of cross-sensitivity by monitoring the response of a diverse set of (likely, crosssensitive) MOFs [42,43], analogous to the mammalian olfactory system (MOFs :: olfactory receptors) [44]. Each response of a cross-sensitive MOF, though having contributions from the analyte and interferents, places one constraint on the gas composition. As a whole, the response vector of the gas sensor array may provide sufficient information to uniquely determine the gas composition. Typically, a machine learning algorithm is used to parse the high-dimensional response of a sensor array [45]. A few MOF-based gas sensor arrays have been experimentally demonstrated [16,29,[46][47][48]. Still, even gas sensor arrays are susceptible to cross-sensitivity; the inverse problem (determine the gas composition from the sensor array response vector) could still be underdetermined-particularly, if the number of MOFs comprising the array is less than the number of degrees of freedom in the gas composition. In an environment with complex, multicomponent gas mixtures, if the sensor array contains too few MOFs, the information contained in its response is insufficent to fully constrain the gas composition.
In this article, we outline a mathematical method to identify changes in the gas composition to which reversible 6 , quantitative gas sensors/sensor arrays are unresponsive. Gas sensing can be viewed as the inverse problem of finding the gas composition consistent with the sensor response governed by a mixed-gas adsorption model [40]. Owing to cross-sensitivity, the mapping, under the adsorption model, from gas composition space to sensor array response space could be noninjective (many-to-one). Consequently, some gas composition changes are undetectable. By definition, when the gas composition changes in an unresponsive direction in composition space, the sensor response remains constant; the explanation is that the adsorption of one set of species balances (in mass) the desorption of another set of species. These undetectable gas composition changes generally depend upon the initial composition. The identification of unresponsive directions of gas sensors/sensor arrays is important for understanding their limitations and vulnerabilities to adversarial attacks [49].
Specifically, we show that the singular value decomposition (SVD) of the Jacobian matrix of the mapping from gas composition vectors to sensor response vectors is key to determining unresponsive directions and responsive directions, ranked by sensitivity, in composition space. In particular, the unresponsive subspace is the null space of the Jacobian matrix. We illustrate this under the context of quantitative sensing for diluents and higher-hydrocarbons in natural gas [50] (N 2 , CO 2 , and C 2 H 6 in CH 4 ) using gravimetric, MOF-based sensors comprised of HKUST-1 and Co-MOF-74. We use experimental gas adsorption data and ideal adsorbed solution theory [51,52] to model the mass of adsorbed gas in each MOF in response to different gas compositions. Under several case studies, we visualize the unresponsive subspace and ranked responsive directions together with the underlying mixed gas adsorption model.
Several computational and mathematical modeling approaches have been developed to design/analyze gas sensor 6 Gas sensors based on physical adsorption in stable MOFs lacking adsorption/desorption hysteresis are reversible. Suppose the gas composition changes from (i) a reference composition to (ii) some new composition, then (iii) back to the reference composition. The equilibrium mass of gas adsorbed in the MOF will be the same in (i) and (iii).  [40,41,[53][54][55][56][57]. Our work focuses on identifying the limitations of non-injective, MOF-based gas sensor arrays by elucidating directions in composition space in which the gas sensor is unresponsive to changes.

Problem setup
Suppose a gravimetric sensor array of M MOFs aims to determine the composition of a gas (temperature, pressure fixed) with G + 1 components. Table 1 summarizes our notation. The gas composition vector. Let x ∈ R G be the gas composition vector, with x i the mole fraction of component i in the gas phase. We omit component G + 1 of the gas from x since its mole fraction follows from x G+1 = 1 − (x 1 + x 2 + · · · + x G ). Thus, the only constraints on x are G i=1 x i 1 and x 0. We define this subset of R G as gas composition space X , so that x ∈ X . We assume the gas is held at constant pressure and temperature, implying (i) x fully specifies the thermodynamic state of the gas phase and (ii) G is the number of degrees of freedom in the gas phase.
The sensor response vector. Let m ∈ R M be the sensor array response vector, with m i (g gas/g MOF) denoting the total mass of gas adsorbed in MOF i at thermodynamic equilibrium, normalized by the mass of MOF in the sensor. We assume, as in practice, that each MOF is cross-sensitive. As a result, m i is comprised of contributions from each of the G + 1 components of the gas phase.
The adsorption function. Mathematically, we view gas sensor arrays as mapping from gas composition space X to sensor response space M ⊂ R M [41,58]. The adsorption function a : x → m maps each gas composition vector x ∈ X to a sensor response vector m ∈ M. I.e. m = a(x) is a model for the total mass of gas adsorbed in each MOF (at thermodynamic equilibrium) as a function of the gas composition. We assume a(x) is a continuously differentiable function, disallowing adsorption/desorption hysteresis, gas-induced first-order structural transitions, and condensation of adsorbates in the pores. We also disallow chemical transformations in the MOF. The sensor response space M = a(X ) is then the image of gas composition space under the adsorption model.
A model of the adsorption function a(x) could be constructed from adsorption data , with n the number of experiments exposing the sensor array to a gas mixture to observe its response, through various methods including: • interpolation of D.
• A statistical mechanical model of gas adsorption [59] whose parameters are identified using D. • A statistical machine learning model trained on D.
The source of D could be experimental gas adsorption measurements or molecular simulations of gas adsorption [60,61] in the MOFs.
While we write the adsorption function a(x) as a vectorvalued function, the mass of gas adsorbed in each MOF is independent. In other words, we can independently build the adsorption model for each MOF i in the array, m i = a i (x).
Gas sensing as an inverse problem [40]. The forward problem is to predict the response of the sensor array m given the gas composition x. The solution is to evaluate the adsorption model m = a(x). The inverse problem arises in gas sensing: we wish to predict the gas composition x given the sensor response m using the adsorption model m = a(x). While the forward problem always has a unique solution, the inverse problem may have a unique solution, no solution, or many solutions.

Non-injective gas sensor arrays with underdetermined inverse problems
In this work, we consider gas sensor arrays comprised of fewer MOFs than degrees of freedom in the gas composition (M < G). The mapping a : x → m under a sensor array with M < G is generally non-injective (many-to-one). Consequently, the inverse problem of determining the gas composition x from the sensor response m is underdetermined; typically, many gas compositions can produce the observed response. In the inverse problem, observation of each MOF's response, generally, provides one independent constraint, m i = a i (x), on the gas composition. For M < G, the response of the sensor array places an insufficient number of constraints on the gas composition to uniquely determine it.
As a result of their (view 1) non-injective mapping a : x → m and (view 2) underdetermined inverse problems, gas sensor arrays with fewer MOFs than degrees of freedom in the gas (M < G) suffer from unresponsiveness to some changes in gas composition: despite a change in composition, the sensor response remains constant, and hence the composition change goes undetected.

Unresponsive and ranked responsive directions of non-injective gas sensors
Non-injective gas sensors contain fewer MOFs than degrees of freedom in the gas composition. They are vulnerable to blindness: the sensor is unresponsive to certain gas composition changes. Our work focuses on identifying these vulnerabilities in non-injective gas sensors. Moreover, the sensor is more sensitive to certain gas composition changes than others (of the same magnitude). We show that the SVD of the Jacobian matrix of the adsorption function a(x) is key to identifying directions in composition space to which the sensor is most-, least-, and un-responsive.

The operating point x op as a reference
We will define unresponsive and ranked responsive directions in reference to some steady-state, reference gas composition, or operating point x op ∈ X . m op := a(x op ) is the sensor response at this operating point.

The unresponsive locus B
The unresponsive locus B ⊂ X associated with an operating point x op is the set of gas compositions such that the sensor response remains constant at m op : The unresponsive locus is an intersection of the level sets of the adsorption functions for each MOF in the sensor array, By definition, the sensor array cannot distinguish between gas compositions in the unresponsive locus. A change in the gas composition from x op ∈ B to x ∈ B is undetectable despite x = x op . Fundamentally, the response of a sensor array composed of cross-sensitive MOFs remains constant under the composition change from x op to x because the adsorption of one set of species balances (in mass) the desorption of another set of species (see figure 2). A physically trivial example of a mathematically non-trivial unresponsive locus is when all MOFs do not adsorb a particular component of the gas.

Linear approximation of a(x) near the operating point x op
Let us make a linear approximationã(x) of the adsorption function a(x) valid near the operating point x op . A first-order Taylor expansion of a(x) about x op gives: For a non-injective gas sensor array (M < G), J is fat. From a geometric viewpoint, the approximator m i ≈ã i (x) is a hyperplane tangent to the surface a i (x) and passing through m i,op .

The (local) unresponsive subspace of composition space
We define the (locally valid) unresponsive subspaceB ⊂ R G of a sensor array associated with operating point x op as the directions in composition space such that, for small changes in the gas composition in these directions, the sensor response remains approximately constant at m op . Thus, for a unit vector Δx ∈B, a(x op + Δx) ≈ a(x op ) with a small number. Invoking the linear approximation in equation (2), the local unresponsive subspace is given by the null space of the Jacobian matrix J(x op ): The null space of J will be non-trivial provided G > M.
I.e, sensor arrays such that M < G possess non-trivial unresponsive subspaces because the mappingã : x → m is noninjective.

The sensitive direction in composition space
The sensor response is most sensitive to gas composition changes in the direction of: Of all gas composition changes Δx from x op that are small ( > 0) in magnitude, those in the sensitive direction of Δx s elicit the largest-magnitude change in the response of the sensor array.

The singular value decomposition (SVD) of J.
The SVD [62,63] of the M × G Jacobian matrix J factorizes it as:  Illustrating a gas composition change to which a non-injective, gravimetric, MOF-based gas sensor is unresponsive. A single QCM-HKUST-1 sensor is immersed in a gas mixture of two different compositions: on the left, a dominantly CH 4 /C 2 H 6 mixture; on the right, a dominantly CH 4 /CO 2 mixture. The response of the sensor to the two distinct gas compositions is identical; hence, the sensor cannot be used to distinguish between these two compositions. The total mass of gas adsorbed in the HKUST-1 film remains the same upon changing from the ∼ CH 4 /C 2 H 6 to ∼ CH 4 /CO 2 mixture because the desorption of C 2 H 6 approximately balances (in mass) the adsorption of CO 2 , while the adsorption of CH 4 remains approximately constant.
extremely likely that J is full-rank (rank M) 8 , so we assume σ M > 0. Seen by JV = UΣ: Therefore, under the linear approximationã(x) in equation (2), the sensor array is: • responsive to gas composition changes in directions belonging to the subspace spanned by the first M right singular vectors (v 1 , v 2 , . . . , v M ). This list of vectors is ranked by the magnitude of the associated sensor array responses. • Unresponsive to gas composition changes in directions belonging to the subspace spanned by the set of last This subspace is the null space of J. Hence, • the sensitive direction of the gas sensor array, Δx s in equation (5), is described by the first right singular vector v 1 of the Jacobian matrix J. The gas sensor array is responsive, but less sensitive, to composition changes in the subspace spanned by We emphasize that the sensitive and unresponsive directions (i) depend on the operating gas composition x op and (ii) pertain to small changes in the gas composition since they rely on the linear approximation in equation (2) of the generally nonlinear function a(x).
We remark on the uniqueness of the SVD in equation (6). The singular values are unique. The left and right singular vectors associated with the distinct, non-zero singular values 8 J could, however, be ill-conditioned [40]. are unique, up to both corresponding vectors being multiplied by −1. The right singular vectors spanning the null space are much more arbitrary in the sense that they can be any orthonormal basis for the null space.
Note, if the response vector is recorded in units g gas instead of g gas/g MOF, (i) the responsive and unresponsive subspaces do not change, but (ii) the ranked responsive directions that span the responsive subspace do change if different masses of MOF are used in each sensor.

Special case: linear adsorption model
Suppose gas adsorption in each MOF of the array is described by Henry's law: with P the total pressure (bar) of the gas phase and H i, j the Henry coefficient (g gas/(g MOF-bar)) of gas j in MOF i. Imposing the constraint that the mole fractions {x j } sum to one, the adsorption model for the sensor array is linear: with Under this special case, the Jacobian matrix J = A does not depend on a reference gas composition x op . Therefore, the unresponsive and responsive subspaces are independent of x op , too.

Summarizing with a toy example
We illustrate the identification of the unresponsive and ranked responsive directions with a toy example: a sensor array of M = 2 distinct MOFs aimed at sensing a quaternary mixture at fixed temperature and pressure (G = 3). See figure 3(a).  3-dimensional composition space, while the two orthonormal left singular vectors {u 1 , u 2 } lie in M = 2-dimensional response space. The Jacobian matrix maps the right-singular vectors into response space as follows: Provided the MOFs are distinct, the two rows of J are highly unlikely to point in exactly the same direction; thus, we safely assume J is full-rank, i.e. σ 2 > 0. Equations (10) and (11) indicate the sensor is responsive to gas composition changes in the direction of v 1 and v 2 but more sensitive to changes in the direction of v 1 (σ 1 σ 2 by definition, but likely σ 1 > σ 2 ). Equation (12) indicates the null space of the Jacobian matrix is non-trivial and spanned by v 3 . Therefore, the linear mapã : x → m is non-injective, as a consequence of M < G. Consider small gas composition changes (of magnitude > 0) from x op . The linear approximantã(x) in equation (2) maps a sphere in 3D composition space centered at x op to a solid ellipse in 2D sensor response space [62] centered at m op . See figure 3(b). This follows from equation (2) and equations (10)- (12). The composition change in the sensitive direction, v 1 (green in figure 3(b)), elicits the largest sensor response-from m op to m op + σ 1 u 1 on the endpoint of the major axis of the ellipse. The sensor is responsive, but less sensitive, to composition changes in the direction of v 2 (yellow in figure 3(b)); the composition change v 2 moves the sensor response by the vector σ 2 u 2 , placing it on the endpoint of the minor axis of the ellipse. The relative sensitivity of the  [67,71], N 2 (298 K) [70,71], CO 2 (298 K) [68,71], and C 2 H 6 (296 K) [69] adsorption isotherm data (points) in HKUST-1 and Co-MOF-74. Curves show the pure-component adsorption models fit to the data. response to composition changes in the direction of v 1 vs v 2 depends on the singular values, σ 1 vs σ 2 . On the other hand, v 3 is the unresponsive direction; the composition change v 3 (red in figure 3(b)) does not elicit a sensor response, and m remains at m op despite the change in gas composition. Using this toy sensor array, we therefore cannot detect small composition changes in the direction of v 3 !

Demonstration: natural gas sensing with gravimetric sensors based on HKUST-1 and Co-MOF-74
We now demonstrate the identification of the unresponsive subspace and ranked responsive directions in gas composition space for a gravimetric, single-MOF sensor and two-MOF sensor array for diluents and higher-hydrocarbons in natural gas [50]. Specifically, suppose the sensor (array) is immersed in a variable-composition gas mixture involving N 2 , C 2 H 6 , CO 2 , and CH 4 at 1 bar and 298 K. We consider two candidate MOFs as the recongition element(s), HKUST-1 [37] and Co-MOF-74 [64]. HKUST-1 is composed of dicopper(II) ions coordinated to benzene-1,3,5-tricarboxylate ligands to form three distinct pores, two of ∼1.4 nm and one of ∼1.0 nm in diameter [65]. Co-MOF-74 is composed of cobalt(II) ions coordinated to 2,5dihydroxyterephthalic acid ligands to form hexagonal channels of ∼1.2 nm diameter [66]. Figure 4(a) visualizes their crystal structures.
In each case study below, the number of degrees of freedom in the gas composition is greater than the number of MOFs comprising the sensor/sensor array (G > M). Thus, (i) the sensor's mapping under a from gas composition space to sensor response space is non-injective and (ii) the inverse problem to determine the gas composition from the sensor response is underdetermined. Accordingly, the sensor (array) will contain a non-trivial unresponsive subspace.

The adsorption model a(x), its Jacobian matrix J, and its SVD
We construct an adsorption model for each MOF on the basis of experimentally measured, pure-component CH 4 , CO 2 , C 2 H 6 , and N 2 adsorption data at or near 298 K. Figure 4(b) displays the adsorption isotherms and table 2 provides the references. We invoke ideal adsorbed solution theory (IAST) [51,52] and use pyIAST [72] to implement the adsorption function a(x). Section 2.1 explains that a(x) gives the total mass of gas adsorbed in each MOF (g/g) of the array as a function of the gas composition x. IAST is a thermodynamic framework to predict mixed-gas adsorption from pure-component adsorption isotherms. Figure 4(b) shows the pure-component adsorption isotherm models fit to the experimental adsorption data and used as input for IAST calculations; the single-site Langmuir, dual-site (DS) Langmuir, and quadratic adsorption isotherm models fit the data well. N.b., though we write m = a(x), IAST provides m i = a i (x) for each MOF in the array independently.
We compute the Jacobian matrix J = J(x op ) of a(x) numerically via a second-order, centered finite difference using numdifftools; we compute the SVD of J using numpy.

Case M = 1, G = 2: single-MOF sensor, ternary gas mixture
We first consider a single-MOF sensor, using either Co-MOF-74 or HKUST-1, immersed in a three-component mixture: CH 4 /N 2 /CO 2 , CH 4 /N 2 /C 2 H 6 , or CH 4 /C 2 H 6 /CO 2 at 1 bar and 298 K. Figure 5 visualizes, under these six scenarios, the adsorption function m = a(x) as well as the unresponsive v 2 (red arrow) and sensitive v 1 (green arrow) directions-given by the right singular vectors of the Jacobian matrix J(x op )-at a reference gas composition x op (black dot). The rows correspond to the three different gas mixtures; the columns correspond to the two different single-MOF sensors. Each panel displays the 2D gas composition space pertaining to the row. The colored lines are contours of the adsorption function a(x) and are labeled by the total adsorbed mass of gas m in the respective single-MOF sensor. Each map a : x → m is clearly noninjective, as an unresponsive locus of points elicits the same sensor response m. Within each panel, (i) the nonlinearity of the contours and the different areas between successive contours reflect the nonlinearity of a(x) and (ii) the slant of the contours reflects the different affinity for the MOF among the three different components of the gas.
The sensitive direction v 1 is orthogonal to the contour {x : a(x) = m op }. Among all fixed-magnitude changes in gas composition, the change in the sensitive direction will elicit the largest response (see equation (5)). The unresponsive direction is tangential to the contour {x : a(x) = m op }. The unresponsive subspace is one-dimensional owing to the single constraint imposed by the response of the sensor on the two degrees of freedom in the gas composition. For a small change in gas composition in the unresponsive direction, the sensor response remains approximately the same and, hence, the composition change is not detected by the sensor. Figure 2 illustrates the underlying physical cause of the unresponsiveness to a composition change, using as an example the HKUST-1 sensor immersed in a CH 4 /C 2 H 6 /CO 2 mixture: the desorption of one set of species balances (in mass) the adsorption of another set of species.
For the two gas mixtures involving N 2 , the sensitive direction is oriented approximately in the direction of changes in the more readily adsorbing components, CO 2 or C 2 H 6 . N 2 -MOF interactions are weaker than CO 2 -and C 2 H 6 -MOF interactions, reflected in the adsorption isotherms in figure  4(b). The CH 4 /C 2 H 6 /CO 2 mixture is most interesting, as the sensitive and unresponsive directions each have significant components in the direction of changes in CO 2 and C 2 H 6 mole fractions. Again reflected in the adsorption isotherms in figure 4(b), CO 2 -MOF and C 2 H 6 -MOF interactions are competitive.
Comparing Co-MOF-74 and HKUST-1 for CH 4 /C 2 H 6 /CO 2 sensing, the sensitive direction v 1 for HKUST-1 has a larger component along x = [0.5, 0.5] (see figure 5). Therefore, HKUST-1 is a more suitable sensor for estimating the sum of the CO 2 and C 2 H 6 mole fractions and, thus, the mole fraction of CH 4 . In other words, the component of the unresponsive direction for HKUST-1 along x = [0.5, 0.5] is smaller than for Co-MOF-74; so, HKUST-1 is not as blind as Co-MOF-74 to changes in the CH 4 mole fraction in the CH 4 /C 2 H 6 /CO 2 mixture. Figure 6 clarifies: observation of the response m op of the HKUST-1 sensor places tighter bounds on x CH 4 than observation of the response of the Co-MOF-74 sensor because x CH 4 is approximately constant along its unresponsive direction. This exemplifies how unresponsive directions and loci could be used to juxtapose two non-injective sensors. However, a more rigorous comparison of the two sensors should include sensitivity to measurement noise [40,55].    are not ranked, i.e. one is not more or less unresponsive than the other, and are not unique, in that any two orthonormal vectors that lie in the unresponsive plane can be chosen. The unresponsive subspace is two-dimensional due to the single constraint imposed by the response of the sensor on the three degrees of freedom in the gas composition. Small changes in gas composition on the unresponsive plane are undetectable since the sensor response remains constant. The sensitive direction v 1 is orthogonal to the unresponsive plane.
Comparing the sensitive directions of the two sensors at the operating point we find, for HKUST-1 and Co-MOF-74, respectively: v 1 ≈ −0.02 0.67 0.74 (14) v 1 ≈ 0.02 0.96 0.27 (15) with the gas composition vector defined as: Both sensors are much more sensitive to changes in CO 2 and C 2 H 6 than to changes in N 2 . Note the three faces of each cube in figure 7 when one mole fraction is set to zero are equivalent to figure 5.  Figure 8(b) is a visualization to understand the mapping a : x → m, with x in a 3D gas composition space and m in a 2D sensor response space. The image of the sphere of radius = 0.04 in gas composition space (blue, left) is the solid ellipse-like shape (blue, right) in sensor response space; they are (approximately, for the case of the ellipse-like shape) centered, respectively, at the reference gas composition x op and its associated response m op . Unlike the M = 2, G = 3 case in the toy sensor array figure 3(b), the image of the sphere is not exactly a solid ellipse owing to the nonlinearity of a(x).
Magnitude-changes in the gas composition in the sensitive and intermediate directions in gas composition space-changes of v 1 and v 2 , the green and yellow vectors in figure 8(b)-are mapped to the endpoints of the semimajorlike and semiminor-like axes of the ellipse-like shape-σ 1 u 1 and σ 2 u 2 , respectively. Among all magnitude-changes in the gas composition on the sphere (left), a change ∼ v 1 produces the largest-magnitude sensor array response. The sensor array is responsive to, but with reduced sensitivity, small changes in the intermediate direction v 2 . On the other hand, the sensor array is unresponsive to small changes in the gas composition in the unresponsive direction of v 3 . The unresponsive subspace is one dimensional here because the response of the two MOFs places two constraints on the three degrees of freedom in the gas composition.

Non-injective gas sensor arrays are not useless
The inverse problem [40] of predicting the gas composition x from the response vector m of a non-injective gas sensor array typically has infinite solutions, meaning that infinitely many gas compositions are consistent with the response. We therefore cannot make a unique prediction of the gas composition without imposing further assumptions. Despite this, non-injective gas sensor arrays could still be practically useful.
First, the response of a non-injective sensor array places potentially useful constraints on the gas composition. For example, consider the single HKUST-1 sensor in figure 5. The response under CH 4 /CO 2 /N 2 mixtures places tight bounds on the mole fraction of CO 2 in the mixture. On the other hand, the response under CH 4 /CO 2 /C 2 H 6 mixtures cannot delineate between dominantly CH 4 /CO 2 and CH 4 /C 2 H 6 mixtures (see figure 2). Nevertheless, the response does place tight bounds on the sum of the CO 2 and C 2 H 6 mole fractions and, hence, the CH 4 mole fraction (see figure 6). This tight bound on x CH 4 could be very useful and sufficient for certain applications.
Second, imposing additional assumptions about the gas composition can grant the inverse problem a unique solution. Suppose the sensor response changed from m op , at the operating gas composition x op , to m . Invoking the linear approximation in equation (2), the inverse problem is to find x that satisfies: Because J(x op ) is fat for a non-injective (M < G) gas sensor array, equation (17) has infinite solutions (fewer equations than unknowns). However, if we impose an additional assumption that the minimal-L2-norm gas composition change Δx := x − x op from x op is the culprit of the change in the sensor response Δm, the inverse problem is granted a unique solution. The altered inverse problem: has a unique solution given by Δx = J † Δm, with J † the Moore-Penrose pseudo-inverse [63] of J. Again, the SVD in equation (6) plays the central role, as the pseudo-inverse can be constructed from it [63].

Conclusions and discussion
Mathematically, gas sensor arrays map each gas composition vector x to an equilibrium response vector m. For gravimetric, MOF-based gas sensor arrays, this mapping is characterized by a mixed-gas adsorption model m = a(x). An observation of the (total) mass of gas adsorbed in an MOF generally places one independent constraint m i = a i (x) on the gas composition. We considered when there are fewer MOFs in the array than degrees of freedom in the gas composition (the number of components minus one, given fixed temperature and pressure). As a result, the mapping a : x → m is non-injective (many-to-one). Then, some gas composition changes from x op to x do not cause changes in the sensor response m op despite x = x op and thus are undetectable. We showed how to determine the local unresponsive subspace of gas composition space from the null space of the Jacobian matrix J of the adsorption model a(x). Whereupon small changes in gas composition in an unresponsive direction, the sensor response remains constant. More, the right singular vectors of J associated with its non-zero singular values give directions in gas composition space to which the sensor is responsive, ranked by sensitivity. We demonstrated the identification of unresponsive and ranked responsive directions in non-injective, single-and double-MOF sensor arrays based on HKUST-1 and Co-MOF-74 immersed in a mixture involving CH 4 , CO 2 , C 2 H 6 , and N 2 relevant to natural gas sensing [50]. Our case studies involved two MOFs and four components in the gas, instructively allowing us to visualize a(x) and clarify the meaning of the unresponsive and ranked responsive directions in gas composition space. The SVD in equation (6) is particularly powerful for large sensor arrays and high-dimensional gas composition spaces where visualization of a(x) is extremely difficult. Unsurprisingly, the identification of unresponsive and ranked responsive directions have analogies in multiple-input, multiple-output control systems: observability [73][74][75] and directionality [76,77], respectively.
A limitation of our method to identify unresponsive directions in gas composition space is that it pertains to small changes in gas composition (via the Taylor expansion in equation (2); this approximation is illustrated in figure 8(b)).
Why is it useful to identify unresponsive directions in gas sensors? A gas sensor is unresponsive to and thus cannot detect gas composition changes in the unresponsive direction. Determining the unresponsive directions of a gas sensor is important to quantify its limitations and identify its vulnerabilities to adversarial attacks [49]. In addition, given a set of candidate non-injective gas sensors for a sensing task, we may be able rank their fitness according to their unresponsive directions e.g. having a minimal component along a pertinent direction.
Does the notion and identification of unresponsive directions generalize beyond gravimetric, MOF-based sensors? The notion and process of identifying unresponsive directions herein generalizes beyond the specific sensing mechanism of observing the total mass of adsorbed gas in an MOF. To adapt to a generic array of sensing elements, each exhibiting some observable property dependent on the gas composition, redefine: • m as the vector containing the observed properties of the M sensing elements in response to the gas composition x. • a(x) as a function that models the response m to each gas composition x.
Even without much understanding of the underlying physics linking the response to the gas composition, we could build the model a(x) as follows. Construct the sensor array. Conduct gas exposure experiments: observe the response over a grid of gas compositions to generate data D = {(x i , m i )}. Build a regression model of a(x) using the training data D.
Gravimetric MOF sensors are attractive from a modeling perspective because we can construct a reasonable model a(x) without actually constructing the sensor array and conducting laborious experiments. Gas adsorption data in MOFs is abundant; thermodynamic theories of gas adsorption are welldeveloped; and molecular models and simulations can predict adsorption in MOFs. The latter enables the computational design of MOF-based gas sensor arrays, as exemplified by Wilmer and co-workers [54,55], who use molecular simulations of adsorption to predict the response of gravimetric, MOF-based sensor arrays and then evaluate their fitness for gas sensing.
How can we remedy non-injective gas sensors to give a determined inverse problem? The observed response of a noninjective gas sensor generally places an insufficient number of constraints on the gas composition to give the inverse problem a unique solution. We can make a non-injective sensor array injective by (i) retrofitting it with additional sensing elements (MOFs), (ii) designing sensing elements (MOFs) that do not respond appreciably to interferents in the gas that we are not concerned about, or (iii) imposing additional assumptions on the gas composition as in equation (18).
Is an injective sensor array the end goal? The inverse problem associated with an injective sensor array will theoretically always have a unique solution. However, in practice, the measurements of the masses of gas adsorbed in each MOF are corrupted by measurement error. As a result, the applied inverse problem [78] for an injective sensor array could still (i) have no solution or (ii) be ill-conditioned, where small measurement errors lead to large changes in the predicted gas composition [40]. The conditioning of the inverse problem, colloquially speaking, depends on the diversity of the MOFs in the array and their interactions with the components of the gas. One method to evaluate the fitness of different injective sensor arrays is to analyze the conditioning of their inverse problem [40].
Future work remains. First, we posed the gas sensing problem in terms of the equilibrium response of the gas sensor. However, the mass of gas adsorbed in an MOF is generally dynamic; gas must enter into and diffuse in the thin film of the MOF attached to the QCM [79][80][81]. Future work entails (i) considering the diffusion kinetics when evaluating MOFbased sensors to avoid slow response times, (ii) posing inverse problems in terms of the dynamic response of the sensor, as in Rajagopalan and Petit [57], and (iii) extracting additional information about the gas composition from the dynamics of the response.
Second, we assumed isothermal conditions. We may wish to use a gas sensor to robustly predict the gas composition in a range of temperatures. Future work entails building an adsorption model a(x; T) that applies under different temperatures T, then (a) inputting a separate measurement of T or (b) determining T as part of the inverse problem.
Third, imposing additional assumptions on the gas composition can endow the underdetermined inverse problem associated with a non-injective gas sensor with a unique solution. This idea of imposing additional assumptions, consistent with but not imposed by the physics underlying the problem, is a common approach to, given an inverse problem with many solutions, grant it a unique solution [78]. We provided one example in equation (18), where we sought the minimumnorm change in the gas composition consistent with the change in the response.
Fourth, for MOF-based gas sensor arrays to operate in practical conditions, we need to engineer MOFs that are (1) thermally, mechanically, and chemically stable [13,82] and (2) hydrophobic, for applications where moisture is present, so that the response is not dominated by water adsorption [14,83,84].