Law is a set of rules created and enforced by social or governmental institutions to regulate behavior. Its precise definition has been a matter of longstanding debate. It has been variously described as a science and as the art of justice.
A common view is that law is the body of legal precepts and the official content of justice in an organised political society. It has four principal functions: establishing standards, maintaining order, resolving disputes and protecting liberties and rights.
In an idealistic sense law is the entire system of adjusting relations and ordering conduct by systematic application of the force of organised political society. The judicial system is the organ through which this control is exercised.
Another definition of law is that it is a rule or principle formulated and applied by determinate authority. It is this definition that Blackstone used in his famous definition of law.
It has been argued that the definition of law should include not just the rules but also the processes by which they are adopted, administered and enforced. This includes the nature of the legal system itself and the societal values that inform its operation.
One theory of law views it as a mechanism for harmonizing conflicting groups. This is based on the assumption that a society has a single monolithic set of values to which everyone in the society subscribes. Conflicts are inevitable in such a situation and the role of law is to provide a formal means of settling disputes.