A Null Space-Based Blind Source Separation for Fetal Electrocardiogram Signals

This paper presents a new non-invasive deterministic algorithm of extracting the fetal Electrocardiogram (FECG) signal based on a new null space idempotent transformation matrix (NSITM). The mixture matrix is used to compute the ITM. Then, the fetal ECG (FECG) and maternal ECG (MECG) signals are extracted from the null space of the ITM. Next, MECG and FECG peaks detection, control logic, and adaptive comb filter are used to remove the unwanted MECG component from the raw FECG signal, thus extracting a clean FECG signal. The visual results from Daisy and Physionet real databases indicate that the proposed algorithm is effective in extracting the FECG signal, which can be compared with principal component analysis (PCA), fast independent component analysis (FastICA), and parallel linear predictor (PLP) filter algorithms. Results from Physionet synthesized ECG data show considerable improvement in extraction performances over other algorithms used in this work, considering different additive signal-to-noise ratio (SNR) increasing from 0 dB to 12 dB, and considering different fetal-to-maternal SNR increasing from −30 dB to 0 dB. The FECG detection of the NSITM is evaluated using statistical measures and results show considerable improvement in the sensitivity (SE), the accuracy (ACC), and the positive predictive value (PPV), as compared with other algorithms. The study demonstrated that the NSITM is a feasible algorithm for FECG extraction.


Introduction
The electrocardiogram (ECG) signal, in a non-invasive method, incorporates of the maternal ECG (MECG) signal, the fetal ECG (FECG) signal, and several sources of interference, such as power line interference, baseline wander, motion artifact, fetal brain activity, muscle artifact, as well as noise, such as instrumentation noise [1][2][3]. FECG signal is used to monitor the health status of the fetus by determining its maturity level, reactivity, development, and existence of fetal distress [4].
FECG extraction and enhancement method requires the elimination of the MECG as well as optimal detection of the FECG. The frequencies of both signals are a few Hertz's and are possibly overlapping. Thus, separating them using the conventional linear filter fails. To address this problem, a large number of FECG extraction algorithms have been proposed over the past few decades. Some of these algorithms were based on the blind source separation (BSS) or blind source extraction (BSE) techniques [5,6]. In general, the extraction algorithms can be classified as either spatial (non adaptive) or temporal (adaptive) algorithms [7]. Examples of the BSS/BSE based non-adaptive algorithms include principal component analysis (PCA) [8], independent component analysis (ICA) [8,9], time scale image (TSI) and singular value decomposition (SVD)/ICA [10], periodic component analysis [11], parallel linear predictor (PLP) filters [12,13], template subtraction (TS) [14], artificial neural network

Problem Formulation
The biological ECG signal of a pregnant woman is a composite signal between the FECG, MECG, and the noise. It has been proven that the noiseless ECG signals can be modelled using the linear BSS model expressed by [8]: where X is the M × N zero mean recorded ECG mixture signals, from the thorax and the abdominal channels, A is the M × L unknown full rank mixing matrix, S is the L × N unknown source signals (the FECG and the MECG signals), recalling that M is the number of recorded ECG signals, L is the number of the unknown source signals (L ≤ M), and N is the number of samples of each measurement. We assume that both M and L are less than N. The matrices X and S have M and L row vector signals, respectively. Typical ECG signal is composed of P wave, QRS complex, S wave, and T wave. Both FECG and MECG signals are quasi-periodic. However, the amplitude and duration of P, QRS, and T waves are different. In addition, the FECG signal has higher frequency than the MECG signal [2,4]. The ECG signal is captured by appropriate electrodes placed at the abdominal and thorax.
The estimation of S and A from X is the main goal of the BSS problem. To estimate S, we denote matrix Y, having the same dimension of S, as the estimated source matrix, given by Y = HX, (2) where H is the L × M estimated transformation matrix. As the BSS model shown in (1) is affected by scaling, permutation, and rotation ambiguities [34], several methods has been developed to extract S using (2). This will be discussed in Section 3.

Related FECG Extraction Methods
In this section, we discus some widely used approaches, such as PCA and FastICA [35,36]. Moreover, the PLP method in [12] is also included as a recent method to compare with.

PCA Approach
Different methods were reported in the literature to estimate H based on PCA [37]. The PCA whitening method is one of the popular methods, in which the matrix H is computed from the whitening matrix C x , where C x is the M × M covariance matrix of X. The PCA output signals have the property of being uncorrelated. However, these signals do not necessarily represent independent sources [37]. Thus, the PCA method has inferior extraction performance compared with other methods. Despite this disadvantage, the PCA algorithm has less amount of computations as compared with other methods, and shows acceptable detection of FECG R peaks. Thus, the PCA method is still showing interest by researchers in the field of FECG detection and extraction [36,38,39].

