MEDICAL DEVICE FOR GLUCOSE MONITORING OR REGULATION
 The present invention relates to a medical device suitable for analyte monitoring and for drug delivery, in particular for monitoring of glucose and for the treatment of patients with diabetes.
 Different medical devices intended for the treatment of patients with diabetes have previously been described: Separate glucose sensors (e.g. electrochemical, viscosimetric, or optical sensors), separate medication delivery devices (e.g. insulin pumps and insulin pens) as well as so-called closed loop systems, i.e. systems integrating glucose sensor and medication delivery. The latter ideally mimics the function of the pancreas, i.e. medication capable of controlling blood glucose level is released subject to blood glucose concentration.
 A medical system that combines a glucose monitoring unit with a drug infusion unit is described in patent application US 2006/0224141. In this medical system, the analyte monitoring unit is separated from the medication infusion unit. The analyte sensor is based on using electrodes in order to determine a change in electric resistance subject to a change of the analyte concentration. U.S. Pat. No. 5,569, 186A discloses another closed loop system, where parts of the medical system are completely implanted in the patient.  Another closed loop system is described in patent application WO 03047426A1, where an at least partially implanted glucose sensor is in communication with an injection pen, whereas the user can adjust the dose to be injected based on the glucose concentration measured by the glucose sensor.
 The above described closed loop systems for controlling medication infusion consist of at least two separated units, connected through an electronic interface.  WO 89/01794 discloses an implantable glucose sensor for a one part integrated drug delivery system. The sensor includes a liquid infusate, which is put under pressure and flows through a catheter. One section of the catheter contains a microporous membrane, where the concentration of the glucose present in the infusate is equilibrated with a response time between several minutes up to one hour. The equilibrated infusate then flows through a chemical valve which consists of a matrix containing concanavalin A, and dextran molecules. The matrix in the chemical valve changes its porosity subject to the glucose concentration present in the infusate, thus regulating the amount of infusate flowing into the body of a patient.
 When the system, as disclosed in WO 89/01794, is employed to solely monitor the concentration of glucose in the surrounding medium, the catheter contains an additional glucose sensor, such as an enzyme electrode, a fuel cell, or an affinity sensor, whereas the chemical valve is not present. Further proposed is a stand-alone sensor, in which the pressure in the infusate is determined before and after the infusate has passed the chemical valve matrix, whereas the pressuredrop across the chemical valve matrix is inversely proportional to the glucose concentration in the equilibrated infusate.
 In order to control the blood glucose level in a patient with diabetes, it is necessary to obtain results quickly in order to adjust the delivery of drugs. That is why response times of components within the glucose sensor are a crucial
factor for a successful drug delivery program. If, as described in WO 89/01794, an equilibration region has a response time of up to one hour, and a matrix contained in a chemical valve has an additional response time, the drug administration is adjusted to a blood glucose value that is no longer present in the patient, and thus the regulation of the patient's blood glucose level will not be optimal.
 Further, if the matrix that determines the pore size is in a fluent state, i.e. new components (such as dextran molecules) arriving with the infusate replace components that are washed away with the infusate into the patient's body, components that do not contribute to the treatment may enter the patient's body (concanavalin A is a toxic compound). The matrix is likely to have changed characteristics over time, as the replacement of new components may not take place in an evenly distributed manner (clusters are likely to occur at the entry of the matrix where the infusate with new components arrives at first).
 An object of this invention is to provide a medical device for the measurement of analyte levels in a patient that is rapid and accurate.
 Another object of this invention is to provide a medical device that enables fine and timely regulation of the analyte levels.
 A particular object of this invention is to provide a medical device for the measurement of blood glucose levels in a patient that is rapid and accurate, and that enables fine and timely regulation of blood glucose levels.  Another particular object of this invention is to provide a medical device for the regulation of blood glucose levels in a patient that provides rapid, accurate and timely regulation of blood glucose levels.
 It would be advantageous to provide a medical device for analyte measurement and/or regulation that is compact, light weight and economical to manufacture.  It would be advantageous to provide a medical device for analyte measurement and/or regulation that is convenient and easy to wear.
 Objects of this invention have been achieved by providing a medical device for measuring an analyte concentration according to claim 1, and by providing a method for measuring analyte concentration and regulating analyte levels according to claim 12.
 Disclosed herein is a medical device comprising a pressure generating means adapted to deliver a liquid. The medical device further comprises a sensor adapted to measure a flow resistance, and an implantable member comprising a porous membrane. Said porous membrane reversibly changes its porosity subject to changes in analyte concentration that occur in the medium surrounding the implantable member. In particular, the analyte may be glucose.  The liquid according to one embodiment of the present invention contains a drug capable of influencing an analyte level (for instance a blood glucose level) in a patient, such that the medical device may also be used for drug administration.
 Also disclosed is a method of measuring an analyte concentration comprising: providing a medical device comprising an implantable member with a porous membrane which changes its porosity subject to changes in analyte concentration occurring in the solution surrounding the implantable member; inj ecting discrete volume of liquid towards said porous membrane; measuring a value correlated to a resistance against flow of said liquid through said porous mem