Displaying 2 results from an estimated 2 matches for "convergencecod".
Did you mean:
convergencecode
2007 Oct 13
1
R API - optim
...* Copied from tests/Embedded/embeddedRCall.c:
*/
extern int Rf_initEmbeddedR(int argc, char *argv[]);
int main()
{
char *argv[]= {"nmminDemo", "--gui=none", "--silent"}; const int argc =
3;
double initial[1] = {1.5};
double result[1];
double value;
int convergenceCode;
/*
* The following values are based on the help
* page for optim.
*/
const double abstol = 1e-16;
const double reltol = 1e-8;
const double alpha = 1.0; /* reflection factor */ const double beta =
0.5; /* contraction factor */ const double gamm = 2.0; /* expansion factor
*/...
2006 Apr 13
1
bus error on calling nmmin
....)
The source code and an example session:
nmminDemo.c:
#include <R_ext/Applic.h>
#include <stdio.h>
double parabola(int n, double *par, void *ex) {
double xm = par[0] - 1;
return xm * xm + 13;
}
int main()
{
double initial[1] = {1.5};
double result[1];
double value;
int convergenceCode;
const double abstol = 1e-16;
const double reltol = 1e-8;
const double alpha = 1.0; /* reflection factor */
const double beta = 0.5; /* contraction factor */
const double gamm = 2.0; /* expansion factor */
const int trace = 4; /* tracing on */
int fncount;
const int maxit = 10000;...