Implementation of the Doehlert Design
​Authors: Housam Binous and Ahmed Bellagi

The present notebook computes the Doehlert Design Matrix for any number of factors and center points. This matrix was first proposed by Doehlert (see Ref. 1). The proposed coding is based on a previously published Matlab file available in Ref. 2.
​
​References:​
[1] David H. Doehlert, Uniform Shell Designs, Applied statistics, 1970, 19(3), 231-239
[2] https://www.mathworks.com/matlabcentral/fileexchange/54048-doehlert-design
[3] U. M. F. M. Cerqueira, M. A. Bezerra, S. L. C. Ferreira, R. de J. Araújo, B. N. da Silva, C. G. Novaes, Doehlert design in the optimization of procedures aiming food analysis – A review, Food Chemistry, Volume 364, 2021, 130429
In[]:=
Doehlert[nFac_,ncenter_]:=Module[{RegularSimplex,iFac},RegularSimplex=Table[0,{i,1,nFac(nFac+1)+ncenter},{j,1,nFac}];​​For[i=1,i<=nFac,i++,For[j=1,j<=i,j++,{If[i==j,RegularSimplex[[i+1,j]]=Sqrt[i+1]/Sqrt[2i],RegularSimplex[[i+1,i-j]]=1/Sqrt[2(i-(j-1))(i-j)]]}]]​​iFac=0;​​For[i=1,i<=nFac+1,i++,For[j=2,j<=nFac+1,j++,{If[i≠j,{iFac=iFac+1,RegularSimplex[[nFac+1+iFac]]=RegularSimplex[[i]]-RegularSimplex[[j]]}]}]];Table[RegularSimplex[[i,j]]//N,{i,1,nFac(nFac+1)+ncenter},{j,1,nFac}]]
Coded values for the levels of two to five variables in the Doehlert matrix reproduced from Ref. 3.​​
Case 1 : three factors and three center points
In[]:=
nFac=3;ncenter=3;
In[]:=
Doehlert[nFac,ncenter]//TableForm
Out[]//TableForm=
0.
0.
0.
1.
0.
0.
0.5
0.866025
0.
0.5
0.288675
0.816497
-1.
0.
0.
-0.5
-0.866025
0.
-0.5
-0.288675
-0.816497
0.5
-0.866025
0.
0.5
-0.288675
-0.816497
-0.5
0.866025
0.
0.
0.57735
-0.816497
-0.5
0.288675
0.816497
0.
-0.57735
0.816497
0.
0.
0.
0.
0.
0.
In[]:=
Dimensions[%]
Out[]=
{15,3}
Case 2 : five factors and three center points
In[]:=
nFac=5;ncenter=3;
In[]:=
Doehlert[nFac,ncenter]//TableForm
Out[]//TableForm=
0.
0.
0.
0.
0.
1.
0.
0.
0.
0.
0.5
0.866025
0.
0.
0.
0.5
0.288675
0.816497
0.
0.
0.5
0.288675
0.204124
0.790569
0.
0.5
0.288675
0.204124
0.158114
0.774597
-1.
0.
0.
0.
0.
-0.5
-0.866025
0.
0.
0.
-0.5
-0.288675
-0.816497
0.
0.
-0.5
-0.288675
-0.204124
-0.790569
0.
-0.5
-0.288675
-0.204124
-0.158114
-0.774597
0.5
-0.866025
0.
0.
0.
0.5
-0.288675
-0.816497
0.
0.
0.5
-0.288675
-0.204124
-0.790569
0.
0.5
-0.288675
-0.204124
-0.158114
-0.774597
-0.5
0.866025
0.
0.
0.
0.
0.57735
-0.816497
0.
0.
0.
0.57735
-0.204124
-0.790569
0.
0.
0.57735
-0.204124
-0.158114
-0.774597
-0.5
0.288675
0.816497
0.
0.
0.
-0.57735
0.816497
0.
0.
0.
0.
0.612372
-0.790569
0.
0.
0.
0.612372
-0.158114
-0.774597
-0.5
0.288675
0.204124
0.790569
0.
0.
-0.57735
0.204124
0.790569
0.
0.
0.
-0.612372
0.790569
0.
0.
0.
0.
0.632456
-0.774597
-0.5
0.288675
0.204124
0.158114
0.774597
0.
-0.57735
0.204124
0.158114
0.774597
0.
0.
-0.612372
0.158114
0.774597
0.
0.
0.
-0.632456
0.774597
0.
0.
0.
0.
0.
0.
0.
0.
0.
0.
In[]:=
Dimensions[%]
Out[]=
{33,5}
Case 3 : seven factors and only one center points
In[]:=
nFac=7;ncenter=1;
In[]:=
Doehlert[nFac,ncenter]//TableForm
Out[]//TableForm=
0.
0.
0.
0.
0.
0.
0.
1.
0.
0.
0.
0.
0.
0.
0.5
0.866025
0.
0.
0.
0.
0.
0.5
0.288675
0.816497
0.
0.
0.
0.
0.5
0.288675
0.204124
0.790569
0.
0.
0.
0.5
0.288675
0.204124
0.158114
0.774597
0.
0.
0.5
0.288675
0.204124
0.158114
0.129099
0.763763
0.
0.5
0.288675
0.204124
0.158114
0.129099
0.109109
0.755929
-1.
0.
0.
0.
0.
0.
0.
-0.5
-0.866025
0.
0.
0.
0.
0.
-0.5
-0.288675
-0.816497
0.
0.
0.
0.
-0.5
-0.288675
-0.204124
-0.790569
0.
0.
0.
-0.5
-0.288675
-0.204124
-0.158114
-0.774597
0.
0.
-0.5
-0.288675
-0.204124
-0.158114
-0.129099
-0.763763
0.
-0.5
-0.288675
-0.204124
-0.158114
-0.129099
-0.109109
-0.755929
0.5
-0.866025
0.
0.
0.
0.
0.
0.5
-0.288675
-0.816497
0.
0.
0.
0.
0.5
-0.288675
-0.204124
-0.790569
0.
0.
0.
0.5
-0.288675
-0.204124
-0.158114
-0.774597
0.
0.
0.5
-0.288675
-0.204124
-0.158114
-0.129099
-0.763763
0.
0.5
-0.288675
-0.204124
-0.158114
-0.129099
-0.109109
-0.755929
-0.5
0.866025
0.
0.
0.
0.
0.
0.
0.57735
-0.816497
0.
0.
0.
0.
0.
0.57735
-0.204124
-0.790569
0.
0.
0.
0.
0.57735
-0.204124
-0.158114
-0.774597
0.
0.
0.
0.57735
-0.204124
-0.158114
-0.129099
-0.763763
0.
0.
0.57735
-0.204124
-0.158114
-0.129099
-0.109109
-0.755929
-0.5
0.288675
0.816497
0.
0.
0.
0.
0.
-0.57735
0.816497
0.
0.
0.
0.
0.
0.
0.612372
-0.790569
0.
0.
0.
0.
0.
0.612372
-0.158114
-0.774597
0.
0.
0.
0.
0.612372
-0.158114
-0.129099
-0.763763
0.
0.
0.
0.612372
-0.158114
-0.129099
-0.109109
-0.755929
-0.5
0.288675
0.204124
0.790569
0.
0.
0.
0.
-0.57735
0.204124
0.790569
0.
0.
0.
0.
0.
-0.612372
0.790569
0.
0.
0.
0.
0.
0.
0.632456
-0.774597
0.
0.
0.
0.
0.
0.632456
-0.129099
-0.763763
0.
0.
0.
0.
0.632456
-0.129099
-0.109109
-0.755929
-0.5
0.288675
0.204124
0.158114
0.774597
0.
0.
0.
-0.57735
0.204124
0.158114
0.774597
0.
0.
0.
0.
-0.612372
0.158114
0.774597
0.
0.
0.
0.
0.
-0.632456
0.774597
0.
0.
0.
0.
0.
0.
0.645497
-0.763763
0.
0.
0.
0.
0.
0.645497
-0.109109
-0.755929
-0.5
0.288675
0.204124
0.158114
0.129099
0.763763
0.
0.
-0.57735
0.204124
0.158114
0.129099
0.763763
0.
0.
0.
-0.612372
0.158114
0.129099
0.763763
0.
0.
0.
0.
-0.632456
0.129099
0.763763
0.
0.
0.
0.
0.
-0.645497
0.763763
0.
0.
0.
0.
0.
0.
0.654654
-0.755929
-0.5
0.288675
0.204124
0.158114
0.129099
0.109109
0.755929
0.
-0.57735
0.204124
0.158114
0.129099
0.109109
0.755929
0.
0.
-0.612372
0.158114
0.129099
0.109109
0.755929
0.
0.
0.
-0.632456
0.129099
0.109109
0.755929
0.
0.
0.
0.
-0.645497
0.109109
0.755929
0.
0.
0.
0.
0.
-0.654654
0.755929
In[]:=
Dimensions[%]
Out[]=
{57,7}