Sure, but when I pass in 0 for param[0] (y), it turns out it's actually 
put in as -1e-7 which throws an error since y has to be nonnegative. Any 
idea why this is happening?

On 6/27/13 5:43 PM, Daniel Lee wrote:
>
> In src/test/agrad/distributions/univariate/continuous/rayleigh_test.hpp:
>
> > +    param[0] = 1;           // y
> > +    param[1] = 1;           // sigma
> > +    parameters.push_back(param);
> > +    log_prob.push_back(-0.5); // expected log_prob
> > +
> > +    param[0] = 2;          // y
> > +    param[1] = 1;           // sigma
> > +    parameters.push_back(param);
> > +    log_prob.push_back(-1.30685281944005469058276787854182343192449986563974474587931); // expected log_prob
> > +
> > +    param[0] = 3.5;          // y
> > +    param[1] = 7.2;           // sigma
> > +    parameters.push_back(param);
> > +    log_prob.push_back(-2.8135512); // expected log_prob
> > +  }
> > +
>
> @PeterLi2016 <https://github.com/PeterLi2016>, want to add a test for 
> |y=0|? We don't need to add one for |sigma=0|.
>
> —
> Reply to this email directly or view it on GitHub 
> <https://github.com/stan-dev/stan/pull/103/files#r4927538>.
>