Skip to main content

New answers tagged

1 vote

Fast sampling from Fermi-Dirac distribution under specific conditions

Perhaps its a good idea to use the InverseFunction of the CDF. Make the functions parameter dependent an real numeric ...
Roland F's user avatar
  • 3,637
5 votes
Accepted

How to compile the following code (sampling from a distribution)?

Is UniformDistribution compilable? (Or maybe RandomReal?) If so, then making use of the fact that a ...
JimB's user avatar
  • 41.7k
3 votes
Accepted

Problem compiling derivative of expression

In addition to what Domen wrote in their post, I strongly recommend to scope the variable in the expression to make all this less brittle. Currently, some user of your code simply needs to assign some ...
Henrik Schumacher's user avatar
2 votes

Problem compiling derivative of expression

First, remove the second Function, because you already have the Function wrapper. Second, because ...
Domen's user avatar
  • 25.3k

Top 50 recent answers are included