^{1}

^{1}

This research suggests the improving Sine Cosine algorithm and Arithmetic optimization algorithm (SCA-AOA), and the application in two directions: First, in special functions (N-P hard) problems; second, in code analysis and decryption for the method of encryption substitution of simple cipher. The proposed algorithm mathematically simulates the behavior of SCA and Arithmetic algorithm behavior in Mathematical. The measure of SCA-AOA has been measured on a set of test functions to know the power of its performance and efficiency, and verify and compare it with SCA and AOA, each one alone. The numerical results have proved that the proposed algorithm (SCA-AOA) is able to present excellent results as compared with SCA-AOA itself. The applied results have proved that the proposed algorithm is able to analyze and break code. It could also avoid the falling the local solution and reaching to the global optimum resolutions in majority of functions that have been applied on. The adoptive Fuzzy SCA-AOA has been proposed and used in analyzing cipher text and breaking the code by merging the proposed algorithm SCA-AOA with properties of fuzzy logic. Moreover, the simple encoding method is explained and used to encode the proposed text. The method of masking by images is explained and used to hide text. The standards are used to measure the image resolution and find the image resolution. The encrypted text was analyzed and returned to the explicit text using the proposed method, SCA-AOA and Fuzzy SCA-AOA both separately, and the code for the encryption was broken by the proposed method.

Optimization is the process of getting the best values for variable certain problems for minimizing and maximizing certain function. To study the solution optimization problems, multiple complicated steps must be followed: First, determining land marks and building the nature of the world; second, categorizing the problem whether it is separated or continued and evaluating restraints to the restricted and not restricted; third, aims of a certain problem must be verified and the optimization problem is classified into problems with one aim versus multiple aims problems; finally, testing a suitable optimization, using it to solve the problem. In this research paper, a certain optimization has been used in solution of chosen problem, used in previous studies in this field, using of sine cosine algorithm (by S. M) [

This SCA has been proposed by (S. A. M. 2016) [

X k t + 1 = X k t + r 1 × sin ( r 2 ) × | r 3 P k t − X k t | , r 4 < 0.5 (1)

X k t + 1 = X k t + r 1 × cos ( r 2 ) × | r 3 P k t − X k t | , r 4 > 0.5 (2)

where X k t is the current solution which has been changed by using the two functions sine and cosine with a set of iterations t-th, and r_{1}, r_{2}, r_{3} are random values by using absolute value which depends on r_{4} value as a random number, | r 4 | < 0.5 of the scale of functions sine and cosine have been changed in the above mentioned equation by using:

r 1 = a − t a T (3)

where t is current iteration, T is max iteration & a is a constant.

AOA is an algorithm suggested by (Laith and et al. 2020). The basis of its work is its reliance on known mathematical operations such as subtraction, addition, division and multiplication. Solutions are found and improved based on the parameters shown in the equations below.

M O A ( C _ I t e r ) = M i n + C _ I t e r × ( M a x − M i n M _ I t e r ) (4)

“where MOA(C_Iter) the function value at the t-th iter., which is calculated by Equation (4). C_Iter the current iter., which is between 1 and the max number of iter. (M_Iter). Min and Max denote the min and maxi values of the accelerated function”

X i , j ( C _ I t e r + 1 ) = { b e s t ( x j ) ÷ ( M O P + ϵ ) × ( ( U B j − L B j ) × μ + L B j ) , r 2 < 0.5 b e s t ( x j ) × M O P × ( ( U B j − L B j ) × μ + L B j ) , o . w . (5)

“where X_{i}(C_Iter + 1) denotes the ith solution in the next iteration, X_{i}_{,j}(C_Iter) denotes the jth position of the ith solution at the current iteration, and best(x_{j}) is the jth position in the best-obtained solution so far. ϵis a small integer number, UB_{j} and LB_{j} denote to the upper bound value and lower bound value of the jth position, respectively. μ is a control parameter to adjust the search process, which is fixed equal to 0.5 according to the experiments of this paper”.

M O P ( C _ I t e r ) = 1 − C _ I t e r 1 / α M _ I t e r 1 / α (6)

“where Math Optimizer probability (MOP) is a coefficient, MOP(C_Iter) denotes the function value at the tth iteration”.

X i , j ( C _ I t e r + 1 ) = { b e s t ( x j ) − ( M O P ) × ( ( U B j − L B j ) × μ + L B j ) , r 3 < 0.5 b e s t ( x j ) + M O P × ( ( U B j − L B j ) × μ + L B j ) , o . w . (7)

Solutions are found and improved based on the operations of multiplication and division, and then they are found using subtraction and addition operations, depending on the parameters, and solutions are optimized and measured by the fitness function [

It is a proposed algorithm which depends on the sine cosine algorithm (SCA) and the algorithm of Arithmetic metaheuristic (AOA). This algorithm has been hybridized by using properties of SCA algorithm and it is stable functions sine, cosine, confined between [−1, 1], and merging it with the algorithm of Arithmetic of random movement within a specific frame so produce an algorithm with excellent specifications that could avoid failing in local solutions as it is proved on reaching the global optimum solution during applying it on a set of states of testing to (N-P hard) optimization. As such, it has been used in code analysis and half coding by using simple substitution and the result was excellent by getting very small errors and finding half coding.

The Following Are the Basic Steps for This Algorithm SCA-AOA1) Generating the initial community, the initial community is prepared randomly.

2) Measuring the fitness for each value of initial community.

3) Optimizing the value of solution by using AOA, the value of solution or when the element is optimized by using AOA and fitness measurement for it.

4) Optimizing the optimum resulted value by using SCA, and that is done by using the functions (1) and (2).

5) Measuring the final fitness and sorting solutions.

