You are on page 1of 6

Diagnose eye disease with fuzzy-logic

Abdul Rahman[1], Ruqaiya Khanam[2], Syed Naseem Ahmad [3], Mohd Sadiq[4] [1]Department of Computer Sciences Lingayas University, Faridabad, Haryana, INDIA [2] Department of Electrical and Electronics Engineering, Lingayas University, Faridabad, Haryana, INDIA [3] Faculty of Electronics and Communication Engineering, Jamia Millia Islamia (A Central University), New Delhi, INDIA [4] University Polytechnic, Jamia Millia Islamia (A Central University), New Delhi, INDIA rahman.jhansi@gmail.com[1], ruqaiya_khanam@yahoo.co.in[2] sn.ahmad1952@gmail.com[3], sadiq.jmi@gmail.com[4]

ABSTRACT Eye is the most important sensory organ out of five senses. Eye provides essential information for vision. In this paper we have diagnose eye related disease like nearsightedness and farsightedness using rule based fuzzy logic, After that we have design some rule on the basis of shrinking or expansion in the eye ball. Finally we have proposed a methodology using membership function to estimate type of lenses as well as power as a remedial action. . Index TermsMembership Function, Myopia, Hyperopia In figure 1 anatomy of eye is shown. In the above figure light is entering the eyeball passes through refracting media. These are cornea, aqueous humor, lens and vitreous body. The eye is made up with three concentric coats, i.e inner, middle and outer. Inner part or nervous coat is the retina. Middle part or vascular coat is uveal tract and outer or fibrous consist of cornea and sclera. The lens in eye is double convex, light pass through it focus on retina. The rest of the paper is organized as follows. In Section 2 all the background and related work have been have explained. Section 3 contains some basics related to fuzzy logic used in this paper. Section 4 deals with causes of Myopia and Hyperopia and its possible diagnosis. In section 5, the proposed methodology and experimental work is carried out in section 6 respectively. 2. BACKGROUND AND RELATED WORK The shape of human eye can be considered as a circle so the background work consists of two parts. First part of this section includes all types of calculation related to circle, while on the other hand side the second part is based on co-ordinate geometry of circle and line for calculation of the degree of shrinking and expansion of eye [11]. In [13], work on the geometric shapes has been done using fuzzy geometric properties by applying set of points for fuzzy connectedness and fuzzy convexity. In current section some calculation related to change in curvature is define. In mathematics, curvature refers to any number of loosely related concepts in different areas of geometry. Intuitively, curvature is the amount by which a geometric object deviates from being flat, or straight in the case of a line. A circle has curvature equal to the inverse of

1. INTRODUCTION Eye disorder is one of major problem among all health problems. The normal function of eye is to give clear and correct vision of objects all around the world. There are various types of disease that are related to eye. The most common cause of eye disorder is shrinking and expanding of eye cornea. This paper deals only with hyperopia and myopia. Problem arises from shrinking of eye cornea is called farsightedness (hyperopia) and expanding of eye cornea is called nearsightedness (myopia) [1]. Researchers, Scientist and Academician developed different types of models for the calculation of nearsightedness and farsightedness [11].

Figure 1 Anatomy of eye

its radius everywhere. Smaller circles bend more sharply and hence have higher curvature. The curvature of a smooth curve is defined as the curvature of its osculating circle at each point. For a plane curve C, the mathematical definition of curvature uses a parametric representation of C with respect to the arc length parameterization. The meaning of curvature is the rate of changing of slope. Suppose that a particle moves on the plane with unit speed. Then the trajectory of the particle will trace out a curve C in the plane. Moreover, taking the time as the parameter, this provides a natural parameterization for C. The instantaneous direction of motion is given by the unit tangent vector P and the curvature measures how fast this vector rotates. If a curve keeps close to the same direction, the unit tangent vector changes very little and the curvature is small, where the curve undergoes a tight turn, the curvature is large. The magnitude of curvature at points on physical curves can be measured in diopters. The curvature of a straight line is identically zero. The curvature of a circle of radius is constant, i.e. it does not depend on the point and is equal to the reciprocal of the radius. If radius of circle is r and curvature is k then it can be calculated by equation 1and it is represented in figure 2. k = (r) -1 (1) Curve

