[GiNaC-list] Automatic transformation of expressions in GiNaC

Vladimir V. Kisil kisilv at maths.leeds.ac.uk
Wed Jan 11 20:58:11 CET 2017


>>>>> On Thu, 12 Jan 2017 00:30:54 +0500, abpetrov <abpetrov at ufacom.ru> said:

    ABP> Hello, I wrote some program to do some calculations with
    ABP> GiNaC. But I can see program makes some unwanted
    ABP> transformations of expressions automatically. Below is simple
    ABP> example. Can I avoid that transformations?  Wanted output is
    ABP> sqrt(m/2).

    You get this with
    
    ex e = power(m/2,numeric(1,2)).setflag(status_flags::evaluated);     

    Yet, it can be again broken into factors at any use of e in other
  expressions. 
-- 
Vladimir V. Kisil                 http://www.maths.leeds.ac.uk/~kisilv/
  Book:     Geometry of Mobius Transformations     http://goo.gl/EaG2Vu
  Software: Geometry of cycles          http://moebinv.sourceforge.net/


More information about the GiNaC-list mailing list