Determinant of Matrix with Fixed or Data-dependent Basis

Illustrates the proof of the Mairhuber - Curtis theorem.

Clear["Global`*"];
Manipulate[
Block[{dpt,DM,detM,svals,condnum,fun1,tp},

(* Defining some of the parameters *)

dpt = Which[pts==1,dsites,pts==2,ctrs];
DM = matrixA[ctrs,dpt,ϵ] ; 
detM = Det[DM] ; 
svals = SingularValueList[DM] ; 
condnum = svals[[1]]/svals[[-1]] ; 
fun1 = First@matrixA[{{x,y}},dpt,ϵ];
tp = If[t,30,9];

(* Displaying plots and values *)

Column[{
Row[{
Graphics[{White,Point[ctrs]},PlotRange->{{0,1},{0,1}},Frame->True,PlotLabel-> Style[ "Datasites",Bold,Medium],ImageSize-> Small],
"    ",
Plot3D[fun1,{x,0,1},{y,0,1}, PlotRange -> {0,1}, ImageSize -> Medium, Mesh -> None, ColorFunction->Function[{x,y,z},Hue[z]], PlotPoints -> tp,MaxRecursion -> 0,PerformanceGoal -> "Speed",PlotLabel-> Style[ "Basis Functions",Bold,Medium]]
},Alignment -> Center],
Style[StringForm["Det(A) = `1`",ScientificForm[Det[DM]]], Bold,18],
Style[StringForm["Cond(A) = `1`", ScientificForm[condnum]], Bold,18]
},Alignment -> Center]
],

(* specs of the controllers *)

{{ctrs,dsites},Locator, LocatorRegion -> {{0,1},{0,1}}},
Row[{Control[{{pts,1,"Centers for basis functions"},{1->"Fixed",2->"Data-dependent"},ControlType->PopupMenu}], 
Control[{{t,False,"QualityPlot"},{True,False}}]
},Spacer[10]],

(* Additional settings for Manipulate *)

TrackedSymbols :> {ctrs,pts,t}, Initialization :> {d=2;npts=9;ϵ=6;
dsites=Tuples[Range[0,1,1/(npts^(1/d)-1)],d];
matrixA[datasites_,centers_,e_]:=N[Exp[-(e*Outer[EuclideanDistance,datasites,centers,1])^2]];},SynchronousUpdating -> False, ContentSize -> {600,380}
]