# [PERSON] Coding-Based Medical Image Data Hiding Method against Salt and Pepper Noise
## 3 Proposed RS-Based Data Hiding Method  
In this study, we aim to increase the resistance of the message hidden in medical images against salt and pepper noise. In the proposed method, the secret message is encoded with Reed Solomon codes and hidden in medical images. It is assumed that the stego image created by the proposed method is exposed to salt and pepper noise in the communication channel. Although the main purpose of the study is to test the resistance to noise, the method used for data hiding is also compatible with high capacity hiding. With the proposed method, we aimed to determine how accurately the secret message was extracted from the noisy medical image. In the proposed method, first of all, operations are made with the logo that will be hidden in the medical image as a secret message. The brightness values of the secret logo are transferred to a message array as a result of the row-column operations. Each element in the message array is converted to eight-bit numbers. A new array is created with all converted brightness value elements. In RS(n, k) coding, each symbol consists of decimal numbers encoded with m bits. Therefore, the bit sequence of the secret message is divided into m-bit symbols. Each m-bit symbol is converted to decimal values. Decimal message symbols are converted to \(GF(2^{m})\) numbers in Galois field, with the help of \(x^{m}+x+1\) minimal polynomial. By taking k of these message symbols, \(b(x)\) polynomial is created. With the help of the information polynomial \(b(x)\), and the generator polynomial \(g(x)\), the parity polynomial, \(p(x)\) that will add to the RS(n, k) codeword, is calculated as in Equation (3). Finally, the RS(n, k) codeword that consists of \(k\) message symbols and \(2t\) parity symbols, is obtained as a n-element [PERSON] message array. The secret message is now ready to be hidden in the medical image. In this study, we aimed to make corrections unless all k symbols in the codeword are distorted. RS(7, 3) coding has been used in terms of compliance with both these conditions and the proposed hiding method. Therefore, \(\mathrm{m}=3,\ \mathrm{n}=2^{m}-1=7\) and \(\mathrm{k}=3\), and the maximum number of errors that can be corrected in a codeword, is \(\mathrm{t}=2\) symbols. \[p_{e}(j)=\left\{ \begin{array}{cc}p(j)-p(j)[mod10]&p(j)<250\\ 249-249[mod10]&p(j)\geq 250\end{array} \right. \tag{12}\]  
These symbols embed to the luminance value of medical images with the proposed embedding method. For the data hiding method, it is proposed to hide a symbol directly into the brightness value of the pixel instead of the classic bit substitution methods. Thus, each symbol will be added to a pixel luminance (p) according to Equations (12) and (13). In this process, the proposed method changes pixel values a little, but when compared with its other advantages, these changes can be neglected. Because, the proposed method change pixel values, but these changes are unnoticeable in the human visual system. By hiding an RS symbol to a pixel, we change and lose some information. However, we reduce the amount of RS symbols that are affected by noise. This is because if the bits of a symbol are divided into more than one pixel the amount of noise exposure will increase. Moreover, when a secret symbol is embedded with the proposed method, there is not much significant loss. A lot of data hiding algorithms, such as [19; 27], aim to reduce the lost or changes after embedding secret messages, while providing high capacity and high fidelity. In the proposed data hiding method, n-tuple of the pixel of the medical image is taken first. Then, the units digit of the each luminance value is emptied and the new pixel value (\(p_{e}\)) is obtained, as in Equation (12). Because of preventing pixel luminance from exceeding the range 0-255 in the stegoimage, if a pixel value is 250 or greater, its value is set to 249. Each secret symbol of the Reed Solomon codeword is embedded to corresponding \(p_{e}\) as in Equation (13), and the modified pixel (\(p_{m}\)) is obtained.