Figure 3 Spherical shape of eye In figure 4 taking upper half as an arc and moving diameter upwards and every step the distance between intersection point of curvature and radius is reducing. This distance assumed as Xi for standard eye where i is 0>i>n where n is an integer. The above procedure can be followed for defected eye. In every step the distance between intersection point and radius arc is assumed Xi. The values of membership function are calculated by equation 2.

Figure 4 Upper half of eye n =0.1* { (Xi Xi)} i=1 Figure 2 Curvature of circle The shape of eye ball and retina is spherical so it can be considered as a circle in figure 3. For calculating degree of shrinking and expanding of eye retina, study of existing techniques will be beneficial, explanation is given below. This work is based on the study of eye retina as circle of 2.5 cm diameter or 1 inch. In current section some calculation related to change in curvature is define. A standard eye can be considered as a circle of radius of half inch as given in figure 4. (2) [11]

Where the value of deviation from x-coordinate of Healthy eye is Xi and Xi is the value of deviation from x-coordinate of defected eye. Value of deviation from x axis for healthy eye (Xi) and defected eye (Xi ) arc are given in table. On the basis of above results the value of membership function is being calculated by equation (2). =0.1*8 =0.8

XI 16 7 4 2 1 0 15 4 2 1 0 0

XI

XI XI 1 3 2 1 1 0 8 1. RULE BASED FUZZY LOGIC Figure 5 Far-sight (hyperopia) As Explain by Zadeh, [1995]: a vague proposition is fuzzy, but the converse is not generally true [2]. Basically, Fuzzy Logic (FL) is a multi-valued logic that allows intermediate values to be defined between conventional evaluations like true/false, yes/no, high/low, etc. Notions like rather tall or very fast can be formulated mathematically and processed by computers, in order to apply a more human-like way of thinking in the programming of computers [4]. As consequently, fuzzy concepts may generate uncertainty and reducing fuzziness may generate more certainty. However, this is not necessarily so, as far as a concept, although it is not fuzzy at all, may fail to capture the meaning of something adequately. A concept can be very precise, but not - or insufficiently - applicable or relevant in the situation to which it refers. A fuzzy concept may indeed provide more security because it provides a meaning for something when an exact concept is unavailable [5]. A vague proposition as a proposition where the possible states (of the proposition) are not clearly defined with regard to inclusion. For example consider a proposition that a person is young. Since the term young has different interpretation to different individuals. It cannot be decisively determined the age at which an individual is young versus age at which an individual is not considering to be young. Thus, the proposition is vaguely define therefore there must be establish a different method of interpretation [6]. This means the concept is vague, lacking a fixed, precise meaning, without being meaningless altogether. It does have a meaning, or multiple meanings (it has different semantic associations), which however can become clearer only through further elaboration and specification. Fuzzy concepts (Markusen, 2003) " lack clarity and are difficult to test or operationalize. A Fuzzy system can be thought as an aggression of modern of system and a model of a certainty [3]. Fuzzy Sets can be define mathematically by assigning to each possible individual in the universe of discourse a value representing its grade of membership in the fuzzy set [7]. A fuzzy set which have words: short men, tall women, hot day, cold climate, new building, ripe bananas, high intelligence, low speed, overweight, etc., where the condition can be given a value between 0 and 1[10].The

XI XI Table 1

3. CAUSES OF MYOPIA AND HYPEROPIA In old age the convexity of lens deteriorated or change in size of eye ball causes eye disease. This work based on cause which is change in size of eye ball. When the size of eye ball expanded from its normal size the rays coming from lens focus before eye retina as shown in figure 4. So the person unable to see the object far from normal vision distance this is called nearsightedness or myopia. When the size of eye ball expanded from its normal size the rays coming from lens focus before eye retina as shown in figure 3. So the person unable to see the object nearer from normal vision distance this is called farsightedness or hyperopia.

Figure 4 Short sight (Myopia)

