2009/6/10 Fabian Pedregosa <fab...@fseoane.net> [...] > +known_facts_dict = { > + 'even' : ['integer & ~odd'], > + 'composite' : ['integer & ~prime'], > + 'complex' : ['real | imaginary', 'rational | irrational | > imaginary'], # this is not quite correct > + 'integer' : ['rational & numerator_is_one'], > + 'irrational' : ['real & ~rational'], > + 'imaginary' : ['complex & ~real'], > + 'rational' : ['real & ~irrational'], > + 'real' : ['complex & ~imaginary', 'rational | irrational'], > + 'unbounded' : ['extended_real & ~bounded'], > + 'negative' : ['real & ~positive & ~zero'], > + 'nonpositive': ['real & ~positive', 'zero | negative'], > + 'nonnegative': ['real & ~negative', 'zero | positive'], > + 'noninteger' : ['real & ~integer'], > + 'nonzero' : ['real & ~zero'], > + 'odd' : ['integer & ~even'], > + 'prime' : ['integer & positive & ~composite'], > + 'positive' : ['real & ~negative & ~zero'], > + 'zero' : ['real & ~positive & ~negative'] > +}
[...] Why are you using a string-based mini-language rather than using native Python objects and operators? Is this intended for the configuration only or also for the user interface? Vinzent --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sympy-patches" group. To post to this group, send email to sympy-patches@googlegroups.com To unsubscribe from this group, send email to sympy-patches+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sympy-patches?hl=en -~----------~----~----~----~------~----~------~--~---