Abstract
Tuberculosis (TB) stands as the second leading global infectious cause of death, following closely behind the impact of COVID-19. The standard approach to diagnose TB involves skin tests, but these tests can yield inaccurate results due to limited access to healthcare and insufficient diagnostic resources. To enhance diagnostic accuracy, this study introduces a novel approach employing a Bipolar Fuzzy Utility Matrix Inference System (BFUMIS) and a Bipolar Mamdani Fuzzy Inference System (BMFIS) to assess TB disease levels. By considering factors associated with the causation of TB, the study devises suitable membership functions for bipolar fuzzy sets (BFS) using both triangular and trapezoidal fuzzy numbers. Using a point factor scale, the study clusters the rules systematically and assesses the level of uncertainty within these grouped rules by utilizing bipolar triangular fuzzy numbers (BTFN). To handle the BTFN, this study proposes converting bipolar triangular fuzzy into bipolar crisp score (CBTFBCS) algorithm as a defuzzification method. The optimal bipolar fuzzy utility sets (BFUS) are determined from the bipolar fuzzy utility matrix to identify patients’ TB disease levels. These sets play a pivotal role in characterizing the severity of TB disease levels in patients. Additionally, rigorous validation of the utility framework is accomplished through measures of bipolar fuzzy satisfactory factors and sensitivity analyses. Furthermore, the study introduces the BMFIS, which presents a novel perspective on the conventional fuzzy inference system. This innovative system integrates the Mamdani fuzzy inference system (MFIS) into a bipolar fuzzy context, enriching the diagnostic process with enhanced insights. To demonstrate the efficacy of the proposed methods, extensive validation is carried out using actual clinical data. The performance metrics used in this validation effectively demonstrate the superiority of the proposed approach.
Keywords
Introduction
Tuberculosis (TB) is an exceptionally contagious disease primarily caused by the bacterium Mycobacterium TB, posing a significant public health challenge worldwide. It primarily affects the lungs and has the potential to impact other body organs, including the kidneys, spine and brain. TB can attack anyone, but individuals with low immunity or living in crowded and unsanitary conditions are at higher risk. The symptoms can vary but commonly include coughing, chest pain, coughing up blood, fatigue, fever, chills, night sweats, weight loss, loss of appetite and shortness of breath. TB is not transmitted through casual contact; instead, it spreads via prolonged and close exposure to an infected person, especially in crowded and poorly ventilated settings. Individuals working or living in such environments and those in close contact with TB patients or HIV-positive individuals face a higher risk of contracting the disease. The two primary organizations involved in TB control in India are the revised national TB control programme (RNTCP) and the TB Association of India. These organizations strive to increase public awareness about TB, offer medical assistance to patients and conduct research in the field of TB. They have played a crucial role as major contributors to TB control programmes in India, working tirelessly to make the country TB-free. Despite their efforts, India continues to have the highest burden of TB in the world, with around 2.64 million cases estimated in 2020. Controlling TB presents numerous challenges, encompassing drug-resistant strains like multi-drug-resistant TB and extensively drug-resistant TB, as well as co-infections with HIV. Additionally, there is a need for improved diagnostic tools and vaccines. To deal with such complex situation, an effective fuzzy inference system (FIS) can be designed.
The use of the FIS can assist in detecting the levels of TB disease in patients, facilitating early identification and diagnosis of the illness and consequently resulting in improved treatment outcomes. Fuzzy logic is particularly advantageous in medical diagnosis, where data is imprecise or uncertain, as it enables accurate and informed decisions. The implementation of a bipolar fuzzy inference system (BFIS) and utility matrix can further enhance the precision of the diagnosis and ultimately contributing to the eradication of TB. In the following part, a detailed literature review on the FIS is conducted.
Literature review
The primary focus of this work is on TB diagnosis using the bipolar fuzzy utility matrix inference system (BFUMIS) and the bipolar Mamdani fuzzy inference system (BMFIS). Therefore, this section provides an overview of relevant work on TB, it is divided into two subsections. The first subsection explores TB and several disease using various kinds of FIS in decision-making and the second subsection discusses decision-making in a bipolar fuzzy context.
Impact of fuzzy inference system on decision-making
A sophisticated decision-making system known as FIS uses fuzzy IF-THEN rules to draw conclusions from ambiguous or uncertain data. The procedure includes a few steps, making it a potent tool with real-world applications in the diagnosis of a variety of medical conditions. Early detection and treatment of TB has proven particularly useful. Arji et al. [1] reviewed articles from 2005 to 2019 and found that FIS is commonly used for diagnosing diseases like TB, dengue and hepatitis. Medeiros et al. [2] presented a FIS for real-time medical diagnoses, optimizing health costs and resources based on real data. It supports qualified interview decisions, creating a foundation for hospital administrators to enhance processing techniques and provide higher quality services to patients. The system automates patient-risk-factor delineation during interviews, reducing the need for doctors and creating cost-saving opportunities for the hospital. Sari et al. [3] compared the accuracy of three different methods for diagnosing TB in children using Mamdani, Sugeno and Tsukamoto. Due to its ability to describe rules more closely than the other two methods, the Sugeno FIS was found to be the most accurate method. An accurate TB diagnosis in children is critical for preventing TB-related deaths and identifying risk factors that assist in identifying individuals who are at higher risk of developing TB and taking necessary preventive measures. Kesuma et al. [4] used Mamdani FIS to predict TB prognosis based on alcohol reduction, immunity level, good nutrition and medication adherence. The predictions were classified into four categories: very poor, poor, good, or very good. Jain [5] and Srivastava et al. [6] used the utility matrix in a FIS to address medical problems at produced maximum accuracy than the traditional FIS method. Fale et al. [7] contracted an expert system for prescribing drugs to people with allergies. They used both Mamdani and Sugeno FIS, as well as new algorithms, forward and backward chaining approaches and mechanisms for managing allergies.
Recently, neutral network concepts have been widely utilized in FIS to obtain effective results. Ekata et al. [8] explored the use of the neuro-fuzzy inference system (NFIS) to study pulmonary TB. The system calculates the TB risk quotient using patient symptoms, making accurate diagnosis easier. The addition of a hybrid learning algorithm further enhances output accuracy. Ansari [9] presented a neuro-fuzzy system for TB diagnosis. It employs a rule-based fuzzy approach that takes symptoms as input and potential cures or doctor referrals outputs. The adaptability of the system is determined by its decision-making ability and neuro-fuzzy learning. An adaptive neuro-fuzzy inference system (ANFIS) is a hybrid system that combines fuzzy logic and neural networks to create a more flexible and accurate modelling approach. ANFIS can adjust its parameters based on training data to better capture complex relationships in the data. In 2013, Ucar et al. [10] developed a TB diagnosis system using the ANFIS, an adaptive network built on a FIS. The most important characteristics were chosen using a ranking algorithm and it was discovered that ANFIS correctly classified patients with TB. In 2020, an estimated death rate due to TB was 1.5 million, with children under 15 accounting for around 80,000 of those deaths. Due to its often-undiagnosed nature in children, TB is vulnerable and has a higher mortality rate for this population. Detecting and treating TB in children at an early stage is extremely important.
Fuzzy expert systems (FES) handle knowledge representation, reasoning uncertainty and imprecision with fuzzy logic. Expert systems and fuzzy logic make decisions from ambiguous data. Phuong et al. [11] employed medical knowledge-based systems to enable tasks like interpreting medical findings, syndrome differentiation, disease diagnosis, treatment selection and real-time patient data monitoring. Hossain et al. [12] used the belief rule-based expert system (BRBES) to diagnose TB. The fuzzy rule-based expert system (FRBES) was found to be more accurate and transparent in its reasoning than the BRBES. The system was better at predicting the occurrence of TB than it was at diagnosing it. Srivastava et al. [13] emphasized the complexity of hypertension diagnosis due to uncertainties and some factors. They proposed a FES that effectively handles the complexity, which has been validated by medical experts for its user-friendly approach. Lim et al. [14] used a hierarchical FIS for detecting arthritic disease, while Sanchez-Pedraza et al. [15] developed an interval-valued FIS for diagnosing cardiovascular disease. Tsipouras et al. [16] used a fuzzy rule-based decision support system (DSS) to detect coronary artery disease. FIS is also used for patient data management and disease diagnosis. Giovanni et al. [17] designed the clinical decision support systems (CDSSs) for evaluating and monitoring kidney-transplanted patients. Shaban [18] proposed a hybrid diagnosis strategy (HDS) that combines FIS and deep neural networks to detect diseases. The HDS weighs attributes and rules using the feature connectivity graph (FCG). Narasimhan et al. [19] explained that the progression of TB bacilli to active disease is influenced by exogenous and endogenous factors, including sputum bacillary load and proximity to infectious cases. Emerging variables, socioeconomic factors and health system issues contribute to increasing susceptibility.
FIS and MCDM can solve complex decision-making problems with uncertainty, imprecision and multiple criteria. This integration enhances multi-criteria decision modelling in real life. Stephen and Felix [20] designed a FAHP system that demonstrated superior performance in identifying cardiovascular disease, as confirmed through sensitivity and comparative evaluations. Inhaling airborne droplets from an infected person’s cough or sneeze causes TB, which leads to a lung infection. Similarly, lung infection is a major symptom of COVID-19 and people who have both TB and COVID-19 are at high risk. During the lockdown, the Indian government relaxed certain protocols to control the spread of the coronavirus. Devi et al. [21] conducted a study to assess the impact of relaxing COVID lockdown protocols in India. This evaluation was carried out within an intuitionistic fuzzy framework using the DEMATEL method. To identify stroke-prone countries, Ezhilarasan et al. [22] investigated WASPAS method using heptagonal fuzzy numbers.
Role of bipolar fuzzy set on decision-making
A bipolar fuzzy set (BFS) is an extension of the fuzzy set in which an element’s membership degree can be represented by two values, indicating positive and negative membership degrees. This adaptable version of classical sets and traditional fuzzy sets capture uncertain or ambiguous information in both positive and negative contexts. Zhang [23] introduced BFS, assigning positive membership to [0,1] and negative membership to [-1,0]. Various BFS representations exist, including intervals, trapezoidal fuzzy numbers and α-level fuzzy numbers, along with techniques for bipolar aggregation and linguistic description.
Numerous studies explore BFS concepts. Recently, Shumaiza et al. [24] applied the fuzzy VIKOR method with bipolar fuzzy numbers to analyze challenges in thermal power plants and healthcare waste treatment. Ghanbari et al. [25] proposed a method for comparing bipolar L.R. fuzzy numbers and a direct formula for comparing BTFN. Ezhilarasan and Felix [26] designed bipolar fuzzy ARAS method to identify the most influencing TB comorbidities with the criteria of top ten affected Indian states.
Deva and Felix [27] employed BFS in graph theory, studying the fuzzy DEMATEL method in a bipolar fuzzy environment. Garai and Garg [28] presented an innovative MCDM technique using bipolar fuzzy numbers to select COVID-19 treatments in India. Deva and Felix [29] utilized a bipolar fuzzy ARAS method to analyze the COVID vaccine’s impact on a bipolar fuzzy p-competition graph. Mahmood et al. [30] defined bipolar complex intuitionistic fuzzy soft sets (BCIFSSs), merging bipolar complex fuzzy sets, intuitionistic fuzzy sets and fuzzy soft sets. This method leverages complex numbers to manage decision-making uncertainty and incorporates positive and negative aspects for membership and non-membership grades. Nithyanandham et al. [31] designed a bipolar intuitionistic fuzzy graph based DEMATEL technique to identify flood vulnerable zones. This technique analyzes the zone’s membership and non-membership grades from a positive and negative perspective.
This review shows that the existing studies have some shortcomings, such as: i) the concept of the utility matrix has not been used in FIS; ii) the bipolar concepts in FIS have not been studied; iii) the use of bipolar fuzzy concepts in diagnosing TB; and iv) the integration of bipolar fuzzy, utility matrix and FIS concepts has not been studied.
To overcome these shortcomings, the proposed study employed the novel concept of the BFUMIS. It offers an efficient result for FIS by examining bipolar fuzzy perceptions (i.e., satisfaction and dissatisfaction). It helps to diagnose the TB level in an effective manner.
The motivation of the work
An extensive review of the existing literature reveals that many researchers have delved into the realm of TB disease. However, the subsequent factors highlight the motivation for this study. TB remains a significant global health issue and researchers have utilized a variety of fuzzy techniques to examine its diagnosis. Nonetheless, the exploration of a proficient testing approach within the realm of bipolar fuzzy conditions has been lacking. This underscores the necessity for a practical method to address TB within the framework of BFIS. Fuzzy logic is frequently used in disease diagnosis, with FIS mapping inputs to outputs. FIS is capable of handling both crisp and fuzzy inputs. By considering positive and negative membership degrees, BFS provide a more accurate analysis than traditional fuzzy sets. Additionally, the use of the Mamdani fuzzy inference system (MFIS) in TB-related issues has been lacking in a bipolar fuzzy context. As a result, the goal is to assess the conventional MFIS from both positive and negative perspectives. This approach has the potential to improve the accuracy of diagnosing TB severity in patients using a BFIS and BMFIS.
Need of bipolar fuzzy set
The crisp set relies on Boolean logic, where each element within the universe is assigned a value of either 0 or 1. This value indicates whether the elements belong to the set 1 or do not belong to it 0. Due to its sharp boundaries, it provides full membership. It is also termed a classical set or ordinary set and serves as the fundamental study of fuzzy sets. In 1965, Lofti A. Zadeh introduced the theory of fuzzy sets. A fuzzy set is a collection of ordered pairs of elements and their corresponding degrees of membership. It allows the elements to have different membership grades; the membership function defines the value between 0 and 1. Due to its vague boundaries, it provides partial membership. A BFS is the extension of a fuzzy set. It defines the value between -1 and 1. The BFS contains the elements and their corresponding positive and negative membership grades. Due to the extra accuracy of the BFS, it is incorporated into the FIS to determine the diagnosis system. The FIS uses the “IF . . . THEN” rules along with connectors “OR” or “AND” for drawing essential decision rules. From the literature, it is observed that the FIS is carried out to detect the presence or absence of disease in a positive way. Here, the bipolar fuzzy technique is utilized in designing a FIS to analyze both positive and negative perceptions of the TB disease. Then, the bipolar fuzzy inference system (BFIS) is incorporated along with the bipolar fuzzy utility matrix (BFUM) to diagnose the TB level of the patients. The FIS produces only positive outcomes, but the proposed BFIS produces positive and negative outcomes, which analyze wider information than the traditional FIS.
Contribution to the work
The combination of FIS and BFS is proposed to determine TB levels in patients. To design any model, the input parameters play a significant role and influence the outcomes. Here, the TB level is measured by considering the significant attributes that cause TB disease as the input parameters. The attributes are collected from the literature, WHO, RNTCP and the TB association. The selected symptoms are indicated as attributes. The vagueness of the detection problem is handled by BFS, which considers the belongingness grade in both positive and negative sights. The attributes are scrutinized using the appropriate bipolar triangular and trapezoidal fuzzy membership functions. Generally, the FIS builds the relationship between the attributes using the ‘AND’ operation. Here, this FIS is designed using the BFS, named BFIS. Then, the bipolar IF-THEN rules are framed. Since reducing the IF-THEN rule is challenging, the point factor scale is used to group the rules. The five outputs are classified under a BFUM to measure the accurate TB level. Each of the outputs is assigned a BTFN. Additionally, converting bipolar triangular fuzzy into the bipolar crisp score (CBTFBCS) algorithm is proposed to defuzzify the BTFN based on the CFCS algorithm. The outcomes are finalized using the optimal bipolar utility sets. Using the proposed method, the level of TB disease is detected through the attributes. To show the efficiency of the proposed method, the outcomes are probed under bipolar fuzzy satisfactory factor and sensitivity analysis. Using actual data, the performance measure is used to verify the robustness of the proposed method. The proposed BMFIS is used to assess the existing Mamdani fuzzy inference system (MFIS) from both positive and negative perspectives.
Novelty of the research
By scrutinizing the literature, it is observed that the FIS has been widely utilized for diagnosing various human diseases. It divulges the diagnostic level of the diseases by analyzing only the positive perception. Still, the bipolar fuzzy concept has not been involved in any disease-diagnosing system. This study propose a novel method by incorporating the bipolar fuzzy context into the FIS to form a BFIS. Therefore, the bipolar IF-THEN rules have been considered positively and negatively, which adopt more information and provide more accurate outcomes than the usual FIS. Moreover, the utility matrix is involved in the proposed BFIS to group the number of IF-THEN rules into a finite number of groups, which do not impact the outcomes. The utility matrix also aids in easy evaluation when there are more IF-THEN rules. A new defuzzification technique converting bipolar triangular fuzzy into the bipolar crisp score (CBTFBCS) algorithm is proposed to defuzzify the BTFN into a crisp number and its numerical illustration is also derived. The satisfactory factor, which is utilized to validate the outcomes, is used here to check the proposed BFIS by introducing the satisfactory factor in the bipolar fuzzy context as bipolar fuzzy satisfactory factor. The MFIS has been enhanced with the inclusion of the bipolar fuzzy concept, resulting in the development of BMFIS. This enables the measurement of both positive and negative perspectives and is utilized in evaluating the TB level of patients.
The paper is organized into several sections: Section 2 explains the fundamental theory of the bipolar fuzzy set; Section 3 demonstrates a novel defuzzification technique for BTFNs and proposed methods using inference systems in bipolar fuzzy contexts; Section 4 provides an illustration for the proposed methods; Section 5 discusses the performance measure; Section 6 presents the results and discussion; and Section 7 includes the conclusion and future directions.
Preliminaries
In this part, the basic definitions of the research work are given.

