function [gx, gpx, fpx] = bindingfuncs(X)

% h=1;
% k7=0.005;
% g1=2.*k7;
% g2=20.*g1;
% g3=3.*g1;
% fp1=0.88;
% gp1=0.22;
% gp2=4.*(fp1+gp1);
% gp3=3.*gp1;
% gx=g2/h.*(X<0)+g1.*(X)/h.*(X>=0 & X<=h)+ (g1+g3).*(X)/h.*(X>h);
% gpx= gp2/h.*(X<0)+gp1.*(X)/h.*(X>=0 & X<=h)+(gp1+gp3).*(X)/h.*(X>h);
% fpx=0.*(X<0)+(fp1.*(X)/h).*(X>=0 & X<=h)+0.*(X>h);
 h=1;
k7=0.005;
g1=2.*k7;
g2=20.*g1;
g3=3.*g1;
fp1=0.88;
gp1=0.22;
gp2=4.*(fp1+gp1);
gp3=3.*gp1;
gx=g2/h.*(X<0)+g1.*(X)/h.*(X>=0 & X<=h)+ (g1+g3).*(X)/h.*(X>h);
gpx= gp2/h.*(X<0)+gp1.*(X)/h.*(X>=0 & X<=h)+(gp1+gp3).*(X)/h.*(X>h);
fpx=0.*(X<0)+(fp1.*(X)/h).*(X>=0 & X<=h)+0.*(X>h);   
% k1=0.35.*(X<0)+0.06.*(X).*(X>=0 & X<=h)+ (0.35).*(X>h);
% k6=0.35.*(X<0)+0.06.*(X).*(X>=0 & X<=h)+ (0.35).*(X>h);