6) Choosing the best solution.

7) Comparing the best solution with the new one, using the best one between them.

If the number of iterations is less than the permissible limit, return (3-7) and do not stop.

Tables 2-4 in it, it was shown that the proposed algorithm exceeds the original SCA algorithms for the number of elements 10, 30 and 50 elements. The results also showed the possibility of the proposed algorithm to avoid falling into local solutions and reach the best global results within the range of functions used.

It is a well-known encrypt system and the simplest kind of encryption of replacement, where each letter is replaced by another one differs from English

Function | Dim | Range | F_{min} |
---|---|---|---|

F 1 ( x ) = ∑ i = 1 n x i 2 | 30 | [−100, 100] | 0 |

F 2 ( x ) = ∑ i = 1 n ( ∑ j − 1 n x i ) 2 | 30 | [−100, 100] | 0 |

F 3 ( x ) = ∑ i = 1 n i x i 4 + random [ 0 , 1 ) | 30 | [−1.28, 1.28] | 0 |

F 4 ( x ) = ∑ i = 1 n [ x i 2 − 10 cos ( 2 π x i ) + 10 ] | 30 | [−5.12, 5.12] | 0 |

F 5 ( x ) = ∑ i = 1 n x i 2 − ∏ i = 1 n cos ( x i i ) + 1 | 30 | [−600, 600] | 0 |

F 6 ( x ) = ∑ i = 1 n | x i | + ∏ i = 1 n | x i | | 30 | [−10, 10] | 0 |

F 7 ( x ) = max i { | x i | , 1 ≤ i ≤ n } | 30 | [−100, 100] | 0 |

F 8 = 4 x 1 2 − 2.1 x 1 4 + 1 3 x 1 6 + x 1 x 2 − 4 x 2 2 + 4 x 2 4 | 2 | [−5, 5] | −1.031 |

F 9 ( x ) = − 20 exp ( − 0.2 1 n ∑ i = 1 n x i 2 ) − exp ( 1 n ∑ i = 1 n cos ( 2 π x i ) ) + 20 + e | 30 | [−32, 32] | 0 |

FUNCTION | SCA | SCA-AOA |
---|---|---|

F1 | 2.00E−30 | 0 |

F2 | 2.13E−26 | 0 |

F3 | 4.17E−78 | 3.86E−77 |

F4 | 0 | 0 |

F5 | 0.002659 | 0 |

F6 | 7.04E−20 | 0 |

F7 | 3.71E−13 | 0 |

F8 | −1.0316 | −1.0316 |

F9 | 8.88E−16 | 8.88E−16 |

FUNCTION | SCA | SCA-AOA |
---|---|---|

F1 | 1.26E−49 | 0 |

F2 | 1.72E−34 | 0 |

F3 | 1.47E−80 | 5.10E−93 |

F4 | 0 | 0 |

F5 | 0.030856 | 0 |

F6 | 1.92E−23 | 0 |

F7 | 3.66E−18 | 0 |

F8 | −1.0316 | −1.0316 |

F9 | 8.88E−16 | 8.88E−16 |

FUNCTION | SCA | SCA-AOA |
---|---|---|

F1 | 3.58E−47 | 0 |

F2 | 9.74E−40 | 0 |

F3 | 1.01E−88 | 1.28E−101 |

F4 | 0 | 0 |

F5 | 0 | 0 |

F6 | 1.15E−26 | 0 |

F7 | 2.48E−20 | 0 |

F8 | −1.0316 | −1.0316 |

F9 | 8.88E−16 | 8.88E−16 |