capability of fuzzy sets to express gradual transition from membership to non membership and vice- versa. It provides meaningful and powerful representation of vague concept, measurement and uncertainty express in natural language. Fuzzy set can have infinite number of member function to represent it. The set of membership is the key to decision making when face with uncertainty. Only a small portion of knowledge for a problem is certain because uncertainty arises from complexity of problem, ignorance, randomness, lack of knowledge and vagueness. Fuzzy sets provides a natural way of dealing with problems in which source of imprecision in the absence of sharply define area of class membership rather than the presence of random variables [8]. A notion of set membership of an object in a fuzzy set is imprecise or can be approximated. Suppose a person seated at a table on which two glasses of liquid are rested .First glass is describe as having 95% chance of being healthful and good. The liquid in second glass is describe having 0.95 membership in the class of healthful and good liquid Which glass would be selected however first glass has 5% chance of being filled with non healthful liquid including poison [9].The function can be generalize by values that are assigned to elements of universal set fall within a specified range and indicate the membership grade of these elements in the set. Larger value denotes higher degree of set membership such a function is called membership function and the set defined by it a fuzzy set.

the same value of H ) [9].Fuzzy Logic applicable in inexact shape modeling as a f-valid of images [12].Any mathematician or an engineer with the knowledge of elementary geometry can estimate that this figure resembles with a geometry shape (e.g. a line). This knowledge is called Word Knowledge [14]. Defuzzification is the process of producing a quantifiable result in fuzzy logic. Typically, a fuzzy system will have a number of rules that transform a number of variables into a "fuzzy" result, that is, the result is described in terms of membership in fuzzy sets. Defuzzification would transform this result into a single number. Degree of Membership - The degree of membership is the placement in the transition from 0 to 1 of conditions within a fuzzy set. Human processing of information is not based on twovalued, off-on, either-or logic. Linguistic variables while variables in mathematics usually take numerical values, in fuzzy logic applications, the non-numeric linguistic variables are often used to facilitate the expression of rules and Fuzzy set theory defines fuzzy operators on fuzzy sets. A system control rule need not be based on human fuzzy perception. Fuzzy logic usually uses IF-THEN rules, or constructs that are equivalent, such as fuzzy associative matrices .Rules are usually expressed in the form: IF variable IS property THEN action For example, a simple temperature regulator that uses a fan might look like this: IF temperature IS very cold THEN stop fan IF temperature IS cold THEN turn down fan IF temperature IS normal THEN maintain level IF temperature IS hot THEN speed up fan 4. PROPOSED MODEL In previous model only space domain is used for the comparison of two eyes with reference line .Only reference line is not sufficient for comparison of two different images .In proposed model concept of time domain is introduced with spaced domain . Proposed model shown in figure 7.Here diameter of the semicircle is taken as reference line. The length of diameter is given by equation 3 (3) Where (x1, y1) and (x2, y2) are coordinate of end points of diameter as well as intersection point of semicircle or arc. The reference line is moved along y-axis with constant speed son both the eye images. Time taken by the line to cover distance is calculated by

Membership function Expansion in eye Powe arc r E1 0.1 Very low E2 0.3 Low E3 0.5 Low E4 0.7 High E5 0.9 Very High Table 2(a)

Membership function Shrinking in eye Powe arc r E1 0.2 Very low E2 0.4 Low E3 0.6 Low E4 0.7 High E5 0.8 Very High Table 2(b)

