Skip to main content
Royal Society Open Science logoLink to Royal Society Open Science
. 2017 Sep 20;4(9):170712. doi: 10.1098/rsos.170712

A generalized equation for the calculation of receptor noise limited colour distances in n-chromatic visual systems

R C Clark 1, R D Santer 2,, J S Brebner 2
PMCID: PMC5627113  PMID: 28989773

Abstract

Researchers must assess similarities and differences in colour from an animal's eye view when investigating hypotheses in ecology, evolution and behaviour. Nervous systems generate colour perceptions by comparing the responses of different spectral classes of photoreceptor through colour opponent mechanisms, and the performance of these mechanisms is limited by photoreceptor noise. Accordingly, the receptor noise limited (RNL) colour distance model of Vorobyev and Osorio (Vorobyev & Osorio 1998 Proc. R. Soc. Lond. B 265, 351–358 (doi:10.1098/rspb.1998.0302)) generates predictions about the discriminability of colours that agree with behavioural data, and consequently it has found wide application in studies of animal colour vision. Vorobyev and Osorio (1998) provide equations to calculate RNL colour distances for animals with di-, tri- and tetrachromatic vision, which is adequate for many species. However, researchers may sometimes wish to compute RNL colour distances for potentially more complex colour visual systems. Thus, we derive a simple, single formula for the computation of RNL distance between two measurements of colour, equivalent to the published di-, tri- and tetrachromatic equations of Vorobyev and Osorio (1998), and valid for colour visual systems with any number of types of noisy photoreceptors. This formula will allow the easy application of this important colour visual model across the fields of ecology, evolution and behaviour.

Keywords: colour discrimination, colour perception, chromatic contrast, animal vision, photoreceptor

1. Background

Colour sensations are constructed by nervous systems via comparisons of the responses of different spectral classes of photoreceptor [1]. Across taxa there is considerable variation in the number of spectral classes of photoreceptor in the retina, and in the wavelengths of light to which these different spectral classes respond most strongly [13]. Consequently, animal colour sensations can differ substantially to our own, yet it is essential in many fields of enquiry to evaluate similarities and differences in colour from an animal's eye view.

The responses of an animal's photoreceptors to a particular stimulus can be computed, given the reflectance spectrum of that stimulus and its background, the spectral sensitivity functions of the animal's photoreceptors, and the spectrum of illuminant light [1,4,5]. The calculated responses of the relevant classes of photoreceptor can then be used to determine the position of the stimulus within that animal's colour space [1,69]. Often of interest is the question of whether particular colour loci can be discriminated from one another, and key to this issue is the idea that the performance of colour opponent mechanisms is limited by photoreceptor noise [4,10,11]. The receptor noise limited (RNL) model allows the discriminability of colours to be assessed in a way that accounts for photoreceptor noise [4,10,11] and consequently is among the most influential and well-used tools in studies involving animal colour vision.

The original publication of the RNL model provides equations allowing colour distances to be determined for di-, tri- and tetrachromatic visual systems [4]. Most animals with the capability of colour vision do indeed appear to be functionally di-, tri- or tetrachromatic, and theoretical analyses also suggest that such visual systems are adequate for extracting the information available in natural spectra. However, many organisms have photoreceptor machinery that could mediate more complex colour vision, even if the mechanisms employed for a particular behavioural task can be shown to be di-, tri- or tetrachromatic. For example in butterflies, screening pigments produce a wide variety of spectral types of receptor that varies among families, species and even sexes, with the extreme so far discovered being 15 spectral types of photoreceptor in Graphium sarpedon [12,13]. In spite of the potential for greater complexity, foraging in Papilio xuthus relies on a tetrachromatic mechanism [14], and oviposition behaviours in Papilio aegeus, Pieris brassicae, and Pieris rapae are adequately explained by tri- or tetrachromatic mechanisms [15,16]. Dragonflies have an extraordinary diversity of opsin genes whose expression varies with life stage and eye region, with more than 10 visual opsins expressed in the adult eye of some species [17], and their involvement in colour-driven behaviour is currently unknown; and the 12 spectral receptor classes serving colour vision in mantis shrimp operate as an unusual scanning colour recognition system unlike any other known colour visual mechanism [18]. For such organisms, the experimenter may wish to test the plausibility of any possible n-chromatic visual mechanism if the photoreceptors involved in a particular behavioural act are unknown or in doubt (c.f. [14,19]).