FastICA Approach
In the FastICA approach, the matrix H is equal to A + , which is the Moore-Penrose inverse of A, such that A + = A T (AA T ) −1 , if L ≤ M [12]. The resultant estimated sources must be statistically independent. In many FastICA algorithms, the whitening process is needed prior to applying the algorithm, to minimize the correlation between the mixture signals. The PCA approach may be used for data whitening. The FastICA based FECG extraction has some challenges. First, it assumes independent sources and its performance is directly affecting the quality and speed of FECG signal extraction. Second, the background noise has a considerable affect on its performance [3]. Some works were reported to combine the FastICA approach with other approaches [9,10,27,28].

BSE Based PLP Filter
In [12], a BSE based PLP filter was proposed to solve BSS problem using a set of linear predictors that works simultaneously to predict the unknown input sources. The input to the PLP filter is the covariance matrix of the whitened data, denoted by R(n), with the estimated source signals being considered as the PLP filter coefficients. The number of coefficients is fixed to N in this method. The prediction error is minimised using the standard gradient descent algorithm (GDA). The update equation of the estimated source signals, is given by: where y m (n) = [y m (1), y m (2), . . . , y m (N)] T , is the m th vector, m = 1, 2, . . . , L, of the estimated source signal, y m (n + 1) is the update vector of y m (n), µ y is the learning rate, and E r (n) is the error vector. The method has the merits of solving the mixture power ambiguity and has a fast convergence rate. The method was employed to extract FECG signal from real and synthetic ECG data [13]. In addition, the method can be used to extract signal from a noisy mixture.

The Proposed FECG Extraction System
The proposed system is based on extracting the FECG and MECG signals from the null space solution of a certain matrix, named idempotent transformation matrix (ITM), and is being referred to us as W. In this section, we first discus the pre-processing stage that is required to reduce the effect of noise and interface in the ECG signals, since real ECG signals are usually contaminated with different types of noise and interference, as declared in Section 1. Then, the derivation of W matrix is provided. A solution method, using the null space of W, is then explained to address the extracted FECG and MECG signals. We named the extracted FECG signal as raw FECG since it may be contaminated with some unwanted MECG peaks. Thus, a post-processing stage is required to clean the raw FECG signal from the unwanted MECG peaks.

The Pre-Processing Stage
The pre-processing stage includes three cascaded stages: low pass, high pass, and notch filters. The input and output of the the preprocessing stage are defined by X and X p , respectively. A low pass Butterworth filter with 100 Hz cutoff frequency, defined by f 1 , is applied to limit the frequency band of the input ECG signals. The baseline wander effect is reduced using high pass filter of 0.5 Hz cutoff frequency, defined by f 2 , [29]. A second order notch filter having cutoff frequency, defined by f 3 , of 50 Hz or 60 Hz is used to remove the 50 Hz or the 60 Hz power line interference, respectively. The selection of the cutoff frequency depends upon the power line standard which is either European or US standard [9].

The Idempotent Transformation Matrix (ITM)
Define the jth signal y j (n − k + 1), j = 1, 2, . . . , L, k = 1, 2, . . . , N, as the extracted FECG or MECG source signal, and expressed by the following N prediction filter [32,33,40] where w q,k is the autoregressive coefficients of y j (n − k + 1). Re-writing (4) in matrix form, we obtain where Y is the extracted source matrix of dimension L × N, and can be written as and W is the N × N symmetrical idempotent transformation matrix, and is given by The matrix W can be computed as follows [33]: where C x is the covariance matrix of X. The computational complexity of W is equal to O(M 4 N 2 + 6N 3 + 14 3 N 3 ). However, it can be reduced to O(M 2 N 2 + MN 2 ) using an iterative method [33].

