Problem: Nowadays all circuses in Berland have a round arena with diameter 13 meters, but in the past things were different.

In Ancient Berland arenas in circuses were shaped as a regular (equiangular) polygon, the size and the number of angles could vary from one circus to another. In each corner of the arena there was a special pillar, and the rope strung between the pillars marked the arena edges.

Recently the scientists from Berland have discovered the remains of the ancient circus arena. They found only three pillars, the others were destroyed by the time.

You are given the coordinates of these three pillars. Find out what is the smallest area that the arena could have.

Input

The input file consists of three lines, each of them contains a pair of numbers –– coordinates of the pillar. Any coordinate doesn't exceed 1000 by absolute value, and is given with at most six digits after decimal point.

Output

Output the smallest possible area of the ancient arena. This number should be accurate to at least 6 digits after the decimal point. It's guaranteed that the number of angles in the optimal polygon is not larger than 100.

Examples

Input

0.000000 0.000000
1.000000 1.000000
0.000000 1.000000


Output

1.00000000

Solution (in JAVA):

Solution:
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Collection;
import java.util.Locale;
import java.util.StringTokenizer;

public class Main {
	public static void main(String[] args) throws IOException {
		new Thread(null, new Runnable() {
			public void run() {
				try {
					long prevTime = System.currentTimeMillis();
					new Main().run();
					System.err.println("Total time: "
							+ (System.currentTimeMillis() - prevTime) + " ms");
					System.err.println("Memory status: " + memoryStatus());
				} catch (IOException e) {
					e.printStackTrace();
				}
			}
		}, "1", 1L << 24).start();
	}

	void run() throws IOException {
		in = new BufferedReader(new InputStreamReader(System.in));
		out = new PrintWriter(System.out);
		Object o = solve();
		if (o != null)
			out.println(o);
		out.close();
		in.close();
	}
	double EPS = 1e-6;

	private Object solve() throws IOException {
		Point a = new Point(nd(), nd());
		Point b = new Point(nd(), nd());
		Point c = new Point(nd(), nd());
		
		Line m_a = new Line(b,c).perpendicular(new Point((b.x+c.x)/2.0,(b.y+c.y)/2.0));
		Line m_b = new Line(a,c).perpendicular(new Point((a.x+c.x)/2.0,(a.y+c.y)/2.0));
		
		Point center = m_a.intersect(m_b);
		Vec oa = new Vec(center,a);
		double[] angles = { oa.angle(b), oa.angle(c) };
		double sides=-1;
		double alpha=-1;
		for (sides = 3; sides <= 100; sides+=1.0) {
			alpha = (2.0 * Math.PI) /  sides;
			double div1 = Math.round(angles[0] / alpha);
			double div2 = Math.round(angles[1] / alpha);

			if (Math.abs(div1 * alpha - angles[0]) < EPS
					&& Math.abs(div2 * alpha - angles[1]) < EPS)
				break;
		}
		double r = center.dist(a);
		return (r*r* sides *Math.sin(alpha))/2.0;
	}
	
	public class Vec implements Comparable<Vec> {
		double EPS = 1e-7;
		Point src;
		Point dst;
		double angle;

		public Vec(Point src, Point dst) {
			super();
			this.src = src;
			this.dst = dst;
			this.angle = angle();
		}

		private double angle() {
			double ret = Math.atan2(dst.y - src.y, dst.x - src.x);
			if(ret<0)
				ret = 2.0*Math.PI +ret;
			return ret;
		}
		
		public double angle(Point p){
			return parse(Math.atan2(p.y - src.y, p.x-src.x)-angle);
		}

		private double parse(double d) {
			while(d<0)
				d+=Math.PI*2.0;
			while(d>Math.PI * 2.0)
				d-=Math.PI*2.0;
			return d;
		}


		// right =1, same =0, left =-1
		public int position(Point p) {
			double cross = (p.x - dst.x) * (src.y - dst.y) - (p.y - dst.y)
					* (src.x - dst.x);
			if (Math.abs(cross) < EPS)
				return 0;
			if (cross > 0) {
				return -1;
			} else {
				return 1;
			}
		}