In other study species, visual mechanisms have the potential to be more complex than has been assumed, necessitating analysis of n-chromatic visual mechanisms. For example, in true flies five spectral classes of receptor are present through the majority of the retina [20,21]. Although it has often been assumed that colour discrimination relies only on the four classes of long visual fibre [21,22], evidence from Drosophila shows that the short visual fibres, previously assumed to serve achromatic functions only, contribute to colour discrimination [23]. Among the Tabanidae and Dolichopodidae, differently coloured lenses in different regions of the compound eye shift the sensitivities of photoreceptors within their ommatidia [2427], raising the possibility that still more functional classes of receptor may exist. Outside of the insects, the double cones of fishes, reptiles, and birds are also assumed to serve achromatic tasks only, but there is evidence from blackbar triggerfish that they can contribute to colour discrimination in that species [28]. Thus, there may be a need for experimenters on such systems to consider n-chromatic visual mechanisms during their investigations.

In order to apply the RNL model to colour visual systems hypothesized to involve greater than four photoreceptors, experimenters have had to derive the relevant RNL model equations (such as those provided for pentachromatic and hexachromatic colour visual systems by [19]). Thus, to simplify the application of the RNL model to colour visual systems of any dimensionality, we derive a single equation that can be used to compute RNL colour distances for n-chromatic visual systems.

2. Basic assumptions

We begin with the fact that for any animal with the capability, colour stimuli are described by photoreceptor responses. The quantum catch of a photoreceptor, q, is computed by

qi=riλSi(λ)Is(λ)dλ, 2.1

where qi is the quantum catch of receptor i, Si(λ) is its spectral sensitivity function and Is(λ) is the spectrum of light entering the eye from a stimulus of interest, s. λ is the wavelength and ri is the range sensitivity factor, through which photoreceptor responses are adjusted to the spectrum of light entering the eye from the visual background, Ib:

ri=1λSi(λ)Ib(λ)dλ. 2.2

The process of phototransduction leads to a non-linear relationship between quantum catch, qi, and photoreceptor response, fi [1,5,9]. The RNL model can be applied to linearly or non-linearly transformed photoreceptor responses and the two are equivalent for stimuli that are close to a reference [4,10,11].

We will assume that there are N receptors and that the output of receptor i has random noise with variance ei2 [4]. We follow the notation of Vorobyev et al. [11] and the usual assumptions [4] that:

  1. for a visual system with N receptor channels, colour is encoded by N − 1 opponent mechanisms and the achromatic signal is discarded;

  2. opponent mechanisms give zero signal for stimuli that differ from background in intensity only; and

  3. thresholds are set by receptor noise, and not by opponent mechanisms.

The response of the N receptors to a stimulus can be represented by a column vector f where f=(f1,f2,,fN)T. (Superscript T indicates ‘transpose’.) Similarly, the output of the (N − 1) opponent mechanisms can be represented by a column vector x with (N − 1) components. It is also assumed [4,10,11] that x depends linearly on f. Hence the relationship between the two vectors can be written mathematically as

x=Ff, 2.3

where F is an (N − 1) ×N matrix with constant components.

As pointed out by Vorobyev & Osorio [4], assumption 2 imposes a constraint on the form of the matrix F. They show (their equation A8) that the sum of the components in each row of F must be zero. They consequently choose F to be the matrix which defines each xi by

xi=fifi+1 2.4

for i=1,(N1). As we wish to generalize the expressions published by Vorobyev & Osorio [4], we will follow their choice. No scaling factor is required in this equation as the colour distance is invariant under changes of the scale of each xi (see below).

Equation (2.4) implies that the outputs of the opponent mechanisms depend only on the differences between the outputs of the photoreceptors. It can be shown generally that any matrix F satisfying equation A8 in [4], and thus assumption 2, must have this property. What equation (2.4) does not do, is uniquely define the opponent mechanism outputs. Any linear combination of the differences ( fi− fj) is a possible choice of an opponent mechanism output satisfying assumption 2 and that choice will not affect the colour distance ΔS defined by Vorobyev & Osorio [4]. It is in this limited sense that the statement in assumption 3, that thresholds are not set by opponent mechanisms, is valid.

3. The Mahalanobis distance

We need to have a measure of the difference between the responses to two different stimuli. Let two responses be f and g with corresponding vectors x and y after the opponent mechanisms. Let Δf=(fg) and Δx=(xy). Vorobyev & Osorio [4] suggested that in the N − 1 dimension space of x vectors, the distance between the two stimuli could be defined by ΔS where the square of ΔS is given by

(ΔS)2=ΔxTR1Δx. 3.1

Here R1 is the inverse of R, the variance-covariance matrix of the variables xi.

