Why do I get False for the additive law of logs for symbols, but True for numbers?

var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))

False True

1 | initial version |

Why do I get False for the additive law of logs for symbols, but True for numbers?

var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))

False True

Why do I get False for the additive law of logs for symbols, but True for ~~numbers?~~numbers?
And why is my code all on one line?

var('a ~~b')
print(bool(log(a)+log(b)==log(a~~b')*b)))
print(bool(log(5)+log(10)==log(5*10)))

~~False
~~print(bool(log(a)+log(b)==log(a*b)))

print(bool(log(5)+log(10)==log(5*10)))

False

True

Why do I get False for the additive law of logs for symbols, but True for ~~numbers?
And why is my code all on one line?~~numbers?

var('a ~~b')~~b')

print(bool(log(a)+log(b)==log(a*b)))

~~print(bool(log(5)+log(10)==log(5*10)))~~print(bool(log(5)+log(10)==log(5*10)))

False

True

Why do I get False for the additive law of logs for symbols, but True for numbers?

var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))

~~print(bool(log(a)+log(b)==log(a*b))) ~~

print(bool(log(5)+log(10)==log(5*10)))

False

True

Why do I get False for the additive law of logs for symbols, but True for numbers?

var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))

False True

Why do I get False for the additive law of logs for symbols, but True for numbers?

var('a b')

print(bool(log(a)+log(b)==log(a*b)))

print(bool(log(5)+log(10)==log(5*10)))

False

True

Why do I get False for the additive law of logs for symbols, but True for numbers?

~~var('a ~~"""var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))

~~print(bool(log(a)+log(b)==log(a*b))) ~~

print(bool(log(5)+log(10)==log(5*10)))

False

TrueFalse True"""

Why do I get False for the additive law of logs for symbols, but True for numbers?

~~"""var('a ~~var('a b') ~~
print(bool(log(a)+log(b)==log(a~~*b)))
print(bool(log(5)+log(10)==log(5*10)))

~~False
True"""~~print(bool(log(a)+log(b)==log(a*b)))

print(bool(log(5)+log(10)==log(5*10)))

False

True

Why do I get False for the additive law of logs for symbols, but True for numbers?

`var('a b') `
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10))) print(bool(log(a)+log(b)==log(a*b)))

print(bool(log(5)+log(10)==log(5*10)))

False

True

False
True

Why do I get False for the additive law of logs for symbols, but True for numbers?

```
var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))
False
True
```

Why do I get False for the additive law of logs for symbols, but True for ~~numbers?~~numbers?
var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))

~~var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))
~~False
True

Why do I get False for the additive law of logs for symbols, but True for ~~numbers?
var('a b')
print(bool(log(a)+log(b)==log(a~~numbers?*b)))
print(bool(log(5)+log(10)==log(5*10)))

```
var('a b')
print(bool(log(a)+log(b)==log(a*b)))
print(bool(log(5)+log(10)==log(5*10)))
False
True
```

Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.