#include "header.h" int main(void) { vec x,df; mat ddf; int flag,c=1; float ans=0; clock_t start, end; double toltime; con count; count=conset(A,B,C);//here we difine which value(s) we are going to evaluate. while(readv(&x)==1)//means could continue to read. { printf("the vector is:\n"); printv(x); df=createv(x.n); ddf=createm(x.n,x.n); start=clock();//time started flag=objfun(x,&ans,&df,&ddf,count); end=clock();//end of timing toltime=(double)(end-start)/CLOCKS_PER_SEC; printf("the value of the function is : %f\n",ans); printf("the value of df is :\n"); printv(df); printf("the value of ddf is :\n"); printm(ddf); printf("the time of this function ran is %f\n",toltime); printf("the number of f,df,ddf are called is %d\n",c); c++; freev(&x); freev(&df); freem(&ddf); } return 0; }