Equilibrium Interest Rate
We rewrite here the supply curve for credit which is a function of interest rate r:
We can also rewrite the demand curve for credit which is a function of interest rate r:
We can solve for equilibrium by trying out a vector of interest rate points, or using nonlinear solution methods. 
Alternatively, although this is not a system of linear equations, we can approximate these equations using first order taylor approximation, then they become a system of linear equations. We can then using linsolve to find approximate equilibrium Q and r.
First Order Taylor Approximation
Here, we discussed the formula for First Order Taylor Approximation: Definition of Differentials. Using the formula we have from there: We approximate the demand and Supply curves. Now x is the interest rate,  is the demand or supply at interest rate x we are interested in. a is the interest rate level where we solve for actual demand or supply. We approximate the
 is the demand or supply at interest rate x we are interested in. a is the interest rate level where we solve for actual demand or supply. We approximate the  by using information from
 by using information from  .
. For the problem here, let us approximate around  , this is 100 percent interest rate.
, this is 100 percent interest rate.  Note the demand and supply curves are monotonic, and they are somewhat linear for segments of r values. If they are not monotonically increasing or decreasing, we should not use taylor approximation. 
Approximate the Supply
% For Approximation, need to get the derivative with respect to R
SDiffR = diff(S, r)
SDiffR = 

% Now evaluate S at r = 1 and evaluate S'(r) also at r = 1
SatRis1 = subs(S, r, 1)
SatRis1 = 

SDiffRris1 = subs(SDiffR, r, 1)
SDiffRris1 = 

% We now have an equation that approximates supply
SupplyApproximate = SatRis1 + SDiffRris1*(r-1)
SupplyApproximate = 

Approximate the Demand
% For Approximation, need to get the derivative with respect to R
DDiffR = diff(D, r)
DDiffR = 

% Now evaluate D at r = 1 and evaluate D'(r) also at r = 1
DDiffRris1 = subs(DDiffR, r, 1)
DDiffRris1 = 
 % We now have an equation that approximates supply
DemandApproximate = DatRis1 + DDiffRris1*(r-1)
DemandApproximate = 
 Solve approximate Demand and Supply using a System of Linear Equations
Now we have two linear equations with two unknowns, we can rearrange the terms. Note that only r and  are unknowns, the other letters are parameters.
 are unknowns, the other letters are parameters. Starting with the equations from above:
We can plug this into matlab and solve for it
COEFMAT = [1, -b/4;1, k*h];
OUTVEC = [a-(3*b)/4; h + k*h];
approximateSolution = linsolve(COEFMAT, OUTVEC);
QEquiApproximate = approximateSolution(1)
QEquiApproximate = 

REquiApproximate = approximateSolution(2)
REquiApproximate = 

Now we have approximate analytical equations for demand and supply. If our  was close to true equilibrium rate, we would have a good approximation of how parameters of the model, the
 was close to true equilibrium rate, we would have a good approximation of how parameters of the model, the  constants, impact the equilibrium interest rate and quantity demanded and supplied.
 constants, impact the equilibrium interest rate and quantity demanded and supplied.