language latters in the Encrypted text. All the code is used in this kind of encryption is made of English language alphabet that is formed of 26 letters from A-Z. The distances and marks will be considered hidden to clarify this method, and we will deal with text as a complete one without space and marks. Let Xi be defined as a group of algebraic values [X1, X2, X3, ・・・, X26] and Y is also group of alphabet letters G(X1), G(X2), ・・・, G(X26), Where G: X → Y, where G is the function key of encryption which can be seen as substituting the letters 26 and their applications (one to one mapping). Where each letter is substituted by a letter of decoding G-1(Yi). So the cipher is being broken by inverse function G and using the inverse key to find original key that was encrypted. There are 26 ≈ 288 probability of encryption replacement could be used with a simple alphabet of these 26 letters [

The solution X_{i} is evaluated and developed depending on the using of the frequency technique of selected letter and comparing it with the original unigram of the known letter frequency used in English language which is shown in

Fitness = ∑ i , j ∈ E n 26 | actual frequency ( i ) − cipher frequency ( j ) | (8)

where the actual frequencies are the letter ones of the English language alphabet, and the cipher frequencies are the letters ones of the cipher text and the used | | absolute value.

The solutions are to be presented by using the cost. When all the relevant letters will reach the solution of encryption of encrypted text, which means that the cost = 0 or about. Each encrypted letter refers to its corresponding letter, that means the actual frequency ≈ cipher frequency for each letter used in the encrypted text. Sowe get the plain text.

The new solutions are found depending on SCA-AOA algorithm. Then, we optimize the solutions by the following steps:

M | L | K | J | I | H | G | F | E | D | C | B | A |
---|---|---|---|---|---|---|---|---|---|---|---|---|

0.024 | 0.04 | 0.008 | 0.002 | 0.07 | 0.061 | 0.02 | 0.022 | 0.127 | 0.043 | 0.028 | 0.015 | 0.082 |

Z | Y | X | W | V | U | T | S | R | Q | P | O | N |

0.001 | 0.02 | 0.002 | 0.024 | 0.01 | 0.028 | 0.091 | 0.063 | 0.06 | 0.001 | 0.019 | 0.075 | 0.067 |

X i , j ( C _ I t e r + 1 ) = { b e s t ( x j ) ( “ ÷ ” or “ + ” ) ( M O P + ϵ ) × ( ( U B j − L B j ) × μ + L B j ) , r 2 < 0.5 b e s t ( x j ) ( “ × ” or “ − ” ) M O P × ( ( U B j − L B j ) × μ + L B j ) , o . w .

(form AOA).

And SCA algorithm is used to get the best solution.

X i n e w t + 1 = { X k t + r 1 × sin ( r 2 ) × | r 3 P k t − X k t | , r 4 < 0.5 X k t + r 1 × cos ( r 2 ) × | r 3 P k t − X k k t | . r 4 ≥ 0.5

The value X i n e w t + 1 is determined within the period [0.001, 0.127].

All possible probabilities for each letter of English language are gotten. And after comparing and evaluating it, to get code breaking for eachencrypted letter to reach solution of plain text.

In this research, all processes have been used in the text by using alphabet letters of English language from (A-Z). Neglecting the spaces and punctuation marks of thesentences and paragraphs, and they have been omitted before encryption. The proposed SCA-AOA algorithm is used on the encrypted text that is exposed to a big attack and encrypted it. This was achieved by different amounts of elements of research and a number of multiple repetitions. This algorithm proved it’s capability on breaking any amount of random messages by using this kind of encryption by different kinds, with the existence of a certain error probability rate because of the fact that the taken texts do not represent all English language. Matching letters, often reached the exact solution and break the code.

The proposed SCA-AOA algorithm provides a strong tool for analyzing and breaking the code of a (simple substitution encryption) kind for its accuracy of solutions in letters frequency of English language unigram and the fitness of the function used depending on it. Duo to the accountings of the SCA-AOA algorithm and the parameters that depend on, a certain rate of error is resulted. But it is possible to adjust the fitness function relevant to this work to reach to optimum solution. As such this algorithm proved capability on overcoming the falling in local solution and reaching the global optimization value in most functions, especially the applied test, and as shown in the practice.

The proposed SCA-AOA and using it cipher text analyzing segment of developing skill book, unit 2, (L. G. Alexander), segment tittle “thirteen equal one” the text is taken from the segment and is encryption be method simple substitution and test the encryption letter as in

Standard letters | |||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|

A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z |

Cipher letters | |||||||||||||||||||||||||

O | Q | S | U | W | Z | C | Y | B | E | A | F | J | D | G | K | H | L | N | R | I | M | P | T | V | X |

The cipher text is gotten, after that the SCA-AOA algorithm is used to get the keys of cipher regarding the text by using the function fitness

Fitness = ∑ i , j ∈ E n 26 | actualfrequency ( i ) − cipherfrequency ( j ) |

After that, the generated group of solutions of the proposed algorithm has been evaluated, and after a certain repetition to get fitness function equal zero, or near it (in case of the frequency of the capitalized letters does not exactly match the frequencies of the English language letters), So the letters are matched to get on letters that the text is encrypted on it and returning it to the original text. Therefore, the plain text is recoups.

While

Lotfi Zadeh 1965 has proposed fuzzy logic depending on the theory of fuzzy sets, which is a design of classic sets generalized, and it aims to model logical thinking into a fuzzy set. Because it is based on the theory of variable values, which it could be of true values partially and wrong values partially on the contrary to the binary logic which is based on the wrong or right only. The fuzzy logic works on establishing a rough fact based on linguistic variable of Inference rules in a fuzzy set. So the element that the highly related to the membership function belongs to the scale [0,1]. The propose of the logic statement AND, OR, Min, Max and merging them together that has a huge effect in the processes used in the fuzzy set [

The adaptive optimization of the sine cosine: Arithmetic algorithm is the system of fuzzy logic with developed metaheuristic algorithm and optimizing these as a kind of algorithm of Intelligent by the assistance of fuzzy logic. The both being a general flexible computing, and having a naturally inspired feature. We use it on the conventional method especially, and generally on the problems of education, modeling, optimization and the security information as encryption and steganography. The base of this adoption takes over the application the entered

data which is considered the initial population of SCA-AOA, and the data is divided to a set of fuzzy sets by using FCM (fuzzy c-mean) method [

This algorithm has been proposed. It is inspired by the SCA-AOA algorithm with fuzzy logic. It is very similar to it with the difference that this algorithm uses the starting values in the form of fuzzy groups. Then create fuzzy relationships resulting in the SCA-AOA method and the use of logical relationships and by using the fitness function of the SCA-AOA method, then the defuzzification is done to find the true values of the solutions.

The General Outlines of This Algorithm (1) Enter the initial values.

2) Fuzziness of the initial values.

3) Use FC-MEAN to find clusters (fuzzy sets).

4) Create fuzzy relationships.

5) Use of logical operations.

6) Use an SCA-AOA.

