Subject: CGAL users discussion list
List archive
- From: Stefan Schirra <>
- To:
- Subject: Re: [cgal-discuss] Side effects
- Date: Fri, 5 Jul 2019 16:03:46 +0200
- Authentication-results: mail3-smtp-sop.national.inria.fr; spf=None ; spf=Pass ; spf=None
- Ironport-phdr: 9a23:YRSmeBzim6nDJlnXCy+O+j09IxM/srCxBDY+r6Qd1OISIJqq85mqBkHD//Il1AaPAdyBrakYwLWM+4nbGkU4qa6bt34DdJEeHzQksu4x2zIaPcieFEfgJ+TrZSFpVO5LVVti4m3peRMNQJW2aFLduGC94iAPERvjKwV1Ov71GonPhMiryuy+4ZLebxhWiDanb75/Ixq6oAfPusILnYZsN6E9xwfTrHBVYepW32RoJVySnxb4+Mi9+YNo/jpTtfw86cNOSL32cKskQ7NWCjQmKH0169bwtRbfVwuP52ATXXsQnxFVHgXK9hD6XpP2sivnqupw3TSRMMPqQbwoXzmp8qFmQwLqhigaLT406HzZhNJ+jKxboxyvqRJwzIHWb46JO/RzZb/dcNEASGZdQspcWS5MD4WhZIUPFeoBOuNYopHgqVsSsxS+CxOjBOXywTFVmnD23aw60/47EQ7cwQctGMkOsGjPrNrpNKcSUPq1zLPTwDXCdPNW1i3x55TTchw7vPGMW7NwfdPUyUY1GAPKk0ufppf4PzOP2eQBqXWU4PR5WO+plmUpqBlxryCyysojl4XFnI0Yx1/e+Slnzos5P8C0RUhmatC+CpRQrTuVN45uT8MiXW5ovCE6x6UCuZ6mcykF0ognxxnFa/Cdb4eI+QjvVPuXITd5nX5lfaiwhxmv/ke+0eL8S9O00FlQoiVYjNbArnEN1xrN5cibUvZx40is1SuV2w3c5exIO144mKTBJ5I82rIwk4AcsUXHHi/4gkX2i6qWe10/+ui08OTofrXmpp6GN49ukQz+M78umsOlDeskKQgCRXWb+eK91LH6+E32WrpKgeAonabCrZDaP8sbqrSkDABLyooj8QqwDy+60NQEmnkKNE5KeB2dgIjtIl3BPfH4DeyjjFSxizdr3OvLPqbhA5XINnjMiq3tfbd7605GyQo818pT55xOCuJJHPWmUUD4sJnUDwQyLhev6+fhEtR0kI0ECkyVBarMC7/fv1aOrtkkI+iWfoZd7C3hMPMl5uT0pX4ilhkWZu+025pSbXm3EvlsPl+WJ3bh1IRSWVwWtxYzGbS5wGaJViReMi7rDvAMowojAYfjNr/tA4WkgbiPxiC+RMAEZ3tJTFuXV2rudsCBUvgAZSiPOMAnnjFWDOH9Gb9k7gmnsUrB85QiNvDdoHBKtInsktNuofDVlFQ3/DN4As6AyW7LQ2wmxjpVFQ9z57h2pAlG8nnG0aV8hKYJR9hO9/pVVR18PoWa0up7TtX7VQ7MdMqTRxCqT4f+DA==
Hi Monique and Stefan,
not sure whether my 2 cents might be helpful, but may be, they are.
I conclude from Monique's answer that the CGAL code uses CORE::Expr internally.
So I'm wondering: is it possible that previous calculations performed
with dt affect future calculations? I'm imagining something like if
some calculation needed a certain precision (or number field), the
consecutive calculations are performed with the same precision even
though they might not need it.
Basically, such expression-dag based number types like CORE::Expr or leda::real (or Real_algebraic which is still under development) use adaptive precision computation, i.e., somehow increase the local precision repeatedly until it suffices. By local I mean the precision used during a decision making (sign computation). There is no global overall precision.
There are two strategies when it comes to the next decision making. Either you keep all the correct information you already have or you round to a small local starting precision, thereby introducing some error but making initial computations faster again, and then later adjust the precision adaptively. To my knowledge, CORE keeps all the correct information it has in order to avoid redundant recomputation.
If this is the case, is there a way to "reset" the precision?
I don't know, but I believe there is nothing like that. Usually, keeping all the correct information is a fairly good strategy.
Now I'm experiencing the following behavior: I have a program (and a
set of input) that finishes "immediately" but if I add some code, it
takes on the order of minutes and more *even in the old part of the
code*.
I do not quite understand what you mean by "add some code", but it is hard to believe that running time switches form seconds to minutes just because of keeping correct bits. I guess, there must be other causes, too, running out of memory for example. But without knowing what you are actually doing ...
Best regards
Stefan
- Re: [cgal-discuss] Side effects, Monique Teillaud, 07/04/2019
- Re: [cgal-discuss] Side effects, Stefan Schirra, 07/05/2019
Archive powered by MHonArc 2.6.18.