		// requiere position(p) == 0
		// antes de src =-1, despues de dst =1, en el medio ( con src y dst) 0
		public int inside(Point p) {
			if (src.same(p) || dst.same(p))
				return 0;
			if (Math.abs(Math.atan2(src.y - p.y, src.x - p.x)
					- Math.atan2(dst.y - src.y, dst.x - src.x)) < EPS)
				return -1;
			if (Math.abs(Math.atan2(p.y - dst.y, p.x - dst.x)
					- Math.atan2(dst.y - src.y, dst.x - src.x)) < EPS)
				return 1;
			return 0;
		}

		@Override
		public int compareTo(Vec o) {
			int res = src.compareTo(o.src);
			if (res != 0)
				return res;
			return dst.compareTo(o.dst);
		}
	}
	
	class Line implements Comparable<Line> {

		// ax+by+c==0
		// siempre a o b es 1
		double EPS = 1e-9;
		double a;
		double b;
		double c;
		double angle;	//(0,pi]

		private Line() {
		}

		public Line(Point p1, Point p2) {
			if (Math.abs(p1.x - p2.x) < EPS) {
				this.a = 1;
				this.b = 0;
				this.c = -p1.x;
			} else {
				this.a = -(p1.y - p2.y) / (p1.x - p2.x);
				this.b = 1;
				this.c = -(p1.x * a + p1.y);
			}
			this.angle = angle();
		}

		boolean isParallel(Line other) {
			return (Math.abs(a - other.a) < EPS) && (Math.abs(b - other.b) < EPS);
		}

		boolean same(Line other) {
			return (isParallel(other) && Math.abs(c - other.c) < EPS);
		}

		// requiere !this.isParallel(other)
		Point intersect(Line other) {

			double x = (other.b * c - b * other.c) / (other.a * b - a * other.b);
			double y = -1;

			if (Math.abs(b) > EPS) {
				y = -(a * x + c) / b;
			} else {
				y = -(other.a * x + other.c) / other.b;
			}
			return new Point(x, y);
		}

		Line parallel(Point p) {
			Line ret = new Line();
			ret.a = a;
			ret.b = b;
			ret.c = -(a * p.x + b * p.y);
			return ret;
		}

		Line perpendicular(Point p) {
			Line ret = new Line();
			if (Math.abs(a) > EPS) {
				ret.b = 1;
				ret.a = -b / a;
			} else {
				ret.a = -b;
				ret.b = 0;
			}
			ret.c = 0;
			return ret.parallel(p);
		}
		boolean isPerpendicular(Line other){
			if(isParallel(other))
				return false;
			Point p = intersect(other);
			return same(perpendicular(p));
		}

		public double angle() {
			double ret= Math.atan2(-a, b);
			return (ret<=0.0? Math.PI+ret : ret);
		}

		@Override
		public int compareTo(Line o) {
			if (o.angle - angle > EPS)
				return -1;
			if (angle - o.angle > EPS)
				return 1;
			if (o.c - c < EPS)
				return -1;
			if (c - o.c > EPS)
				return 1;
			return 0;
		}

	}
	
	public class Point implements Comparable<Point> {
		double EPS = 1e-9;
		double x, y;

		Point(double x, double y) {
			this.x = x;
			this.y = y;
		}
		
		public boolean same(Point other) {
			if (this == other)
				return true;
			return Math.abs(x - other.x) < EPS && Math.abs(y - other.y) < EPS;
		}
		
		public double dist(Point p) {
			return Math.hypot(x-p.x, y-p.y);
		}

		@Override
		public int compareTo(Point o) {
			if (Math.abs(x - o.x) > EPS)
				return Double.compare(x, o.x);
			if (Math.abs(y - o.y) > EPS)
				return Double.compare(y, o.y);
			return 0;
		}

		@Override
		public String toString() {
			return "Point [x=" + x + ", y=" + y + "]";
		}
	}


