Hello Tobias, Thanks a lot for your reply. Apologies for the delay in response. '*Are you sure that Mathematica gives you 300 digits precision (PrecisionGoal), and doesn't just require 300 digits working precision (WorkingPrecision)? Do you need 300 digits precision? *' -- the relevant part of the Mathematica notebook says *{$MaxExtraPrecision, prec} = {500, 40} , *not sure whether this is the actual precision or the 'working precision' as this is the first time I'm handling such involved numerical calculations.
Great idea about digging deeper into how Mathematica itself is dealing with the problem (I guess you meant Gnu Scientific ilbrary by GSL, this also looks like a cool package . ) - this is a generic approach which I could then use to test how the same algorithm implemented in another package performs. best, Thejasvi On Wednesday, April 14, 2021 at 4:26:13 PM UTC+2 Tobias Neumann wrote: > > > For my own use-case, I expect to need very high precision (eg. the > Mathematica code I'm trying to port uses 300 digits for the same model). > > Is DoubleFloat the correct Type to use? > > > Given that the target is 300 digits precision, I tried to run the > adaptive integration with lower and lower errors (< 1.0e-16). > > It ended up taking a much longer time (didn't complete in 3mins). Do any > of you have ideas on how to overcome this. > > Are you sure that Mathematica gives you 300 digits precision > (PrecisionGoal), and doesn't just require 300 digits working precision > (WorkingPrecision)? Do you need 300 digits precision? If yes, then there > likely won't be an out-of-the-box solution, > especially with an oscillatory integrand. > > *If* Mathematica is able to get you 300 digits (PrecisionGoal) by just > using NIntegrate, you should try to figure out which > method it uses. By default it uses heuristics to choose a good method ( > https://reference.wolfram.com/language/tutorial/NIntegrateIntegrationStrategies.html > > ). This is especially relevant > for those oscillatory integrands. I would try to replicate your success > with Mathematica by explicitly specifying the integration method with > NIntegrate. Once you have done so, you can either find a library that > implements that method (or implement it yourself). For example > GSL has some routines for oscillatory integrands > > Best wishes, > Tobias > >> >> -- You received this message because you are subscribed to the Google Groups "FriCAS - computer algebra system" group. To unsubscribe from this group and stop receiving emails from it, send an email to fricas-devel+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/fricas-devel/808de225-b00d-41fb-88b7-694356e9fd67n%40googlegroups.com.