I am comparing two Doubles:

```
37.4238777160645

```

and 

```
37.4238777160645

```

But Java does not consider them to be equal. I am comparing them in the following manner

```
if(object1.getLatitude()!=object2.getLatitude()){
    fail("objects are not equal "+object1.getLatitude()+":"+object2.getLatitude());
}

```

resulting in the following fail:

```
junit.framework.AssertionFailedError: objects are not equal  37.4238777160645:37.4238777160645

```

I don't understand why - Please advise.