When a female dog is in heat, a male dog nearby will usually start whining. A male dog can smell a female dog in heat and it frustrates them. If you don't want them to mate, make sure they are separated at all times. All they would need is 10 seconds together to mate. This will happen in a cycle until one of the dogs gets fixed. Heat cycles usually last about 3 weeks and sometimes longer. Be aware that the male could start spraying around the house out of frustration, and he is scenting his territory.