Fix boundary cases in logspace() and linspace()

For any a < b:
torch.linspace(a, a, 1) returns a 1-dim tensor of a, instead of nan
torch.linspace(a, b, 1) throws an error, instead of returning nan
torch.logspace(a, a, 1) returns a 1-dim tensor of 10^a, instead of nan
torch.logspace(a, b, 1) throws an error, instead of returning nan
torch.test() checks the 4 asserts above
Merge pull request #100 from jucor/LinspaceFix

Fix boundary cases in logspace() and linspace()