The distance defined in equation (3.1) is known to statisticians as the Mahalanobis distance [29] after the Indian statistician who first used it. Note that although ΔS is referred to as a distance, it is actually a pure number as it is the ratio of the ‘distance’ between the two stimuli to the generalized standard deviation of the distribution. It gives the equivalent, in any number of dimensions, of the one-dimensional statement that two data points are ΔS standard deviations apart. Since it is a number, it has the property of ‘scale invariance’ which means that each xi can be rescaled without changing ΔS. It is also invariant under rotations of the axes in the space of the vectors x. This gives us the freedom to choose the opponent mechanisms' outputs in the manner mentioned in the previous section.

It should be noted that in the calculation of the variance-covariance matrix R, knowledge of the values of the means of the fi or xi are not required. While it is frequently stated that the variances of a distribution are independent of the position of the mean, in the RNL model this is a direct consequence of the implicit assumption that the variance of the noise, ei2, is independent of the quantum catch of receptor i. Hence the variances of the noise are independent of the means of the receptor outputs fi and the variances and covariances of the xi are independent of their means also.

Following a suggestion from a referee (whom we thank) we define, along with Vorobyev & Osorio [4], δxi and δfi by δxi=xixi and δfi=fifi. Then Rij=δxiδxj, ei2=(δfi)2 and, since the fi are independent, their covariances, δfiδfj with i ≠ j, are all zero.

Thus the diagonal terms of the matrix are

Rii=(δxi)2=(δfiδfi+1)2=(δfi)22δfiδfi+1+(δfi+1)2=ei2+ei+12 3.2

and the only non-zero, off-diagonal terms are

Ri,i+1=Ri+1,i=δxiδxi+1=(δfiδfi+1)(δfi+1δfi+2)=ei+12. 3.3

In all the above expressions, the brackets indicate averaging over the weighted values of the variable inside the brackets or both the variables if there are two.

To simplify the mathematical expressions below, from this point on we will write vi for ei2. We will return to the usual notation in the final expression.

The matrix R is a symmetric, tridiagonal matrix:

R=(v1+v2v20v2v2+v3v30v3v3+v4000000000000vN2+vN1vN1vN1vN1+vN). 3.4

The components of inverses of tridiagonal matrices are known to satisfy simple relationships [30]. The components of the inverse of the above matrix are given by

Rii1=1θN1θi1i+1i=1,2,N1 3.5

and

Ri,j1=Rj,i1=1θN1vi+1vjθi1j+1i=1,2,N2,j=2,N1,i<j. 3.6

In these expressions the θi and i are functions of the vi that satisfy known recurrence relations.

The θi satisfy the recurrence relation

θi=(vi+vi+1)θi1vi2θi2 3.7

for i= 2, … N − 1 with initial values θ0=1and θ1=v1+v2.

Similarly the i satisfy

i=(vi+vi+1)i+1vi+12i+2 3.8

for i=N2,1 with initial values N=1 and N1=vN1+vN.

From equation (3.7), we have

θivi+1θi1=vi(θi1viθi2). 3.9

The term in brackets on the right side of the equation is the same as the expression on the left side with i replaced by i − 1. Repeated substitution of the bracketed term in terms of the next lower value of i gives eventually

θivi+1θi1=vivi1v2(θ1v2θ0)=vivi1v1 3.10

or

θi=vi+1θi1+vivi1v1. 3.11

Using θ0 = 1 and θ1=v1+v2 we have θ2=v3(v1+v2)+v2v1 and

θ3=v4(v3v1+v3v2+v2v1)+v3v2v1. 3.12

It is clear that θi is the sum of all possible products of v1, v2, … vi+1 with just one v missing. It can be written concisely as

θi=v1v2.vi+1k=1i+11vk. 3.13

Note that the determinant of R1 is θN−1 where

 θN1=v1v2.vNk=1N1vk. 3.14

A similar reduction can be made for i. The variances involved are vi to vN giving

i=vivi+1.vNk=iN1vk. 3.15

When these expressions are entered into equations (3.5) and (3.6) the products of the vi cancel, giving

Rii1=(k=1i(1/vk))(k=i+1N(1/vk))k=1N(1/vk) 3.16

and

Ri,j1=Rj,i1=(k=1i(1/vk))(k=j+1N(1/vk))k=1N(1/vk)i<j. 3.17

In terms of these components, since Δxi=(ΔfiΔfi+1), equation (3.1) is

(ΔS)2=i=1N1Rii1(ΔfiΔfi+1)2+2j=2N1i=1j1Ri,j1(ΔfiΔfi+1)(ΔfjΔfj+1). 3.18

