Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Possible bug when a symbolic function is declared twice

I don't understand the output of the following code:

sage: f = function('f')
sage: f(x).operator() is f
True
sage: f = function('f')
sage: f(x).operator() is f
False

Is that the intended behavior?

It seems that operator returns the first symbolic function defined with this name, not the actual operator. This is problematic for me because it means there are some cells in my notebook I can only run once, so I have to restart the kernel everytime I want to press "run all".

Possible bug when a symbolic function is declared twice

I don't understand the output of the following code:

sage: f = function('f')
sage: f(x).operator() is f
True
sage: f = function('f')
sage: f(x).operator() is f
False

Is that the intended behavior?

It seems that operator returns the first symbolic function defined with this name, not the actual operator. This is problematic for me because it means there are some cells in my notebook I can only run once, so I have to restart the kernel everytime I want to press "run all".

click to hide/show revision 3
retagged

Possible bug when a symbolic function is declared twice

I don't understand the output of the following code:

sage: f = function('f')
sage: f(x).operator() is f
True
sage: f = function('f')
sage: f(x).operator() is f
False

Is that the intended behavior?

It seems that operator returns the first symbolic function defined with this name, not the actual operator. This is problematic for me because it means there are some cells in my notebook I can only run once, so I have to restart the kernel everytime I want to press "run all".