Bipolar triangular fuzzy number.
This section presents three methods. The initial part introduces a novel defuzzification algorithm. The subsequent part discusses the approach of a bipolar fuzzy utility matrix inference system (BFUMIS). Finally, the third section provides bipolar Mamdani fuzzy inference system (BMFIS). This algorithm highlights the reduction of rules and the computation of classic FIS from both positive and negative perspectives.
The proposed CBTFBCS algorithm
Generally, defuzzification transforms imprecise data into precise data. According to fuzzy methods, defuzzification is the process of transforming a fuzzy number into a crisp number. Some existing defuzzification techniques are the centre of area, centre of sum, weighted average and maxima methods. As bipolar fuzzy is an emerging concept, there is still a lack of bipolar fuzzy defuzzification methods. The papers [35, 36] disclose the defuzzification techniques for triangular and intuitionistic fuzzy numbers, which exist as the basis for proposing the CBTFBCS algorithm. The proposed CBTFBCS algorithm converts the BTFN into the bipolar fuzzy number (BFN). Let
Each member of the bipolar triangular fuzzy number is normalized.
In the matrix T, (0.75, 0.90, 1.00) (0.00, 0.10, 0.20) denotes the entry of S3 and R1. This BTFN is defuzzified using the proposed CBTFBCS algorithm.
Method-I: The proposed bipolar fuzzy utility matrix inference system
The possible attributes or input parameters A ={ A1, A2, …, A f } are chosen based on the field experts E ={ E1, E2, …, E d }.
For the considered attributes, the bipolar fuzzy linguistic terms or sub-attributes are classified.
The appropriate bipolar fuzzy membership functions (μ+ (x) , μ- (x)) are framed for all the bipolar fuzzy linguistic terms.
All the classifications of the inputs are combined using AND operation to form the bipolar fuzzy linguistic strings
All the bipolar fuzzy linguistic strings are grouped to reduce the number of strings based on the point factor analysis. The main advantage of using point factor analysis is that it can reduce the strings without affecting the result accuracy and it aids in determining the relative score of a string. The grouped strings are indicated as R g , g = 1, 2, …, n.
The outputs for the grouped strings are classified into linguistic variables {V1, V2, … , V m }. These outputs provide the strength of the grouped strings.
BLUM is considered for the grouped strings. It divulges the relationship between the possible outputs of the grouped strings in a linguistic manner.
Using the linguistic scale, the BLUM is converted into the BTFUM.
Where T
Through the proposed defuzzification algorithm in subsection 3.1, the BTFUM is defuzzified and converted into a bipolar fuzzy utility matrix (BFUM).
The additive sum of μ+ (x1) ⊕ μ+ (x2) = μ+ (x1) + μ+ (x2) - μ+ (x1) μ+ (x2) and μ- (y1) ⊕ μ- (y2) = - ((μ- (y1) + μ- (y2) - μ- (y1) μ- (y2)).
The bipolar fuzzy maximizing set is denoted as
The optimal bipolar fuzzy utility set U iO , i = 1, 2, …, n are determined from the maximum sets
The MFIS is a control system technique that combines linguistic control rules from expert human operators. It involves fuzzification, inference engine, decision-making unit and defuzzification. BMFIS incorporates the MFIS into a bipolar fuzzy context, allowing for a wider range of information to be analyzed than the conventional MFIS.
The bipolar consequent part is framed for each bipolar fuzzy linguistic string, chooses the possible output, classifies it into linguistic terms and provides a suitable bipolar fuzzy membership function.
The process of combining the attributes in rules is known as aggregation. The most common method is to cut the membership function at the level of the antecedent truth. This method is called clipping. The main advantage is that it involves less complex and faster calculations. It generates an aggregated output surface. The other aggregation method is scaling, which scales down the entire structure to the assigned membership degree.
The most precise way to find the solution is when it is a single number. The bipolar defuzzification transforms the bipolar fuzzy into a bipolar crisp output. Therefore, the aggregated output is converted into a bipolar crisp value. The centre of area method is utilized to defuzzify the bipolar fuzzy outputs.
The final outcomes are obtained based on the bipolar defuzzified values. The flow of the two approaches is represented in Fig. 2. The short algorithm of both methods is given below.

The framework of the proposed method.
TB is a globally lethal disease and knowledge of a patient’s disease level significantly reduces mortality rates. The procedures of the proposed methods provide a comprehensive analysis for detecting a patient’s TB level. TB data is obtained from multiple sources, including expert opinions and standard healthcare portals such as IHME and WHO. The patient information is acquired from the TB association and accessed through https://tbfacts.org/tb-statistics-india/ on a state-by-state basis in India.
The bipolar fuzzy utility matrix inference system
A notable symptom of TB is a cough, considered the main route for transmitting Mycobacterium TB from a human to the environment, resulting in the release of airborne particles into the environment. A high level of cough is a chronic cough lasting more than eight weeks [37]. The main reason for transmission of TB infection is the release of bacilli from the lungs into the surrounding airborne in the possible form during air travel. The case study was conducted on 63 patients based on the cough frequency for three consecutive nights (11 pm to 7 am). If the patient coughs < 12 times, it considered a low prevalence of TB; coughing > 48 times is considered a 44% presence of TB. But the role of cough in the spread of TB is relatively small. Table 1 exhibits the classification of cough in the three fuzzy categories, including positive and negative rates and a graphical representation of cough is represented in Fig. 3.
Cough
Cough

Bipolar view of cough.
(i) Cough - positive membership function
Weight loss is an important symptom of TB. According to Los Angeles research, when a patient loses weight, nearly 44% and 40.6%, anorexia may lead to TB, Wasting is another term for losing weight. Moreover, it leads to impairment of the immune system and malnutrition. The WHO assortments are BMI < 18.5 kg/m2 is underweight, BMI < 18.5 and < 30 kg/m2 is normal weight and BMI > 30 kg/m2 is obese. Generally, the weights are calculated by kilogrammes as well as percentages. Pham et al. [38] studies reported TB treatment weight after two months: 31.9% of patients gained 5% or more weight, but 62.4% of patients had gained at least 5% body weight. Table 2 shows the classification of weight loss in the three fuzzy sets, including positive and negative rates and a graphical representation of weight loss is represented in Fig. 4.
Weight loss

Weight Loss in positive and negative views.
(i) Weight loss - positive membership function
(ii) Weight loss - negative membership function
Fever is the first sign of recognizing diseases present in the human body. One of the most common medical symptoms is fever, which rises in the normal body’s temperature due to a high level of disease. In humans, the normal temperature ranges between 37.2°C and 38.3°C (99.0°F and 100.9°F). But fever rarely reaches temperatures above 41°C (107°F). Most health problems can cause a fever, including bacterial infections, the common cold, meningitis, COVID-19 and TB Fever is one of the symptoms of TB, which is a severe disease that affects up to 75% of people. Table 3 exhibits the classification of fever in the three fuzzy sets, including positive and negative values and the graphical representation of membership functions of fever level is represented in Fig. 5.
Fever

Fever positive and negative views.
(i) Fever - positive membership function
The age parameter plays a significant role in all diseases. Demographic factors such as age and gender may influence TB incidence. The TB-affected male percentage is high compared to females, with a sex ratio of 1.7 : 1. There were 5497 TB cases reported in Nanshan between 2011 and 2016, with the following general characteristics: 25-34 years and 15-24 years, which together made up 36.9% and 29.0% of all TB cases, respectively, were the two age groups with the highest percentage of cases. Approximately 44.8% of pulmonary tuberculosis cases were diagnosed clinically without microbiological confirmation. Table 4 exhibits age classification in the three fuzzy sets, including positive and negative rates, as well as a graphical representation in Fig. 6.
Age

Age positive and negative views.
(i) Age - positive membership function
Sweating profusely and severely at night, such that the sweat may wet the night clothes and bedding, is a symptom of TB and it’s often a sign that the body’s infection levels are at an alarming rate. Although TB is the most common cause of night sweats, it is rarely found to be the cause in modern practice. Table 5 exhibits the classification of night sweats in the three fuzzy grades, including positive and negative rates and a graphical representation of night sweats is represented in Fig. 7.
Night sweat

Night Sweat positive and negative views.
(i) Night Sweat - positive membership function
Sputum is a major sign of TB disease. Sputum is a thick fluid produced in the lungs and the airways that lead to TB. Sputum is a very common and hazardous symptom. People who have TB contain sputum and also exhibit other symptoms. The first test procedure to detect a high rate of TB infection in most countries is sputum smear microscopy. Sputum collection and testing are basic tests in rural and urban India. Table 6. exhibit the classification of sputum in the three fuzzy categories, which include positive and negative rates and a graphical representation of sputum is represented in Fig. 8.
Sputum

Sputum positive and negative views.
(i) Sputum - positive membership function
The severe chest pain under the breastbone may feel like pressure, squeezing, tightness, or crushing. Pleural chest pain has been associated with TB and is superficial to a diseased lung. Besides TB, chest pain is also common in many other diseases like heart disease, anxiety or muscle injury, indigestion and TB. Shortness of breath and chest pain are the common symptoms of pulmonary TB. Table 7. portrays the classification of chest pain in the three fuzzy categories, including positive and negative rates and a graphical representation of chest pain is represented in Fig. 9.
Chest pain

Chest pain in positive and negative views.
(i). Chest pain - positive membership function
(ii) Chest pain - negative membership function
(Grade I (+, -)) NightSweat and (Positive Grade 1+(+, -))Sputum and (Grade 1+(+, -))ChestPain
(Grade I (+, -)) NightSweat and (Positive Grade 1+(+, -)) Sputum and (Grade 2++(+, -))ChestPain
(Grade I(+, -)) NightSweat and (Positive Grade 1+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
(Grade I(+, -)) NightSweat and (Positive Grade 2+(+, -))Sputum and (Grade 1+(+, -))ChestPain
⋮
(Grade III(+, -))NightSweat and (Positive Grade 2+(+, -))Sputum and (Grade 2++(+, -))ChestPain
⋮
(Grade III(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
⋮
(Grade II(+, -))NightSweat and (Positive Grade 2+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
(Grade II(+, -)) NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 1+(+, -))ChestPain
(Grade II(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 2++(+, -))ChestPain
⋮
(Grade III(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
⋮
(Grade II(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
⋮
(Grade III(+, -)) NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
⋮
(Grade III(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
⋮
(Grade II(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 1+(+, -))ChestPain
(Grade III(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 2++(+, -))ChestPain
(Grade III(+, -))NightSweat and (Positive Grade 3+(+, -))Sputum and (Grade 3+++(+, -))ChestPain
where
Bipolar triangular fuzzy number
Determining the patients’ TB level is a challenging task. The patient’s data is collected based on sub-attributes through the decision-makers.
Case 1: The first patient’s data
The ranges of the input parameters for the first patient are: cough level is acute (2, 7), weight loss is low (3, 15), fever is low (97, 100), age is young (18, 54), night sweat under grade I (22.5, 39), sputum level is P grade 1+(6, 6.8) and chest pain level is Grade 3+++(69, 33). The suitable BMFs of the given data is found using the characteristic function of parameters or attributes.
Therefore, the obtained bipolar fuzzy membership grade of cough level is acute (1, - 1), weight loss is low (1, - 1), fever is low (0.66, - 0.66), age is young (0.6, - 0.8), night sweat under grade I (1, - 0.8), sputum level is P grade 1+(0.75, - 0.8) and chest pain level is Grade 3+++(0.8, - 0.68) in Fig. 10.

First patient medical information.
The overall patient medical data are evaluated using the mean operator X = (0.83, - 0.82).
The optimal outputs U
io
are determined using these bipolar utilities,
As per the proposed bipolar utility matrix approach, the patient is diagnosed with a too mild level of TB. The optimal TB level is graphically shown in Fig. 11.

Too mild level of TB.
It aids in calculating the satisfaction level of the attained result. A satisfactory factor [39] determines the satisfaction level of results through the degree of match of input values. Since the proposed approach adopts a bipolar perspective, the bipolar fuzzy satisfactory factor is utilized. The degree of match aids in identifying the minimum and maximum value in the positive and negative views, respectively. The total degree of match of input DM T is given below.
The degree of match of bipolar output DM O + and DM O - are 1 and -1, respectively; then the total satisfactory factor is D = (|DM T + - DM O + |, - |DM T - - DM O - |) = (|0.6 - 1|, - | - 0.66 - (- 1) |) = (0.4, - 0.34). The attained positive and negative values are 0.4 and -0.34, which meet the level of satisfaction. Therefore, the satisfactory factor aids in proving the accuracy level of the obtained result.
Additionally, the four patients’ medical details with their output, following from step 10 to step 12, are presented.
Case 2: The second patient’s input values
The ranges of the input parameters for the second patient are: cough level is subacute (4.5, 3), weight loss is Medium (7, 7), fever is high (101, 95), age is young (27, 61), night sweat under grade I (27, 35), sputum level is P grade 1+(4, 5) and chest pain level is Grade 1+(20, 80). The suitable BMFs of the given data is found using the characteristic function of parameters or attributes.
Therefore, the obtained bipolar fuzzy membership grade of cough level is subacute (0.75, - 0.5), weight loss is medium (1, - 0.5), fever is high (1, - 1), age is young (0.6, - 0.8), night sweat under grade I (0.4, - 0.66), sputum level is P grade 1+(0.75, - 0.75) and chest pain level is Grade 3+++(1, - 1) in Fig. 12.

Second patient data.
The BFS represents the patient’s state:
Based on the bipolar utility sets, the bipolar fuzzy maximizing sets are determined for the corresponding classified outputs.
These optimal attributes point reveal that the patient presently has a low grade of TB, both in a positive and negative view. The optimal outputs are graphically portrayed in Fig. 13.

Mild level of TB.
Bipolar fuzzy satisfactory factor: The satisfaction level of the second patient,
The attained positive and negative values are 0.6 and –0.5, which meets the level of satisfaction.
Case 3: The third patient’s input values
The ranges of the input parameters for the third patient are: cough level is acute (2, 7), weight loss is high (11, 7), fever is low (96, 100), age is old (60, 28), night sweat under grade I (22, 40), sputum level is P grade 2+(6, 77) and chest pain level is Grade 2++(52, 68). The suitable BMFs of the given data is found using the characteristic function of parameters or attributes.
Therefore, the obtained bipolar fuzzy membership grade of cough level is acute (1, - 1), weight loss is high (0.5, - 0.5), fever is low (0.33, - 0.66), age is old (1, - 0.4), night sweat under grade I (0.93, - 0.66), sputum level is P grade 2+(0.88, - 0.75) and chest pain level is Grade 2++(0.45, - 0.7) in Fig. 14.

Third patient data.
The third patient medical data of BFS:
The five bipolar fuzzy utility sets are
The maximum sets corresponding to each attribute are
The optimal outputs U
io
are determined using these bipolar fuzzy utilities,
These optimal attributes point out that the patient presently is in a moderate level of TB in the positive and negative view. The optimal TB level is graphically portrayed in Fig. 15.

Moderate grade of TB.
Bipolar fuzzy satisfactory factor: The satisfaction level of the third patient,
The attained positive and negative values are 0.67 and –0.6, which meets the level of satisfaction.
Case 4: The fourth patient’s input values
The ranges of the input parameters for the fourth patient are: cough level is chronic (7, 2), weight loss is high (17, 6), fever is high (101, 97), age is old (62, 17), night sweat under grade I (36, 18), sputum level is P grade 2+(6, 4) and chest pain level is Grade 3+++(85, 20). The suitable BMFs of the given data is found using the characteristic function of parameters or attributes.
Therefore, the obtained bipolar fuzzy membership grade of cough level is chronic (1, - 1), weight loss is high (1, - 1), fever is high (1, - 0.66), age is old (1, - 1), night sweat under grade I (0.88, - 0.64), sputum level is P grade 2+(0.75, - 0.5) and chest pain level is Grade 3+++(1, - 1) in Fig. 16.

Fourth patient information.
The BFS represents the fourth patient’s state:
The five bipolar fuzzy utility sets are
The maximum sets corresponding to each attribute are
The optimal outputs U io are determined using these bipolar fuzzy utilities,
These optimal attribute points reveal that the patient presently is in a severe level of TB in a positive and negative view. The optimal TB level is depicted in Fig. 17.

Severe grade of TB.
Bipolar fuzzy satisfactory factor: The satisfaction level of the fourth patient,
The attained positive and negative values are near 0.25 and near –0.5, which meets the level of satisfaction.
Case 5: The fifth patient’s input values
The ranges of the input parameters for the fifth patient are: cough level is chronic (7, 2), weight loss is high (7, 7), fever is high (99.5, 97.5), age is old (27, 61), night sweat under grade III (27, 35), sputum level is P grade 2+(4, 5) and chest pain level is Grade 3+++(20, 80). The suitable BMFs of the given data is found using the characteristic function of parameters or attributes.
Therefore, the obtained bipolar fuzzy membership grade of cough level is chronic (1, - 0.5), weight loss is high (0.5, - 0.75), fever is high (1, - 1), age is old (1, - 1), night sweat under grade III (1, - 0.4), sputum level is P grade 2+(0.22, - 0.5) and chest pain level is Grade 3+++(1, - 1) in Fig. 18.

Fifth patient data.
This is the 5th patient medical data of BFS:
These optimal attribute points reveal that the patient presently is in a very severe level of TB in the positive and the negative view. The optimal TB level is portrayed in Fig. 19.

Very severe grade of TB.
Bipolar fuzzy satisfactory factor: The satisfaction level of the fifth patient,
The attained positive and negative values are near 0.78 and -0.6, which meets the level of satisfaction.
The sensitivity analysis is calculated for cases 1 to 5 to verify the obtained results. The bipolar string output value is simulated and utilized in the bipolar fuzzy utility matrix. It has been proven that changes in the input parameters do not affect the optimal level of TB in patients. Figure 20(a-e) depicts the sensitivity results of cases 1 to 5.

(a-e). Sensitivity analysis output.
The processes of the MFIS [40] are incorporated into the bipolar fuzzy context to examine the rules from both positive and negative perspectives (Fig. 21).

Bipolar Mamdani fuzzy inference system.

The output of the BMFIS.
Case 1: in the first approach is considered to check the patient’s TB level through the proposed BMFIS. The state of the concerned patients in a linguistic string (Acute, Low, Low, Young age, Grade I, Positive Grade I+, Grade 3+++) occurs at
Classification of bipolar fuzzy output
The rule
Case 2: The patient is occurring the rule of at
The rule
The defuzzified value is
The achieved bipolar membership grades are 0.3 and 0.7, indicating that the patient’s TB level is classified as mild.
Case 3: The patient is occurring the rule of
The rule
The defuzzified value is
The achieved bipolar membership grades are 0.5 and 0.5, indicating that the patient’s TB level is classified as moderate.
Case 4: The patient is occurring the rule of
The rule
The defuzzified value is obtained using center of area method.
The achieved bipolar fuzzy membership grades are 0.7 and 0.3, indicating that the patient’s TB level is classified as severe.
Case 5: The patient is occurring the rule of
The rule
The center of area method is utilized to obtain the defuzzified value.
The achieved bipolar fuzzy membership grades are 0.9 and 0.1, indicating that the patient’s TB level is classified as very severe. This outcome (case 1-5) aligns with the results obtained from the initial approach of the BUMIS.
Performance measurement involves regularly evaluating outcomes to determine the effectiveness of a system. The confusion matrix is a technique used to provide a comprehensive understanding of a model’s performance by summarizing accurate and erroneous predictions. It consists of a 2 × 2 matrix with four pairs of predicted and actual values: true positive, true negative, false positive and false negative. True positives and true negatives are correct predictions, while false positives and false negatives are incorrect predictions. The performance measure of the proposed method is analyzed using the actual data. Kaggle portal data was collected from https://www.kaggle.com/datasets/victorcaelina/tuberculosis-symptoms, which contains details of 1000 patients with TB This data was used to test the effectiveness of the proposed methods and it showed that 669 data had the same positive outcomes for both the actual and method data, while 278 data had the same negative outcomes. TB is diagnosed in the actual data and model data provided, positive results come under true positive and negative results come under true negative. If the impact in the actual data is positive and the model data is negative comes a false positive and the reverse comes under false negative (Fig. 23).

Confusion matrix.
Accuracy measures how similar model data is to actual data, calculated by adding true positive and true negative cases and dividing by the total evaluated cases,
F1 Score uses the harmonic mean to evaluate model accuracy on a dataset, where a high score indicates high precision and sensitivity, while a low score indicates low precision and sensitivity. A medium score means one is low and the other is high,
The graphical representation of the scores of the performance measures is given in Fig. 24. A ROC (Receiver Operating Characteristic) curve is a graphical representation of the performance of a binary classifier system. It is a plot of the true positive rate (TPR) versus the false positive rate (FPR) at various threshold settings. (Fig. 25).

Value of the performance measures.

ROC curve.
TB is one of the world’s most dangerous infectious diseases. In 2021, India accounted for almost a fourth of the global population causing TB, i.e., 2,590,000 people infected (188 per 100,000) and 53,000 HIV people diagnosed with TB. Nearly 11,000 HIV-positive people died of TB and India has the highest TB infection rate globally. TB spreads from one person to another through coughing or sneezing. One of the most important reasons is that many people are unaware of the diagnosis method for TB and the drugs needed for treatment. In this situation, the pulmonary TB symptoms of the patients are categorized into five levels: too mild, mild, moderate, severe and very severe. Based on the field experts’ opinions, the symptoms that cause pulmonary TB are chosen as attributes. Then each selected attribute is defined with its sub-attributes and its positive and negative membership functions.
The first common symptom is cough, divided into three fuzzy categories: (a) acute, (b) subacute and (c) chronic. Weight loss is classified into three fuzzy categories: (a) low, (b) medium and (c) high. Fever is divided into three fuzzy sets: (a) low, (b) medium and (c) high. The three fuzzy grades of night sweat are: (a) grade I, (b) grade II and (c) grade III. Sputum is viewed in three categories: (a) P grade 1+, (b) P grade 2 + and (c) P grade 3 + . Chest pain is divided into three types: (a) Grade 1+, (b) Grade 2++and (c) Grade 3+++. The bipolar linguistic strings of order 5*2187 are framed through these categories. The strings with the same characteristic are identified from the constructed strings using the point factor to reduce the number of strings. After applying the point factor, 2187 strings are reduced to 15 groups under the bipolar linguistic utility matrix. Then transform the BLUM into the BTFUM. The bipolar triangular fuzzy matrix is defuzzified using the proposed CBTFBCS algorithm to develop the bipolar fuzzy utility matrix U and this matrix divulges the patients’ level of TB disease, which is defined as too mild, mild, moderate, severe, or very severe.
In case 1, the first step is to gather patient medical information from a field expert and the collected data is categorized into respective BMFs. For patient 1, cough level is acute (1, - 1), weight loss is low (1, - 1), fever is low (0.66, - 0.66), age is young (0.6, - 0.8), night sweat under grade I (1, - 0.8) sputum level is P grade 1+(0.75, - 0.8) and chest pain level is Grade 3+++(0.8, - 0.68) in Fig. 10. The averaging operator calculates the overall patient symptom in BFSs. Then the bipolar fuzzy utility sets are determined and the bipolar maximum sets correspond to each attribute obtained from the bipolar fuzzy utility sets. Finally, the optimal bipolar fuzzy utilities determine the presence of TB level in the patient. As a result, patient 1 got a too mild grade of TB in the positive and negative view in Fig. 11. The remaining four cases are depicted in Table 10.
Another four patients’ medical information and result
Another four patients’ medical information and result
The satisfaction level of the obtained result was also determined to prove the proposed system’s efficiency. All the illustrated cases meet the satisfactory factor in both positive and negative categories. The sensitivity analysis is also executed by stimulating the string values in the BFUM. The output remains the same even when the input string values are changed. Therefore, the results show that if the positive and negative views are (too mild, mild, moderate, severe and very severe), This bipolar concept in Table 10. shows the remaining four stages of the patient’s TB level. Even though the proposed system’s efficacy is shown through the bipolar fuzzy satisfactory factor, its working methodology in real-time data is also determined. The 1000 TB patients’ details were collected from the Kaggle website and implemented into the proposed system to observe the actual data and system data outcomes through performance measures.
Besides, the traditional MFIS has been incorporated in a bipolar fuzzy context to assess rules from both positive and negative perspectives and is named the BMFIS. The proposed BMFIS was applied to examine the same cases and the TB level of the first patient being observed using this system. The first four steps are similar to method I. The consequent region of the BMFIS is constructed and the strength of the rules is found through the aggregation process. The optimal outputs are determined through the defuzzification technique. The center of area method is utilized as a defuzzification method. Even though the proposed method’s efficacy is shown through the bipolar fuzzy satisfactory factor, its working methodology in real-time data is also executed. The 1000 TB patients’ details were collected from the Kaggle website and implemented into the proposed methods to observe the actual data and method data outcomes through performance measures.
The performance of the proposed model is compared with other methodologies examined by Ekara [8], Omisore [41], Vathana [42] and Er [43]. The evaluation clearly demonstrates the performance metrics of the existing and proposed model in Table 11.
Comparison of performance measure
Comparison of performance measure
Managing bipolar fuzzy information: BFS consider both positive and negative information, enabling decision-makers to convey ambiguity and uncertainty in their decision-making data. This capacity comes especially handy when handling vague or insufficient data. More flexibility and adaptability: The employed BFUM and BMFIS can identify any disease and prevent the patient’s illness from becoming worse. Minimum computation process: The maximum number of strings is separated into a finite number of strings, which helps to shorten the computation process without impacting the outcome. High accuracy level: Utilizing utility matrix concepts in a bipolar fuzzy environment and applying BMFIS principles significantly increase the accuracy level of TB disease diagnosis. Analyzing various factors: Incorporating diverse bipolar fuzzy numbers into the diagnostic procedure enables a thorough evaluation of various factors, such as clinical, laboratory and historical data, thereby improving diagnostic accuracy through the careful consideration of multiple criteria.
Disadvantages of the model
Data quality and availability: BFIS decisions rely on accurate TB data, which can be unreliable in resource-limited settings due to data challenges. Model complexity: BFIS models with multiple inputs and linguistic rules can be challenging for non-experts to manage and interpret due to their complexity. This paper streamlines the rules and if it fails to reduce rules, the accuracy level of the output may be decreased. Since the result tend on specific situations involving medical experts and clinical data as inputs.
Conclusion
TB is a major public health issue in India, with a high burden of cases and drug-resistant strains. This study aimed to identify TB presence by considering seven important attributes of the utilization of FIS in the context of bipolar. To reduce India’s TB mortality rate, a BFUM and BMFIS methods were designed to diagnose the optimal level of TB from a positive and negative perspective. A CBTFBCS algorithm was proposed for the defuzzification process within the model. A bipolar fuzzy satisfactory factor and sensitivity analysis were performed to validate the proposed model. Additionally, some performance measures were employed to highlight the accuracy of the proposed model. Further, the performance of method was compared with existing models to show the superiority of the model. In essence, this study endeavoured to enhance TB detection, thus mitigating the disease’s impact on public health.
The present study has some limitations as follows: Data variability: Geographical location, demographics and individual lifestyles are all factors that can lead to highly variable TB data. BFIS may struggle to manage this variability, resulting in less-than-ideal performance. The data collection for this study was conducted in India. The outcome may vary if the data is obtained from other countries. In order to reduce the rules, the techniques of BFUM and BMFIS are employed. The outcome may differ if an alternative technique is employed. The bipolar fuzzy context is utilized in this study. The result may vary when other contexts are considered.
The proposed work further can be implemented into the following studies. The BFIS can be extended into bipolar intuitionistic FIS to enhance the accuracy level of TB diagnosis. Some novel rule reduction techniques can be designed in the proposed model. The proposed BFIS can be utilized for diagnosing diseases like COVID-19, cardiovascular, etc. The aforementioned limitations can also be addressed in the future studies.
Declarations
Conflicts of interest
The authors declare that they have no competing interests.
Funding statement
All authors declare that there is no funding for this research paper.
Availability of data and materials
The data set analyzed during the current study is available from the corresponding author on reasonable request.
Authors’ contributions: N. Ezhilarasan
Actualization, validation, methodology, formal analysis, initial draft and final draft.
