A putty-clay model with three factors of production and partly endogenous technical progress