Linear Congruence ax ≡ b ( mod n ) Solver

Although there are existing methods for solving linear congruence ax ≡ b (mod n), finding solutions still remain difficult especially when the modulus n is large. Thus, this paper aimed to develop a linear congruence solver that will provide step by step solutions even for large modulus n. The linear congruence solver was based on alternative numerical method devised by the researcher and was developed using Microsoft Visual Studio C# programming language. The system was tested using ISO 9126 standard questionnaire for software quality characteristics such as functionality, reliability, and usability. The result of the evaluation shows that the developed linear congruence solver is highly functional, highly reliable and highly usable. The use of linear congruence solver as an instructional aid for instructors and students is highly recommended.


Introduction
In today's modern age, information security is a major challenge in the field of internet and network application.With the development and advancement of the internet and electronic commerce, large volumes of personal and sensitive information are being electronically transferred and stored everyday.Thus, the security and privacy in electronic communication and the need to protect these information when they are being transmitted become an important issue to consider.Using the process of encryption and decryption, cryptography makes communications indecipherable to all except authorized parties [1].Cryptography is widely used tool which secures the information by protecting its confidentiality as well as the integrity and authenticity of data from the attack of intruders [2,3].With cryptography, electronic data transmitted in correspondence, online shopping, financial transactions such as online banking or even in social media account passwords are secured from unauthorized users in data communication [4].
There are two broad categories of cryptography systems.One is a symmetric-key systems that use a single key used by both sender and recipient, and the other is public-key systems that uses a public key which can be widely known and a private key which is being used only by the receiver of messages [5].An example of the symmetric-key system is Caesar's cipher, a shift cipher in which f(p) = (p + k) mod 26 [6].RSA®, named after its inventors Rivest, Shamir and Adlemann in 1978 is an example of public key cryptosystem.In RSA system, private key consists of two prime numbers p and q while a public key is a number n which is a product of p and q and another number e which is a number relatively prime to (p -1)(q -1) [7].
Linear congruence play a very important role in cryptographic system.It is widely used in the encryption and decryption of codes in public key cryptosystems like the Rivest Shamir Adlemann (RSA) system [6,7].
Because of this, numerous researchers and mathematics educators have been interested in studying and developing methods for solving linear congruence ax ≡ b (mod n).A standard method of solving linear congruence involves the use of multiplicative inverse of a modulo n.Another is an approach which translates the given congruence into Diophantine equation ax + by = c to solve linear congruence and solved using Extended Euclidean Algorithm [8,9].Remodulization method, a novel solution for linear congruence which characterizes the conditions under which solutions exists and then determines the solution space [10].An algebraic method for solving linear congruence was introduced in 2014.This method translates the linear congruence into a algebraic linear equation x = b+nq, where b is the residue, n is the modulus and q is any arbitrary integer.After translating into linear equation, the equation is then solved algebraically [11,12].
Although there are existing approaches developed, finding solutions to congruence still remain difficult especially on the part of the students.This is because the methods make use of complex algorithms.Many computer programmers have also developed linear congruence calculators that provides congruence class solutions but failed to show the step by step procedures for solving such problems.Thus, this paper aimed to devise a computer program that solves ax ≡ b (mod n) in a step by step fashion based on an alternative method that solves complex linear congruence problems.

Objectives of the Study
This study aims to develop a linear congruence solver using C# programming language and evaluate the developed system using the ISO 9126 standard questionnaire for software quality characteristics such as functionality, reliability, and usability.

Project Development
C# (C Sharp) is an object-oriented programming (OOP) language from Microsoft that combines the computing power of C++ and the programming ease of the Visual Basic.C# provides an advanced code editor, convenient user interface designers, integrated debugger, and many other tools to make it easier to develop applications based on the C# language and the .NET Framework.With these features, C# was chosen as the programming language in developing linear congruence ax ≡ b (mod n) solver.The system was coded and constantly improved using various types of testing methods to completely attain the desired goals.

User Interface
User interface include graphical user interface (GUI) which is a human-computer interface that uses windows, icons and menus which can be manipulated by a mouse.It is the most important part of an application and it is certainly the most visible.To the user, the interface is the application they probably are not aware of the code that is executed behind the scene.
The interface of the developed linear congruence solver contains three textboxes for inputting the value of a, b and n.It has three buttons: print, solve and clear buttons.Solve button is used for solving the given linear congruence ax ≡ b (mod n) inputted in the textboxes.Once the solve button is clicked, a step-by-step solution will appear if the given congruence is solvable.If it is not solvable, a label will appear that it has no solution and the reason why it is not solvable.A warning will also appear if the solve button is clicked without the complete values for a, b and n.The print button is used to preview and print the solutions of the given congruence.On the other hand, the clear button is used to delete previous data.

Operation and Testing
After the development, a test case was conducted.The researcher presented the system to a panel for preliminary evaluation.Some computational errors were found out during the technical presentation.Series of trials and improvement were done to correct the errors and improve the functionality of the system.

System Evaluation
The linear congruence solver was evaluated using the ISO 9126 standard questionnaire [13] in terms of functionality, reliability and usability.The evaluators were 5 IT experts, 10 Mathematics faculty and 25 Mathematics students.Five-point Likert scale was used to evaluate the system: 4.50-5.00-Very Effective; 3.50-4.49-Effective; 2.50-3.49-Moderately Effective; 1.50-2.49-Slightly Ineffective and 1.00-1.49-Ineffective.Result of the evaluation was tabulated and treated statistically using SPSS software.

Evaluation of the Linear Congruence Solver
To test the effectiveness of the solver, an evaluation of its functionality, reliability and usability was conducted.This was evaluated by a panel of IT experts, Mathematics faculty and students.

Functionality
Table 1 presents the results of the evaluation of the functionality of the system.As shown, the system was rated "very effective" by the IT experts (5.00), Mathematics faculty (5.00) and Mathematics students (5.00).
This implies that the system functions according to its specified purpose and produces accurate solutions to the linear congruence problems being encoded in the system.The evaluators believes that the system is very functional and can serve its purpose as a supplemental instructional material in teaching linear congruences.

Reliability
Table 2 shows the results of the evaluation of the reliability of the system.As presented in the table, the linear congruence solver was rated "effective" by the IT experts (4.30), Mathematics faculty (4.33) and Mathematics students (4.27).
This implies that the system has the ability to maintain the service and can manage and recover from factors that may affect its failure.Although the system can be operational even in the event of minor system, further improvement on the system may be considered to solve the problems encountered and provide reliable and efficient results.

Usability
As shown in Table 3, in terms of usability, the system was rated by IT experts (4.87) as very effective, by Mathematics faculty (5.00) as very effective and by Mathematics students (4.80) as very effective.This means that the system is user-friendly, easy to operate and does not require learning effort for different type of users.

Conclusions and Recommendations
A linear congruence solver of ax ≡ b (mod n) showing step-by-step solutions was successfully developed using the C# programming language.The system met its objective of providing accurate and reliable congruence classes solutions for linear congruence problems.The overall results of the evaluation of the system passed software quality characteristics of functionality, reliability and usability.It is highly recommended that the linear congruence solver be integrated in teaching Number Theory as a supplemental instructional material.