4. Simplification

Vorobyev & Osorio [4] demonstrated for trichromatic and tetrachromatic vision that much simpler expressions could be obtained if (ΔS)2 is expressed in terms of all the ½N(N − 1) squared differences (ΔfiΔfj)2. We will assume this is possible for any N and we will show that the result is a very simple formula.

Let

(ΔS)2=1k=1N(1/vk)i=1N1j=i+1NCi,j(ΔfiΔfj)2. 4.1

We can calculate the Ci,j by comparing the coefficients of Δfi2 and of ΔfiΔfj in the two expressions (3.18) and (4.1). We can take any values of i and j we choose as (ΔS)2 does not depend on which receptor is labelled i and which is j. For simplicity choose i= 1. In equation (3.18) the coefficient of Δf12 is R111 where

R111=(k=11(1/vk))(k=2N(1/vk))k=1N(1/vk)=(1/v1)(k=2N(1/vk))k=1N(1/vk), 4.2

while the coefficient of Δf12 in (4.1) is (1/k=1N(1/vk))j=2NC1,j. The two terms are equal if C1,j=1/v1vj.

Similarly with i= 1 and j= 2 the coefficient of Δf1Δf2 in equation (3.18) is 2(R1,21R1,11 ).

R1,11 is given by equation (4.2) and

R1,21=(k=11(1/vk))(k=3N(1/vk))k=1N(1/vk)=(1/v1)(Σk=3N(1/vk))Σk=1N(1/vk). 4.3

Hence

2(R1,21R1,11)=2(1/v1)(1/v2)k=1N(1/vk), 4.4

which agrees with the coefficient of Δf1Δf2 in equation (4.1) if C1,2=1/v1v2 . So the two expressions for (ΔS)2 are identical if Ci,j=1/vivj. Consequently, we have that the square of the Mahalanobis distance between f and g for N receptors with (N − 1) opponent mechanisms is simply

(ΔS)2=1k=1N(1/ek2)i=1N1j=i+1N(ΔfiΔfj)2ei2ej2. 4.5

We have replaced vi by ei2in this result.

This equation agrees with the results published by Vorobyev & Osorio [4] for dichromatic, trichromatic and tetrachromatic vision. To demonstrate this we will consider the trichromatic case as an example.

When N= 3 equation (4.5) is

(ΔS)2=1(1/e12+1/e22+1/e32)((Δf1Δf2)2e12e22+(Δf1Δf3)2e12e32+(Δf2Δf3)2e22e32). 4.6

Multiplying both brackets by e12e22e32 gives

(ΔS)2=1(e22e32+e12e32+e12e22)(e32(Δf1Δf2)2+e22(Δf1Δf3)2+e12(Δf2Δf3)2). 4.7

Apart from reordering this is the same formula as given in [4].

5. Conclusion

Equation (4.5) gives (ΔS)2 for any number of receptor types. It can be simply stated as (ΔfiΔfj)2/ei2ej2 summed over all pairs of receptors divided by 1/ei2 summed over all receptors. This equation allows the calculation of RNL colour distances for n-chromatic visual systems, facilitating the easy application of this model to investigate colour discrimination in organisms with complex visual systems and unknown chromatic mechanisms (c.f. [14,19]).

A key premise of the RNL model is that the discriminability of colour stimuli is set by receptor noise and not opponent mechanisms (assumption 3), and as such the way in which receptor responses are combined within opponent mechanisms (the matrix F in equation (2.3)) does not determine the discriminability of colour signals (e.g. [11]). However, we point out that the form of equation (4.5) depends critically on equation (2.4), which itself is determined by assumption 2. Hence in the RNL model, opponent mechanisms are not completely unspecified because their choice is restricted by assumption 2.

Acknowledgements

The authors thank two anonymous reviewers whose suggestions improved the manuscript.

Data accessibility

This article has no additional data.

Authors' contributions

R.C.C. and J.S.B. conceived the idea for the paper. R.C.C. conducted the mathematical work; J.S.B. and R.D.S. provided biological interpretation. R.C.C. and R.D.S. drafted the article, and all authors contributed to critical revisions. All authors have agreed to the final version.

Competing interests

We have no competing interests.

Funding

The authors received no specific funding to support this work. IBERS receives strategic funding from the Biotechnology and Biological Sciences Research Council (BBSRC).

References

Associated Data

This section collects any data citations, data availability statements, or supplementary materials included in this article.

Data Availability Statement

This article has no additional data.


Articles from Royal Society Open Science are provided here courtesy of The Royal Society

RESOURCES