	BufferedReader in;
	PrintWriter out;
	StringTokenizer strTok = new StringTokenizer("");

	String nextToken() throws IOException {
		while (!strTok.hasMoreTokens())
			strTok = new StringTokenizer(in.readLine());
		return strTok.nextToken();
	}

	int ni() throws IOException {
		return Integer.parseInt(nextToken());
	}

	long nl() throws IOException {
		return Long.parseLong(nextToken());
	}

	double nd() throws IOException {
		return Double.parseDouble(nextToken());
	}

	int[] nia(int size) throws IOException {
		int[] ret = new int[size];
		for (int i = 0; i < size; i++)
			ret[i] = ni();
		return ret;
	}

	long[] nla(int size) throws IOException {
		long[] ret = new long[size];
		for (int i = 0; i < size; i++)
			ret[i] = nl();
		return ret;
	}

	double[] nda(int size) throws IOException {
		double[] ret = new double[size];
		for (int i = 0; i < size; i++)
			ret[i] = nd();
		return ret;
	}

	String nextLine() throws IOException {
		strTok = new StringTokenizer("");
		return in.readLine();
	}

	boolean EOF() throws IOException {
		while (!strTok.hasMoreTokens()) {
			String s = in.readLine();
			if (s == null)
				return true;
			strTok = new StringTokenizer(s);
		}
		return false;
	}

	void printRepeat(String s, int count) {
		for (int i = 0; i < count; i++)
			out.print(s);
	}

	void printArray(int[] array) {
		for (int i = 0; i < array.length; i++) {
			if (i > 0)
				out.print(' ');
			out.print(array[i]);
		}
		out.println();
	}

	void printArray(long[] array) {
		for (int i = 0; i < array.length; i++) {
			if (i > 0)
				out.print(' ');
			out.print(array[i]);
		}
		out.println();
	}

	void printArray(double[] array) {
		for (int i = 0; i < array.length; i++) {
			if (i > 0)
				out.print(' ');
			out.print(array[i]);
		}
		out.println();
	}

	void printArray(double[] array, String spec) {
		for (int i = 0; i < array.length; i++) {
			if (i > 0)
				out.print(' ');
			out.printf(Locale.US, spec, array[i]);
		}
		out.println();
	}

	void printArray(Object[] array) {
		boolean blank = false;
		for (Object x : array) {
			if (blank)
				out.print(' ');
			else
				blank = true;
			out.print(x);
		}
		out.println();
	}

	@SuppressWarnings("rawtypes")
	void printCollection(Collection collection) {
		boolean blank = false;
		for (Object x : collection) {
			if (blank)
				out.print(' ');
			else
				blank = true;
			out.print(x);
		}
		out.println();
	}

	static String memoryStatus() {
		return (Runtime.getRuntime().totalMemory()
				- Runtime.getRuntime().freeMemory() >> 20)
				+ "/" + (Runtime.getRuntime().totalMemory() >> 20) + " MB";
	}

	public void pln() {
		out.println();
	}

	public void pln(int arg) {
		out.println(arg);
	}

	public void pln(long arg) {
		out.println(arg);
	}

	public void pln(double arg) {
		out.println(arg);
	}

	public void pln(String arg) {
		out.println(arg);
	}

	public void pln(boolean arg) {
		out.println(arg);
	}

	public void pln(char arg) {
		out.println(arg);
	}

	public void pln(float arg) {
		out.println(arg);
	}

	public void pln(Object arg) {
		out.println(arg);
	}

	public void p(int arg) {
		out.print(arg);
	}

	public void p(long arg) {
		out.print(arg);
	}

	public void p(double arg) {
		out.print(arg);
	}

	public void p(String arg) {
		out.print(arg);
	}

	public void p(boolean arg) {
		out.print(arg);
	}

	public void p(char arg) {
		out.print(arg);
	}

	public void p(float arg) {
		out.print(arg);
	}

	public void p(Object arg) {
		out.print(arg);
	}

}