7) Defuzzification.

8) Finding real values for solutions.

End.

It is one of the important methods for hiding information and it is the process of hiding the information inside an image or a newspaper within letters or inside an audio record or by using unseen ink [

Image is one of the most important methods of hiding information, as it is a hidden messages conveyor. It is more used in media all over the world as an encrypted message content on the form of an image, and that is because of the large spreading information on the internet as a result of the that the computer is dealing with the image as it is a three-dimensional system, each site represents a spot of light called pixel. Highly increasing the number of pixels, the image is more clear. The colors of spots are three, Red, Green and Blue (RGB) [

It is a complete reference picture quality-rating index that measures image similarity in three aspects, brightness, contrast and texture then compares between the images that have been used in hiding the encrypted text and the original one.

SIMM ( X , Y ) = L ( X , Y ) ∗ C ( X , Y ) ∗ S ( X , Y ) (9)

SIMM in range [0, 1], the higher the value, the less distorted the image.

It is one of the measurements that is used in the measurement of image accuracy and its clearness degree that is compared between the original the image and the image that the encryption is hidden inside it.

PSNR = 10 ⋅ log 10 ( MAX 2 MSE ) (10)

This shown image has been used in

And then the encryption and Steganography algorithm are used in the text inside this image to increase the security of encrypted message and to be impossible to be determined to any attack. The following steps are done restore the encryption text from inside the image and analyzing it after that, then decipher it’s cryptogram and restore it to the plaintext as follows:

1) Interring plain text and interring the image that is requested hide the text in.

2) Ciphering the text in method simple substitution.

3) Chang the cipher text to ASCII Code.

4) Merging the text with image in hiding way.

5) Getting the image contain hide encrypted text.

6) Separate the encrypted text from the image.

7) Restoring ASCII Code to encrypted text.

8) By using SCA-AOA algorithm and in another direction fuzzy SCA-AA to break the encrypted text.

9) Restoring plain text.

In the application, we get:

PSNR = 90.9247.

SIMM = 1.000.

I would extend my high thanks and appreciation to the supervising, Prof. Dr. Ban Ahmed Mitras, who has never been late in providing assistance, in addition to the good directives and valuable advice that contributed to the completion of this paper. Finally, I thank everyone who taught me a letter, my teachers, lecturers and professors. Please accept my sincere regards.

The authors declare no conflicts of interest regarding the publication of this paper.

Khalaf, A.H. and Mitras, B.A. (2021) Use Two Hybrid SCA-AOA and Fuzzy SCA-AOA Algorithms in Information Security. Open Access Library Journal, 8: e7339. https://doi.org/10.4236/oalib.1107339