A most commonly used range of the values of membership function is the unit interval [ 0, 1].Consider a set consisting of height near 6 feet .since the property near 6 feet is fuzzy , there is not a unique membership function H rather , the analyst must be decide what the membership function denote H , should look like .Plausible properties of this function might be (i) normality ( H (6)=1), (ii) monotonicity (the closer H is to 6,6 the closer H is to 1) and (iii) symmetry (numbers equidistant from 6 should have

Time T=l*0.5/s.Time T divided into n number of fixed intervals. The length of chord is change as the line move upwards on both the images i.e. healthy eye, defected eye. These calculated by intersection points at ith lengths are i and time interval. The degree of deviation d (i.e. expansion or shrinking) is given by equation 4. (4) The sign of d shows expansion or shrinking. ALGORITHM 1. Initialize 2. Draw the image of eyes as a circle 3. Take the half part of the circle 4. Move diameter of the standard eye on both semicircle with constant speed for time period T 5. Divide T into n equal intervals 6. Repeat step 7 , 8 For i=1 to i=n 7. Calculate length of the both chord i 8. Calculate deviation d Figure 7

Figure 8

9. 10. Exit

IF IF IF

d < 0 THEN eye is shrunk d = 0 THEN eye is normal d > 0 THEN eye is expanded

Figure 9 After normalization the value obtain from simulation, table 3 shows the length of chord for normal, expanded and shrunk eye. Time (100ms) 1 2 3 4 5 6 7 8 Length of chord normal expand 139 147 125 131 111 115 97 98 84 81 66 63 50 44 32 23 Table 3 shrink 137 129 109 95 80 64 48 30

is calculated by equation 5 (5) The values of membership functions revealed form the simulation of 5 data sets are index in table 2(a) and 2(b). On the basis of degree of deviation following IF THEN fuzzy rule is constructed. IF deviation IS very small THEN uses very low power lenses IF deviation IS small THEN uses low power lenses IF deviation IS normal THEN no lenses IF deviation IS large THEN uses high power lenses IF deviation IS very large THEN uses very high power lenses Membership function 5. EXPERIMENTAL WORK The above algorithm works efficiently and successfully, the screenshots of every simulation obtained are shown in figures below. In fig 7, 8, 9 are used normal eye, expanded eye and shrunk eye respectively.

6. CONCLUSION AND FUTURE SCOPE This paper defines eye defects i.e. nearsightedness, farsightedness using membership function that is increases along with deviation to the normal eye (li -li). The proposed algorithm calculates membership function for defected eye. Moreover mathematical formulas are design to estimate membership function which makes this work more feasible. Using the same technique in the field of

orthopedics degree of fracture in a bone or slip of disk can be defined. As the application proposed work can be used in diagnosis through medical imaging by varying the membership definition and its mathematical formula. In current work reference image is not real time three dimensional image. In future there is scope for redefining the membership function as well as amendment in existing algorithm for real time data sets. 7. REFERENCES [1] Chaurasia B.D. Human Anatomy Regional and Applied Head, Neck & Brain, vol.3, pp.229, 1998. [2] L.A. Zadeh, Discussion Probability theory and Fuzzy Logic are Complementary rather than competitive, Techno metrics, vol. 37, pp.271-276, 1995. [3] Ben-Haim, Information Gap Decision Theory: Decisions under severe uncertainty, series on Decision and Risk, Academic Press, London, (2001). [4] L.A. Zadeh, Making computers think like people, IEEE. Spectrum, 8, pp. 26-32, 1984. [5] S. Korner, Laws of thought, Encyclopedia of Philosophy, Vol. 4, MacMillan, pp 414-417, 1967. [6] Black. M, Vaguness an exercise in logical analysis, Int. J.Gen .Syst, Vol. 17, pp 107-128, 1937. [7] Klir, George, Yuan Bo. Fuzzy Sets and Fuzzy Logic. Theory and Application, pp 1-5, 1995. [8] L.A Zadeh, Fuzzy Sets, Inf. Control, vol. 8, pp 338-353, 1965. [9] J. Bezdek, Editorial, Fuzzy Models -What are they and why?,IEEE Trans. Fuzzy Syst.vol. 1, pp1-5, 1993. [10] Hellman. M, Fuzzy Logic Introduction. [11] T.V Prasad, K. M Rafi, Ruqiaya Khanam, Abdul Rahman, Fuzzy Logic as a Knowledge Base Tool in Medical Diagnosis, National Conference on Advances in Knowledge Management , pp 366370,2010. [12] B. Mohammed Imran, M.M. Sufyan Beg Elements of Sketching with Words, IEEE International Conference on Granular Computing, pp 241-246, 2010. [13] Rosenfeld ,Geometric properties of sets of lines, Pattern Recognition Letters Elsevier, Vol. 16, Issue 5 pp 443-556, May 1995. [14] L.A. Zadeh, A note on web intelligence World Knowledge and fuzzy Logic, Journal Data & Knowledge of Engineering, Issue 50, pp.291- 304, 2004.

You might also like