f4d.c

来自「数值算法库」· C语言 代码 · 共 21 行

C
21
字号
/*  f4d.c    CCM mathematics library source code. * *  Copyright (C)  2000   Daniel A. Atkinson    All rights reserved. *  This code may be redistributed under the terms of the GNU general *  public license. ( See the gpl.license file for details.) * ------------------------------------------------------------------------ *//* 4-D function   Minimum =0 at x[i]=0.0 for i=0,1,2,3 .*/double f4d(x)double x[];{ double f,s; extern int count;  ++count;  s=x[0]+10.*x[1]; f=s*s;  s=x[2]-x[3]; f+=5.*s*s;  s=x[1]-2.*x[2]; f+=s*s;  s=x[0]-x[3]; s*=s; f+=10.*s*s;  return f;}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?