The Null Space Solution of W
The matrix W, computed from Section 4.2, is then used to estimate the extracted raw FECG and MECG signals, as follows: Equation (5) can be rewritten as where Q is the required N × N separation matrix, and 0 N×L is an N × L zero matrix. Equation (9) can be solved for the unknown Y using the null space of Q, as follows: Since the extracted signals of the Y matrix are computed based on (11), i.e, the Null space (NS) of Q, and since W is an ITM, we call this method NSITM. The computational complexity of Null(.) based on SVD is equal to O(6N 3 + 14 3 N 3 ) [41]. Thus, the overall computational complexity of NSITM will be O( . It is clear that there is a significant reduction in the computational complexity of the proposed NSITM as compared with the NCA method in [20]. Figure 1 shows a logarithmic plot to illustrate a comparison between the computational complexity of NCA and NSITM when N is varied from 10 to 1000, assuming N 1 = 20, N 2 = 10, and M = 5. The solution of (11) can be obtained using SVD. First, we express Q by where U q is an N × N unitary matrix, D q is an N × N diagonal matrix with the eigenvalues of Q, and V q is an N × N matrix with the columns being the eigenvectors of Q. Assume that V q is expressed by then, from (11)- (13), and since L < M, which is the usual case in FECG extraction, the solution Y will be taken from the last L column vectors of V q , and is given by Equation (14) represents the extracted raw FECG and MECG signals. Figure 2 illustrates the block diagram of the raw FECG and MECG system, based on the discussion in Sections 4.1-4.3.

High pass filter
Notch filter As the MECG signal level, in the input mixture, is high as compared with the FECG signal, the MECG signal may exist in the extracted FECG signal, especially in noisy environments. This needs a postprocessing stage to detect first the MECG peaks and then remove them from the raw FECG signal. This post-processing is shown in Section 4.4.

The Post-Processing Stage
The operation of this stage is based on using multiple window functions, named adaptive comb filter (ACF) [19], centered at all MECG peaks, then multiplying its unit sample response by the raw FECG signal. This results in removing the unwanted MECG component from the raw FECG signal. The post-processing stage consists of peaks detection, control logic, and MECG removal. In the following, we will discuss all these stages and then show how to connect them in order to remove the unwanted MECG peaks from the raw FECG signal.

Peaks Detection
The R peaks in the raw FECG and MECG QRS complex are detected using the Pan-Tompkins algorithm [42,43]. Due to the quasi-periodic nature of the FECG and MECG signals, and since the time needed to record ECG signals is typically long and contains many periods of the signals, we define p 1 and p 2 as vectors that contain the sampling indices, i.e., locations, of all detected MECG and FECG peaks, respectively. We also define P 1 and P 2 as the number of detected MECG and FECG peaks, respectively. Then, the difference in sampling indices between two consecutive MECG and FECG peaks, defined as dp 1 and dp 2 , are given by dp 1 (l) = p 1 (l + 1) − p 1 (l), l = 1, 2, . . . , The lth maternal heart rate (MHR l ) and the kth fetal heart rate (FHR k ) can be calculated from (15) and (16), as follows: MHR l = 60 f s /dp 1 (l), FHR k = 60 f s /dp 2 (k), where f s is the sampling frequency of the ECG signals. The average values (MHR and FHR) are then calculated by

Control Logic
The control logic stage is required to decide about the existence of unwanted MECG peaks at the raw FECG signal, then activate the MECG removal stage when needed. The stage checks the estimated FHR. If the raw FECG signal contains MECG components, then the estimated FHR from (20) will not fall within the expected FHR ranges, since the values of elements of the vector dp 2 will decrease according to (16), resulting in an increase in FHR k according to (18). For instance, if an MECG peak is located half the way between two consecutive FECG peaks, the local values of the elements of dp 2 in that sector will be decreased to half its value as compared with the situation when MECG peak does not exit. This causes the FHR k to be doubled its value in that sector. If an MECG peak is very close to the location of the FECG peak, then dp 2 local value approaches zero in that sector, resulting in an infinite value of FHR k . As a result, the existence of MECG peaks causes a large increase in the variance of the estimated vector [FHR 1 , FHR 2 , . . . , FHR P 2 −1 ]. The control logic considers these two factors and activates the MECG removal to extract a clean FECG signal. However, if the MECG peaks do not exist in the raw FECG signal, the control unit will deactivate the MECG removal stage. Thus, the raw FECG signal will be considered as the clean FECG signal.

MECG Removal
The MECG removal stage removes the MECG components in the raw FECG signal using ACF, whose unit sample response is denoted by h(n), and is expressed as where w(n) is the unit sample response of a non-causal Hamming window with 2U + 1 being its length, and centered at n = 0, a r is the window coefficient, and δ(n) is a unit sample function. The resultant h(n) consists of multiple window functions centered at all MECG peaks p 1 (1), p 1 (2), . . . , p 1 (P 1 )-thus multiplying h(n) by the raw FECG results in removing the unwanted MECG components. Figure 3 illustrates an example of a typical extracted MECG and raw FECG signals using the system shown in Figure 2. The figure illustrates how to position the ACF in order to remove the unwanted MECG components from the raw FECG signal. More details about MECG removal are provided in the simulation section. Figure 4 illustrates the proposed post-processing stage used to get the clean FECG signal. Figure

The Proposed NSITM Algorithm
From Figure 5, we propose the NSITM Algorithm 1 that extracts the MECG/FECG signals from the ECG mixture signals. The maxFHR is the maximum possible FHR. At 20 weeks, it can be set to 180 beats per minute (bpm) [2]. The maxvar is the maximum variance of FHR vector [FHR 1 , FHR 2 , . . . , FHR P 2 −1 ]. Values of 1-5 are found to be appropriate during simulation. The var(.) used in the algorithm represents the variance of (.).

Experiments
Five different simulations are provided in this section. The first simulation uses real ECG signals from the database for the Identification of Systems (DAISY) [44]. Then, the FECG signal is extracted using our proposed NSITM algorithm. The simulation is repeated using PCA, FastICA, and PLP algorithms, for comparison purposes. The second simulation is similar to the first simulation but uses another real piece of data from Physionet/Computing in the Cardiology Challenge 2013 database [45,46]. The third simulation extracts the FECG signals from a synthesized ECG data and then evaluates their performances. The synthesized data were taken from Physionet/Fetal ECG Synthetic database (FECGSYNDB) [46,47]. The fourth simulation investigates the FECG extraction metrics based on fetal-to-maternal SNR (fmSNR) variations. Data used in this simulation are the same as the data used in experiment 3. The fifth simulation evaluates the performance of the algorithm using statistical measures, using the data from experiment 2. In all simulations, the denoising filters (lowpass, highpass, and notch) were performed in all algorithms used in this work. In addition, for clarity, all signals are visualized in a normalized form, unless otherwise specified. All simulations were conducted in Matlab R2018b, on 2.2 GHz Intel Core i7-8750 CPU with 16 GB RAM, Windows 10.

Experiment 1: FECG Extraction of Real ECG Data from the DAISY Database
Recorded real ECG signals, from pregnant women for 10 s, were used from [44]. The signals were acquired from eight channel sensors (five abdominal and three thorax channels). The sampling frequency f s was selected to be 250 Hz. Then, the proposed NSITM algorithm was applied to extract the FECG and MECG signals. The PCA, FastICA, and PLP algorithms were also applied to extract the FECG and MECG signals, and their results will be compared with the results from the proposed algorithm. Figure 6 illustrates the recorded ECG signals, with N = 2500 samples, and M = 8, using five abdominal signals (x 1 (n)-x 5 (n)) and three thorax signals (x 6 (n)-x 8 (n)). There are a large number of combinations between these eight signals needed as input to test the algorithms. In our work, and to efficiently use the space, we showed only the case for (M = 7). Figures 7 and 8 illustrate the extracted FECG and MECG signals, respectively, using the selected algorithms, considering five abdominal signals (x 1 (n)-x 5 (n)) and two thorax signals (x 6 (n)-x 7 (n)). As the data from DAISY are clean, the MECG components were not found in the raw FECG signals, thus the control unit in Figure 2 will deactivate the MECG removal stage. Thus, the extracted FECG signal shown in Figure 7 represents both the raw FECG and the clean FECG signals. The visualization on the results indicates that the proposed NSITM algorithm, the PCA algorithm, the FastICA, and PLP algorithms are effective in extracting the FECG and MECG signals from the ECG mixture. In addition, the estimated FECG signals using NSITM and FastICA show less noise contents as compared with PCA and PLP.   Figure 7. Extracted FECG signals from ECG signals in Figure 6, using NSITM, PCA, FastICA, and PLP, assuming M = 7 (five abdominal signals x 1 (n)-x 5 (n) and two thorax signals x 6 (n)-x 7 (n).The y-axis labels refer to the names of the algorithms used for extracting the FECG signals. Data used are from the DAISY data set.  Figure 6, using NSITM, PCA, FastICA, and PLP, assuming M = 7 (five abdominal signals x 1 (n)-x 5 (n) and two thorax signals x 6 (n)-x 7 (n). The y-axis labels refer to the names of the algorithms used for extracting the MECG signals. Data used are from the DAISY data set.

Experiment 2: FECG Extraction of Real ECG Data from the Physionet Database
Recorded real ECG signals, from pregnant women for one minute, were used from the Physionet Challenge 2013 data set [45,46]. Each recording includes four noninvasive abdominal signals. The data were obtained from multiple sources using a variety of instrumentation with differing frequency response, resolution, and configuration. The sampling frequency f s for all data are 1 kHz. We selected the data files (a04, a08, a14, a15, a25) from the database, and used them in this experiment. Then, we followed the same simulation procedure as in Section 5.1. For illustration purposes, we visualize only the results of file a15 due to the excessive number of figures. Figure 9 illustrates the recorded abdominal ECG signals, from file a15, with M = 4. We selected a block of 5000 data samples, from 0-4999. Figures 10 and 11 illustrate the extracted FECG and MECG signals, respectively, using the selected algorithms. Figure 10 shows the raw FECG signals using all algorithms (the proposed NSITM algorithm, as well as the PCA, FastICA, and PLP algorithms). However, all used algorithms are effective in extracting the MECG signals from the ECG mixture, as in Figure 11. Figure 10 shows that both FECG and MECG R peaks exist, and are marked by red dashed lines and green dashed lines, respectively. The red dashed lines and the green dashed lines are the left and the right lines in Figure 10, respectively. Thus, the control unit will activate the MECG removal stage. The locations of the ACF, used to remove the unwanted MECG peaks, are illustrated in Figure 10 by black arrows. The length of the ACF window is a variable quantity and depends upon the duration of the QRS complex of the selected MECG signal. In this simulation, a length of 20 samples were found appropriate in removing the MECG R peaks, for the used file a15. For other used files, the length of ACF must be selected between 20 and 45 samples, to avoid the removal of portions of the required FECG signal when the two signals are very close in their locations. Figure 12 illustrates the clean extracted FECG signals of Figure 10 after the removal of MECG signals by ACF. The first signal from the top is the abdominal ECG signal x 1 (n), which is considered at the top of the figure for illustration purposes, since it contains the reference annotation taken from LightWAVE annotation viewer [45]. It is clear from Figure 12 that the proposed NSITM algorithm, the PCA algorithm, the FastICA algorithm, and the PLP algorithm are effective in extracting the FECG and MECG signals from the ECG mixture. The extraction performances will be considered later in Section 5.3.
To ensure the stability of extraction performance over time, the simulation is repeated by taking blocks of data samples from 5000-9999, and from 55,000-59,999 which are the last available data samples. The results obtained are very similar to the results using data samples from 0-4999. Results from those simulations are not shown in this paper to limit the number of pages. In general, the proposed NSITM algorithm as well as the other algorithms are effective in extracting both FECG and MECG signals from the abdominal ECG mixture if ACF is used to remove the MECG R peaks from the raw FECG signals shown in Figure 10.    Figure 10 after the removal of MECG signals by ACF, and based on R peaks locations in Figure 11. The first signal from the top, x 1 (n), is the abdominal signal taken from Figure 9, and used as a reference of marking the FECG and MECG R peaks. The 'x' and '∆' markers refer to the reference positions of the R peaks in FECG and MECG signals, respectively. The red dashed lines refers to one position of the extracted FECG R peaks. The green dashed lines refers to one position of the removed MECG R peaks. The y-axis labels of signals 2, 3, and 4 (from the top) refer to the names of the algorithms used for extracting the FECG signals. The data used are from the Physionet Challenge 2013 data set a, file a15.

Experiment 3: FECG Extraction Using Synthesized ECG Data
To study the extraction performance of the proposed algorithm, the ECG signals (FECG and MECG) must be first modelled then mixed according to (1). The modelling of ECG signals involves the generation of P, QRS, and T waves. This can be accomplished using the synthesized data taken from Physionet/Fetal ECG Synthetic database (FECGSYNDB) [46,47]. This database and its collection methods are described in [48]. Each signal had a duration of 5 minutes, and was sampled at 250 Hz with a 16-bit resolution. The FECG and MECG signals are generated by treating each abdominal signal component (e.g., foetal/maternal ECG or noise signals) as an individual source, whose signal is propagated onto the observational points, also called the electrodes. Thus, the database provides separate waveform files for each signal source [46,47]. The simulator generates 34 ECG channels (32 abdominal and 2 maternal ECG reference channels). Adding the three individual signals (FECG, MECG, and noise) per channel is then needed to generate the ECG mixture [49]. In our experiment, we consider four abdominal channels (10,11,18,19) and the two reference channels (33 and 34) with different signal to noise ratio (SNR), equals to 0 dB, 3 dB, 6 dB, 9 dB, and 12 dB, respectively. The values of SNR are selected from the available values in [47]. We select eight pregnant women with simulated pregnancy numbers (01, 02, 03, 06, 07, 08, 09, 10). The selected event is maternal heart rate (MHR)/FHR acceleration/deceleration plus noise. As there are many entries needed to download a file, the file name format is long. To simplify the file format and use it in the paper, we propose a short file format. Table 1 illustrates examples of how to rename the downloaded files for different simulated pregnancy numbers, SNR, and signal type. Other file names can also be obtained based on this table. Table 1. Examples of how to rename the files downloaded from the FECGSYNDB large database [47], considering SNR = 0 dB, 6 dB, and 12 dB. The paper file name is used in this paper to shorten the long file name from [47]. Its format is XYYZZ, where X is an abbreviation for the synthesized signal, and is equal to F (for FECG), or M (for MECG), or N (for Noise), YY is the simulated pregnancy number (00-10), ZZ is the SNR (00 dB, or 06 dB, or 12 dB). The 'l1' code in the downloaded file name refers to the repetition number (1 to 5). It was selected as 1 in this paper.  Figure 13 illustrates the synthesized abdominal FECG, MECG, and noise signals, from channel (10), considering simulated pregnancy number = 01, SNR =12 dB, and event of MHR/FHR acceleration/deceleration plus noise. The signal number (4) from the top is the mixture signal after adding the FECG, MECG, and noise signals. Other signals from channels (11,18,19) and their corresponding mixtures were not shown in the paper due to excessive number of figures. All signals in Figure 13 are visualized in un-normalized forms to show the actual amplitudes of the components of the mixture signal (10). Figure 14 illustrates the synthesized maternal reference ECG (MECG) signals, from channels (33-34). All signals in Figure 14 are visualized in un-normalized forms, in order to compare it with the mixture signal (10) shown in Figure 13. The proposed NSITM algorithm was then applied to these six signals (the four abdominal mixture signals plus the two reference signals) to extract the FECG and MECG signals. The simulation is repeated to extract the FECG and MECG based on PCA, FastICA, and PLP algorithms, for comparison purposes. The extracted FECG and MECG signals from all algorithms are illustrated in Figures 15 and 16, respectively. As the synthesized data are clean, the MECG components were not found in the raw FECG signals, thus the control unit in Figure 2 will deactivate the MECG removal stage. Comparing the synthesized FECG and MECG signals shown in Figure 13 with the extracted FECG and MECG signals shown in Figures 15 and 16, it is clear that all algorithms are effective in extracting FECG and MECG signals from their mixture, since all extracted signals (MECG and FECG) match the original signals (MECG (10) and FECG (10)), respectively.  Figure 13. The corresponding paper file name is M0112, according to Table 1. The y-axis labels refer to the names of two signals taken from channels 33 and 34.  To evaluate the FECG extraction performance of the previous simulation, we use the similarity performance index (SPI) [7,33], the source-to-interference ratio (SIR), the source-to-artifacts ratio (SAR), and the source-to-distortion ratio (SDR) [50]. These metrics were widely used in evaluating the extraction performance of speech and biomedical signals [20,51,52]. We define y i (n), i = 1, 2, . . . , L as the i th row vector of the extracted matrix Y. The extracted signal y i (n) is estimated using PCA, FastICA, and NSITM algorithms. We also define s i (n) as the corresponding i th row vector of the source matrix S, having the same form of Y, as in (6). Then, the SPI is computed as where L = 2 (the FECG and MECG sources), and . denotes the inner product. To compute SIR, SAR, and SDR, it is required first to decompose the extracted signals y i (n), as follows: where s target is the component of s i (n) in y i (n), e inter f , e noise , and e arti f are the interference, noise and artifact error terms, respectively. Second, the terms are computed using BSS EVAL toolbox, as follows [53]: The simulation is repeated by first fixing the SNR at 0 dB and then varying simulated pregnancy numbers from 1 to 10. For each step, the SPI, SIR, SAR, and SDR are computed, and their average values are obtained. The simulation is repeated by varying the SNR to 3 dB, 6 dB, 9 dB, then to 12 dB. Results of simulation (for only 0 dB, 6 dB, and 12 dB) are recorded in Tables 2-4. Results from the proposed NSITM algorithm are provided in bold letters in these tables. The average values of the extraction performances are plotted as shown in Figure 17. Other results (for 3 dB and 9 dB) are not shown due to excessive number of pages. However, they are included in the final results shown in Figure 17. Results from Figure 17 indicate that for SNR equals 0 dB, the proposed NSITM algorithm shows a considerable improvement over others in terms of SPI. However, it shows slightly less value in terms of SIR, SAR, and SDR, as compared with the FastICA. For SNR equals 3 dB, 6 dB, and 9 dB, the proposed NSITM algorithm shows better score, in all metrics, than other algorithms. For SNR equals 12 dB, the proposed NSITM algorithm shows the highest scores in SAR, SDR, and SPI, while its SIR score is the next highest score after the FastICA. These results were recorded based on applying the algorithms on the available data. As a general conclusion, the extraction performances of the proposed NSITM algorithm shows mostly considerable improvement with increasing SNR values, as compared with other algorithms.     Tables 2-4. SIR, SAR, and SDR are computed using Equations (26)- (28). SPI is computed using Equation (24).

Experiment 4: FECG Extraction Metrics Based on Fetal-to-Maternal SNR Variations
In this section, the FECG extraction performance is evaluated by varying the fetal-to-maternal SNR (fmSNR) from −30 dB to 0 dB and extracting the FECG signal (using NSITM, PCA, FastICA, and PLP algorithms). We used the same data from Section 5.3, from channels (10,11,18,19) and the two reference channels (33 and 34). First, the FECG and MECG signal are generated as discussed in Section 5.3, and illustrated in Figure 13. Next, we set the value of fmSNR to −30 dB, as a starting value.
To satisfy that the value of fmSNR is −30 dB, the FECG signal is multiplied by a factor, denoted by p, which is computed according to [26,49] where p m and p f are the MECG and FECG signal power, respectively, and q =fmSNR. The mixture signal is then computed by adding the MECG signal to the FECG signal (after multiplying by p) [26,49]. This procedure was repeated for all used signals for channels (10,11,18,19). The mixture signals are then passed to the NSITM and other algorithms to extract the FECG and MECG signals. Finally, the quality signal-to-noise ratio (qSNR) of the extracted FECG signal is then computed as [26,54]: where s k f (n) andŝ k f (n) are the FECG and the extracted FECG signals for channel k, k = 10, 11, 18, 19. All above steps were repeated to extract FECG and MECG sigals when fmSNR is −25 dB, −20 dB, . . . , 0 dB. Figure 18 illustrates a plot of qSNR versus fmSNR variations using the NSITM, PCA, FastICA, and PLP algorithms. Results from Figure 18 show considerable improvement of qSNR using the proposed NSITM, as compared with PCA, FastICA, and PLP, when fmSNR varies from −30 dB to 0 dB.

Experiment 5: Performance Evaluation Using Statistical Measures
In this simulation, we used three statistical measures, the sensitivity (SE), the accuracy (ACC), and the positive predictive value (PPV), in order to evaluate the performance of the proposed algorithm in detecting the FECG peaks [4,7,29,54]. We used the same real ECG Data, from Physionet Challenge 2013 data set a, and the simulation carried out in Section 5.2. Then, the extracted FECG signal is used to compute the SE, ACC, and PPV, as follows: where TP, FN, and FP are true positive, false negative, and false positive, respectively. Results were recorded in Table 5. From the results in Table 5, it is clear that the the proposed algorithm NSITM scores the highest mean values in SE, ACC, and PPV, as compared with other algorithms. Thus, the proposed NSITM algorithms has resulted in significant improvement in FECG signal detection as compared with other algorithms used in this paper. In the first experiment, visual FECG and MECG waves are provided to demonstrate the advantages of our proposed algorithm, based on using real ECG data from Daisy database. From Figures 6-8, one may gain the following insights: 1. The proposed NSITM algorithm is effective in extracting the FECG and MECG signals from the ECG mixture. The extraction shows some background noise, using the proposed NSITM and all used methods. This requires further investigation and is probably covered in future work. 2. As the ECG signal from Daisy database is clean, the proposed NSITM is able to extract the FECG signal directly form the raw FECG signal obtained from Null(.) stage in Figure 2. This decision is taken by the control logic in Figure 2, and explained in Algorithm 1, step 13.

Discussion on Experiment 2
This experiment is similar to experiment 1, in visualization the FECG and MECG signals. However, real ECG data were provided from the Physionet database. From Figures 9-12, we have the following remarks: 1. As the data used in this experiment is noisy, the proposed NSITM algorithm and other algorithms used in this experiment, provide raw FECG signals that contain both FECG and MECG signals, as shown in Figure 10. Thus, the MECG components need to be removed using ACF. First, the MECG signals were extracted as shown in Figure 11. Then, the locations of R peaks in the MECG signal are estimated. These locations are used to adjust the ACF in order to remove the MECG components from the raw FECG signals. 2. The extracted FECG and MECG signals, using the proposed NSITM, are better than other extracted FECG and MECG signals using PCA, FastICA, and PLP algorithms.

Discussion on Experiment 3
In this experiment, visual FECG and MECG signals and four extraction performances (SIR, SAR, SDR, and SPI) are provided to address the effectiveness of our proposed algorithm, based on using synthetic data from Physionet database, considering MHR/FHR acceleration/deceleration plus noise. From Figures 13-17 and Tables 2-4, one may point out the following remarks: 1. The proposed NSITM algorithm is effective in extracting the FECG and MECG signals from the ECG mixture. As there were no MECG components in the raw FECG signals, the ACF will be deactivated by the control logic and the raw FECG signal is considered as the extracted FECG signal, as shown in Figure 15. Figure 15, the extracted FECG signal using the proposed NSITM is better than other extracted FECG signals using PCA, FastICA, and PLP algorithms. 3. As illustrated in Figure 17, the average values of the extraction performances SIR, SAR, SDR, and SPI are significantly better for the NSITM algorithm than those results obtained using PCA, FastICA, and PLP algorithms, for SNR equal to 3 dB, 6 dB, 9 dB, and 12 dB. However, for SNR = 0 dB, the FastICA shows a slightly better performance. This is due to limited number of data, i.e., subjects, used in the experiment. An increasing amount of experimental data may show better performances using NSITM, as is the case for 3dB, 6 dB, 9 dB, and 12 dB. We used the available data to run this simulation.

Discussion on Experiment 4
In this experiment, the effect of varying the fmSNR on the qSNR is provided to address the effectiveness of our proposed algorithm in extracting the FECG for different values of fmSNR, and based on using synthetic data from experiment 3. From Figure 18, one may point the following remarks: 1. At very low fmSNR, −30 dB, the proposed NSITM algorithm and other algorithms show the same low level of qSNR, which is equal to 1.29 dB. This is expected from all BSS algorithms at very low SNR. 2. As the fmSNR increased, the proposed NSITM shows a considerable qSNR improvement as compared with all other algorithms. The maximum qSNR was recorded to be at 9.1 dB when the fmSNR is 0 dB. 3. The next considerable algorithm is the PLP that shows a qSNR value of 8.2 dB at 0 dB fmSNR. 4. The FastICA and PCA performance scores for the third and the fourth places with qSNR of 3.83 dB and 2.12 dB, respectively, at fmSNR = 0 dB.

Discussion on Experiment 5
In this simulation, three statistical measures (SE, ACC, and PPV) were used to evaluate the performance of the proposed algorithm in detecting the FECG peaks. A real data from experiment 2 were used in this simulation. From Table 5, the followings points may be noted: 1. The proposed NSITM algorithm scores the highest average SE value (99%) as compared with other algorithms. The next highest scores are (98%, 97.3%, and 96.1%), using the PLP, FastICA, and PCA algorithms, respectively. 2. The proposed NSITM algorithm scores the highest average ACC value (97%) as compared with other algorithms. The next highest scores are (95.5%, 93.3%, and 91.9%), using the PLP, FastICA, and PCA algorithms, respectively. 3. The proposed NSITM algorithm scores the highest average PPV value (97.9%) as compared with other algorithms. The next highest scores are (97.4%, 95.7%, and 95.4%), using the PLP, FastICA, and PCA algorithms, respectively.

Future Work
In summary, our best results on the Daisy and Physionet (Challenge 2013 and Synthetic) databases were achieved by using the proposed NSITM as compared with other algorithms, for the majority of used data files. This is the best that we can do due to the absence of large publicly available databases with expert references [7].
Furthermore, the FECG morphological evaluation of both the simulated and real data are in its earliest stages and requires further investigations. However, we have achieved some extraction performances based on synthetic databases. Furthermore, our proposed NSITM uses ACF to remove the MECG components from the raw extracted FECG. This may cause the removal of some information from the raw FECG signal if the FECG and MECG R peaks are overlapped. Thus, further investigation may be required to remove the MECG component using new post processing techniques.
Furthermore, as the proposed NSITM has less computational complexity as compared with other NCA algorithms. Hence, the algorithm has the potential to be implemented in real time. Further investigation may be required to implement the algorithm for real-time applications that require cooperation with heath care providers and medical doctors.

Conclusions
A noninvasive FECG extraction algorithm, referred to as NSITM, has been presented. The design problem has been formulated and an analysis has also been provided. The proposed algorithm computes first the ITM matrix W from the original ECG input. Then, the raw FECG and MECG signals are estimated from the Null space of W. The clean FECG signal is then extracted by removing the unwanted MECG component from the raw FECG signal. This requires FECG/MECG peak detection and a decision-making algorithm to address the exact locations of the MECG peaks. The computational complexity of the proposed algorithm have shown considerable improvement as compared with the previous NCA algorithm. The proposed algorithm was simulated using real and synthesised ECG data, and compared with PCA, FastICA, and PLP algorithms. Visual results using (DAISY) real data have shown that the proposed algorithm is effective in extracting FECG and MECG signals, when selecting the number of abdominal signals to be 5, with two reference signals taken from the thorax. Visual results using real data from the Physionet Challenge 2013 dataset/set a have shown the existence of MECG R peaks in the FECG signals. The MECG peaks have been removed using ACF, thus extracting clean FECG signals. The robustness of the proposed algorithm over time was checked to address the effectiveness of the algorithm in extracting the FECG and MECG signals.
Results of applying the NSITM algorithm to the Physionet/Fetal ECG Synthetic database (FECGSYNDB) have shown the capability of the algorithm in extraction FECG and MECG signals from all eight data signals used in simulation, and for all selected SNR values (available from the Physionet database from 0 dB to 12 dB), with MHR/FHR acceleration/deceleration plus noise being selected as the event type. The average values of the extraction performance metrics (SIR, SAR, SDR, and SPI for the NSITM algorithm have mostly shown significant improvement compared to other algorithms, when data files are used with SNR from 0 dB to 12 dB. Results on applying the NSITM algorithm to the same synthetic data have shown considerable improvement in qSNR when fmSNR varied from −30 dB to 0 dB. The proposed algorithm was also evaluated using statistical measures (SE, ACC, and PPV). Results on applying the proposed algorithm on the Physionet Challenge 2013 data/set a have shown the highest statistical values of SE, ACC, and PPV, as compared with other algorithms.

Conflicts of Interest:
The authors declare no conflict of interest.