package t::Mock::MapIt;

use JSON::MaybeXS;
use Web::Simple;
use LWP::Protocol::PSGI;

use mySociety::Locale;

has json => (
    is => 'lazy',
    default => sub {
        JSON->new->pretty->allow_blessed->convert_blessed;
    },
);

sub output {
    my ($self, $response) = @_;
    # We must make sure we output correctly for testing purposes, we might
    # be within a different locale here...
    my $json = mySociety::Locale::in_gb_locale {
        $self->json->encode($response) };
    return [ 200, [ 'Content-Type' => 'application/json' ], [ $json ] ];
}

my @PLACES = (
    [ '?', 53.387402, -2.943997, 2527, 'Liverpool City Council', 'MTD' ],
    [ 'EH1 1BB', 55.952055, -3.189579, 2651, 'Edinburgh City Council', 'UTA', 20728, 'City Centre', 'UTE' ],
    [ 'BS10 5EE', 51.494885, -2.602237, 2561, 'Bristol City Council', 'UTA', 148646, 'Bedminster', 'UTW' ],
    [ '?', 51.444878, -2.641142, 2642, 'North Somerset Council', 'UTA' ],
    [ '?', 51.452340, -2.654832, 2642, 'North Somerset Council', 'UTA' ],
    [ '?', 51.495216, -2.551191, 2608, 'South Gloucestershire Council', 'UTA' ],
    [ 'BS20 5EE', 51.496194, -2.603439, 2608, 'Borsetshire County Council', 'CTY', 148646, 'Bedminster', 'UTW' ],
    [ 'SL9 0NX', 51.615559, -0.556903, 163793, 'Buckinghamshire Council', 'CTY', 2257, 'Chiltern District Council', 'DIS', 2796, 'Chalfont Common', 'DIW', 143422, 'Chalfont St Peter', 'CED', 53822, 'Adstock', 'CPC' ],
    [ '?', 51.615499, -0.556667, 163793, 'Buckinghamshire Council', 'CTY', 2257, 'Chiltern District Council', 'DIS', 2796, 'Chalfont Common', 'DIW', 143422, 'Chalfont St Peter', 'CED', 53822, 'Adstock', 'CPC' ],
    [ '?', 51.615965, -0.556367, 163793, 'Buckinghamshire Council', 'CTY', 2257, 'Chiltern District Council', 'DIS', 2796, 'Chalfont Common', 'DIW', 143422, 'Chalfont St Peter', 'CED', 53822, 'Adstock', 'CPC' ],
    [ '?', 51.615439, -0.558362, 163793, 'Buckinghamshire Council', 'CTY', 2257, 'Chiltern District Council', 'DIS', 2796, 'Chalfont Common', 'DIW', 143422, 'Chalfont St Peter', 'CED' ],
    [ 'HP19 8FF', 51.822364, -0.826409, 163793, 'Buckinghamshire Council', 'CTY', 2258, 'Aylesbury Vale District Council', 'DIS', 144545, 'Gatehouse', 'DIW', 143444, 'Aylesbury North-West', 'CED' ],
    [ '?', 51.995, -0.986 , 163793, 'Buckinghamshire Council', 'CTY', 2258, 'Aylesbury Vale District Council', 'DIS', 144539, 'Buckingham South', 'DIW', 143424, 'Buckingham West', 'CED' ],
    [ '?', 51.940, -0.887, 163793, 'Buckinghamshire Council', 'CTY', 2258, 'Aylesbury Vale District Council', 'DIS', 144531, 'Winslow', 'DIW', 143404, 'Winslow', 'CED' ],
    [ '?', 51.563, -0.499, 163793, 'Buckinghamshire Council', 'CTY', 2256, 'South Bucks District Council', 'DIS', 144508, 'Denham', 'DIW', 143412, 'Denham', 'CED' ],
    [ 'HP9 2PJ', 51.611, -0.644, 163793, 'Buckinghamshire Council', 'CTY', 2256, 'South Bucks District Council', 'DIS', 144516, 'Beaconsfield North', 'DIW', 143415, 'Beaconsfield', 'CED' ],
    [ '?', 51.628661, -0.748238, 163793, 'Buckinghamshire Council', 'CTY', 2255, 'Wycombe District Council', 'DIS', 2744, 'Abbey', 'DIW', 143428, 'Abbey', 'CED' ],
    [ '?', 51.566667, -0.766667, 163793, 'Buckinghamshire Council', 'CTY', 2255, 'Wycombe District Council', 'DIS', 2752, 'Marlow South East', 'DIW', 143427, 'Marlow', 'CED' ],
    [ 'SW1A 1AA', 51.501009, -0.141588, 2504, 'Westminster City Council', 'LBO' ],
    [ '?', 51.507461, -0.126890, 2504, 'Westminster City Council', 'LBO' ],
    [ 'GL50 2PR', 51.896268, -2.093063, 2226, 'Gloucestershire County Council', 'CTY', 2326, 'Cheltenham Borough Council', 'DIS', 4544, 'Lansdown', 'DIW', 143641, 'Lansdown and Park', 'CED' ],
    [ 'OX20 1SZ', 51.754926, -1.256179, 2237, 'Oxfordshire County Council', 'CTY', 2421, 'Oxford City Council', 'DIS' ],
    [ 'OX16 9UP', 52.038712, -1.346397, 2237, 'Oxfordshire County Council', 'CTY', 2419, 'Cherwell District Council', 'DIS', 151767, "Banbury, Calthorpe & Easington", "DIW" ],
    [ 'RG9 6TL', 51.561705, -0.868388, 163793, 'Buckinghamshire Council', 'CTY'],
    [ 'PE9 2GX', 52.656144, -0.502566, 2232, 'Lincolnshire County Council', 'CTY'],
    [ 'LE15 0GJ', 52.670447, -0.727877, 2600, 'Rutland County Council', 'CTY'],
    [ 'BR1 3UH', 51.4021, 0.01578, 2482, 'Bromley Council', 'LBO' ],
    [ 'BR1 3UH', 51.402096, 0.015784, 2482, 'Bromley Council', 'LBO' ],
    [ 'BR1 3UH', 51.402092, 0.015783, 2482, 'Bromley Council', 'LBO', 8141, 'Bromley Town', 'LBW' ],
    [ 'BR1 3EF', 51.4039, 0.018697, 2482, 'Bromley Council', 'LBO' ],
    [ 'BR1 1AA', 51.401546, 0.015415, 2482, 'Bromley Council', 'LBO' ],
    # Crystal Palace Park
    [ '?', 51.422382, -0.064555, 2482, 'Bromley Council', 'LBO' ],
    # National Sports Centre in Crystal Palace Park
    [ '?', 51.419275, -0.071410, 2482, 'Bromley Council', 'LBO' ],
    [ 'KT1 1AA', 51.408688, -0.304465, 2480, 'Kingston upon Thames Council', 'LBO' ],
    [ 'SM2 5HF', 51.354679, -0.183895, 2498, 'Sutton Borough Council', 'LBO' ],
    [ '?', 51.466707, 0.181108, 2494, 'London Borough of Bexley', 'LBO' ],
    [ '?', 51.512868, 0.125436, 2494, 'London Borough of Bexley', 'LBO' ],
    [ 'DA6 7AT', 51.45556, 0.15356, 2494, 'London Borough of Bexley', 'LBO' ],
    [ 'NN1 1NS', 52.236251, -0.892052, 164186, 'West Northamptonshire Council', 'UTA' ],
    [ 'NN1 2NS', 52.238301, -0.889992, 164186, 'West Northamptonshire Council', 'UTA' ],
    [ '?', 52.238827, -0.894970, 164186, 'West Northamptonshire Council', 'UTA' ],
    [ '?', 52.23025, -1.015826, 164186, 'West Northamptonshire Council', 'UTA' ],
    [ '?', 52.239694, -0.889992, 164186, 'West Northamptonshire Council', 'UTA' ],
    # FixMyStreet::munge_sendreport_params depends on a call to generation 36:
    [ '?', 52.236252, -0.892053, 2234, 'Northamptonshire County Council', 'CTY', 2397, 'Northampton Borough Council', 'DIS' ],
    [ 'E8 1DY', 51.552267, -0.063316, 2508, 'Hackney Borough Council', 'LBO' ],
    [ 'E8 2DY', 51.552287, -0.063326, 2508, 'Hackney Council', 'LBO' ],
    [' E6 1AX', 51.524448, -0.077625, 2508, 'Hackney Council', 'LBO', 144379, 'Hoxton East & Shoreditch', 'LBW' ],
    [ 'TW7 5JN', 51.482286, -0.328163, 2483, 'Hounslow Borough Council', 'LBO' ],
    [ '?', 51.48111, -0.327219, 2483, 'Hounslow Borough Council', 'LBO' ],
    [ '?', 51.482045, -0.327219, 2483, 'Hounslow Borough Council', 'LBO' ],
    [ '?', 51.345714, -0.227959, 2457, 'Epsom and Ewell Borough Council', 'DIS' ],
    [ 'CW11 1HZ', 53.145324, -2.370437, 21069, 'Cheshire East Council', 'UTA', 135301, 'Sandbach Town', 'UTW' ],
    [ '?', 50.78301, -0.646929 ],
    [ 'GU51 4AE', 51.279456, -0.846216, 2333, 'Hart District Council', 'DIS', 2227, 'Hampshire County Council', 'CTY' ],
    [ 'WS1 4NH', 52.563074, -1.991032, 2535, 'Sandwell Borough Council', 'MTD' ],
    [ 'PO30 5XJ', 50.71086, -1.29573, 2636, 'Isle of Wight Council', 'UTA' ],
    [ 'PE1 1HF', 52.57146, -0.24201, 2566, 'Peterborough City Council', 'UTA' ],
    [ '?', 52.571903, -0.242007, 2566, 'Peterborough City Council', 'UTA' ],
    [ '?', 52.570792, -0.241841, 2566, 'Peterborough City Council', 'UTA' ],
    [ 'PE1 3NA', 52.599211, -0.255387, 2566, 'Peterborough City Council', 'UTA' ],
    [ 'OX28 4DS', 51.784721, -1.494453 ],
    [ 'E14 2DN', 51.508536, '0.000001' ],
    [ '?', 52.51093, -1.86514, 11809, 'West Midlands', 'EUR' ],
    [ '?', 51.379009, -2.359276, 2551, 'Bath and North East Somerset Council', 'UTA' ],
    [ 'The Circus', 51.386269, -2.364050, 2551, 'Bath and North East Somerset Council', 'UTA' ],
    [ 'SM1 1AA', 51.359723, -0.193146, 2498, 'Sutton Council', 'LBO' ],
    [ 'SM4 5DX', 51.400975, -0.19655, 2500, 'Merton Council', 'LBO' ],
    [ 'SY4 5DL', 52.855684, -2.723877, 2238, 'Shropshire Council', 'UTA' ],
    # Norway
    [ '3290', 59, 10, 709, 'Larvik', 'NKO', 7, 'Vestfold', 'NFY' ],
    [ '0045', "59.9", "10.9", 301, 'Oslo', 'NKO', 3, 'Oslo', 'NFY' ],
    ['?', 51.015143, -0.912160, 2227, 'Hampshire County Council', 'CTY'],
    ['?', 51.020097, -0.926065, 2227, 'Hampshire County Council', 'CTY'],
    ['?', 51.511258, -0.011937, 2506, 'Tower Hamlets Borough Council', 'LBO'],
    ['?', 51.512139, -0.013074, 2506, 'Tower Hamlets Borough Council', 'LBO'],
    ['WC1H 8EQ', 51.529432, -0.124514, 2505, 'Camden Borough Council', 'LBO'],
    ['HA9 0FJ', 51.55904, -0.28168, 2488, 'Brent Council', 'LBO'], # Somewhere in Brent
    ['?', 51.564493, -0.277156, 2488, 'Brent Council', 'LBO'], # Housing estate in Brent
    ['?', 51.563623, -0.274082, 2488, 'Brent Council', 'LBO'], # Park in Brent
    ['?', 51.563683, -0.276120, 2488, 'Brent Council', 'LBO'], # Road in Brent
    ['?', 51.551717, -0.260869, 2488, 'Brent Council', 'LBO'], # TfL road in Brent
    ['?', 51.534948, -0.211045, 2488, 'Brent Council', 'LBO'], # Queen's Park in Brent
    [ 'SE1 2QH', 51.50351, -0.08051, 2491, 'Southwark Council', 'LBO' ],
    [ '?', 51.50352, -0.08052, 2491, 'Southwark Council', 'LBO' ],
    [ 'BA11 6BA', 51.26345, -2.28191, 2428, 'Mendip District Council', 'DIS' ],
    [ 'DL10 6BN', 54.45012, -1.65621, 2406, 'Richmondshire District Council', 'DIS' ],
    [ 'CA12 5FJ', 54.60102, -3.13648, 2274, 'Allerdale Borough Council', 'DIS' ],
    [ 'NE61 1BE', 55.169081, -1.691012, 2248, 'Northumberland County Council', 'UTA' ],
    [ 'SG17 5TQ', 52.03553, -0.36067, 21070, 'Central Bedfordshire Council', 'UTA' ],
    [ '?', 51.558568, -0.207702, 2489, 'Barnet Borough Council', 'DIS' ],
    [ '?', 51.418776, 0.005357, 2492, 'Lewisham Borough Council', 'DIS' ],
    [ '?', 52.956196, -1.151204, 2412, 'Gedling Borough Council', 'DIS', 2236, 'Nottinghamshire County Council', 'CTY' ],

);

sub dispatch_request {
    my $self = shift;

    sub (GET + /postcode/*) {
        my ($self, $postcode) = @_;
        foreach (@PLACES) {
            if ($postcode eq $_->[0] || $postcode eq $_->[0] =~ s/ //gr) {
                my %areas;
                for (my $i=3; $i<@$_; $i+=3) {
                    $areas{"$_->[$i]"} = { id => $_->[$i], name => $_->[$i+1], type => $_->[$i+2] };
                }
                return $self->output({
                    wgs84_lat => $_->[1], wgs84_lon => $_->[2],
                    postcode => $postcode, coordsyst => 'G',
                    areas => \%areas,
                });
            }
        }
        my $response = {
            wgs84_lat => 51.5, wgs84_lon => -2.1, postcode => $postcode, coordsyst => 'G',
        };
        return $self->output($response);
    },

    sub (GET + /point/**.* + ?*) {
        my ($self, $point, $query) = @_;
        foreach (@PLACES) {
            if ($point eq "4326/$_->[2],$_->[1]") {
                my %out;
                for (my $i=3; $i<@$_; $i+=3) {
                    $out{"$_->[$i]"} = { id => $_->[$i], name => $_->[$i+1], type => $_->[$i+2] };
                }
                if ($query->{type}) {
                    my %types = map { $_ => 1 } split ',', $query->{type};
                    %out = map { $_ => $out{$_} } grep { $types{$out{$_}{type}} } keys %out;
                }
                return $self->output(\%out);
            }
        }
        my $response = {
            "153255" => {"parent_area" => 2608, "generation_high" => 36, "all_names" => {}, "id" => 153255, "codes" => {"gss" => "E05012110", "unit_id" => "174450"}, "name" => "Chipping Sodbury & Cotswold Edge", "country" => "E", "type_name" => "Unitary Authority ward (UTW)", "generation_low" => 36, "country_name" => "England", "type" => "UTW"},
            "2608" => {"parent_area" => undef, "generation_high" => 36, "all_names" => {}, "id" => 2608, "codes" => {"ons" => "00HD", "gss" => "E06000025", "unit_id" => "25559"}, "name" => "South Gloucestershire Council", "country" => "E", "type_name" => "Unitary Authority", "generation_low" => 1, "country_name" => "England", "type" => "UTA"}
        };
        return $self->output($response);
    },

    sub (GET + /areas/*) {
        my ($self, $areas) = @_;
        if ($areas eq 'Hart') {
            $self->output({2333 => {parent_area => undef, id => 2333, name => "Hart District Council", type => "DIS"}});
        } elsif ($areas eq 'Birmingham') {
            $self->output({2514 => {parent_area => undef, id => 2514, name => "Birmingham City Council", type => "MTD"}});
        } elsif ($areas eq 'Gloucestershire') {
            $self->output({2226 => {parent_area => undef, id => 2226, name => "Gloucestershire County Council", type => "CTY"}});
        } elsif ($areas eq 'Cheltenham') {
            $self->output({2326 => {parent_area => undef, id => 2326, name => "Cheltenham Borough Council", type => "DIS"}});
        } elsif ($areas eq 'UTA') {
            $self->output({2650 => {parent_area => undef, id => 2650, name => "Aberdeen Council", type => "UTA"}});
        } elsif ($areas eq 'DIS,LBO,MTD,UTA,CTY,COI,LGD') {
            $self->output({2508 => {parent_area => undef, id => 2508, name => "Hackney Council", type => "LBO"}});
        } elsif ($areas eq 'GRE') {
            $self->output({2493 => {parent_area => undef, id => 2493, name => "Greenwich Borough Council", type => "LBO"}});
        } elsif ($areas eq 'LBO' || $areas eq 'LBO,UTA,DIS') {
            $self->output({
                2482 => {parent_area => undef, id => 2482, name => "Bromley Borough Council", type => "LBO"},
                2483 => {parent_area => undef, id => 2483, name => "Hounslow Borough Council", type => "LBO"},
            });
        } elsif ($areas eq 60705) {
            $self->output({60705 => {parent_area => 2245, id => 60705, name => "Trowbridge", type => "CPC"}});
        }
    },

    sub (POST + /areas) {
        my ($self, $areas) = @_;
        $self->output({53319 => {parent_area => 2217, id => 53319, name => "Bradenham", type => "CPC"}});
    },

    sub (GET + .geojson) {
        my ($self) = @_;
        return [ 200, [ 'Content-Type' => 'text/html' ], [ '{ "type": "Polygon", "coordinates": [ [ [ -2.628887610656303, 51.6416000233516 ], [ -2.627997933115663, 51.64267930705379 ], [ -2.62729758117729, 51.644287101889574 ], [ -2.624828153396058, 51.64768374200581 ], [ -2.623083921531683, 51.648866319056673 ], [ -2.621138681992249, 51.650572451312357 ], [ -2.619281456879798, 51.652590895708542 ], [ -2.617688060838417, 51.655108776219315 ], [ -2.617005541882011, 51.655727377054454 ], [ -2.615023843110563, 51.656918360487168 ], [ -2.612113285345945, 51.658056628664745 ], [ -2.60957228091137, 51.658196591484653 ], [ -2.599133960093137, 51.659885831427125 ], [ -2.591733711631031, 51.660468262821567 ], [ -2.586234534167322, 51.660486863075633 ], [ -2.583985127868503, 51.660840635263419 ], [ -2.582574937847228, 51.661236944306765 ], [ -2.580285680729184, 51.662208549915654 ], [ -2.579459490394377, 51.662835730557724 ], [ -2.574489601617846, 51.664611701752563 ], [ -2.570501061181081, 51.66626395561083 ], [ -2.565224884413629, 51.668815129922514 ], [ -2.558130519127701, 51.673367162781922 ], [ -2.551366274652055, 51.678304804609361 ], [ -2.547997628201342, 51.680197058131128 ], [ -2.545307270671993, 51.68114647651511 ], [ -2.540812299669275, 51.6823936848144 ], [ -2.5338121569224, 51.676537308293852 ], [ -2.526741601679602, 51.674042696109176 ], [ -2.522034007407363, 51.672119823793878 ], [ -2.520094956565791, 51.671505332219979 ], [ -2.519781109696169, 51.671252251703486 ], [ -2.5174914494476, 51.670697695535281 ], [ -2.515764574847389, 51.669900625104425 ], [ -2.509861242051534, 51.667911411373971 ], [ -2.509005492836268, 51.665998191406331 ], [ -2.508185534983574, 51.665987361727943 ], [ -2.508074595576015, 51.666151526423654 ], [ -2.507196392514714, 51.666230829051145 ], [ -2.505351251393102, 51.666215415527603 ], [ -2.501364254745949, 51.665364829802009 ], [ -2.50125167534058, 51.665123424220397 ], [ -2.501673903811009, 51.66473321824293 ], [ -2.500844875962225, 51.664416669885547 ], [ -2.500076250819516, 51.664864168898333 ], [ -2.498637529371763, 51.664987141989791 ], [ -2.496423511524656, 51.664418371075733 ], [ -2.495195435664323, 51.664639376822329 ], [ -2.492540116802006, 51.664164977203349 ], [ -2.491877084799754, 51.664353014552404 ], [ -2.4908355957446, 51.664313329050088 ], [ -2.489640507456253, 51.663958681348937 ], [ -2.489816442154644, 51.66338248994056 ], [ -2.491142021666106, 51.663227648976942 ], [ -2.491678718214046, 51.662855876253801 ], [ -2.491801955968634, 51.660355777422112 ], [ -2.492343750761095, 51.658325111491521 ], [ -2.492705029773037, 51.657776002646905 ], [ -2.49170186055767, 51.655922599029871 ], [ -2.491403750233439, 51.653750642627955 ], [ -2.491741932835433, 51.653073992992113 ], [ -2.492685380239788, 51.652372331555981 ], [ -2.493014750438256, 51.651819759555082 ], [ -2.491845142971805, 51.649662246391529 ], [ -2.489350668232967, 51.648878697255761 ], [ -2.488787865173645, 51.648959334125891 ], [ -2.486074529489112, 51.648383457456383 ], [ -2.48497067484795, 51.648416787419464 ], [ -2.486435292188961, 51.647385741218471 ], [ -2.487569069367985, 51.647033981924828 ], [ -2.487947846213224, 51.646508184646606 ], [ -2.490050540517064, 51.64569646041015 ], [ -2.489891524185981, 51.645558697588008 ], [ -2.490835115873529, 51.645135790230988 ], [ -2.490675732082632, 51.644831648363642 ], [ -2.487935768621695, 51.644851160482531 ], [ -2.487262068464783, 51.644686678695834 ], [ -2.485114198154437, 51.645207214783518 ], [ -2.482152699357456, 51.646406290555156 ], [ -2.477267625079288, 51.646678839317303 ], [ -2.474718455352253, 51.646562435880156 ], [ -2.473060124115014, 51.646785849660731 ], [ -2.470962755671979, 51.647593562244033 ], [ -2.470335638336707, 51.6474720323463 ], [ -2.470310912442152, 51.64773109680953 ], [ -2.469432830767572, 51.647932364026481 ], [ -2.469153206042532, 51.648295817797951 ], [ -2.468396031807806, 51.648725087415656 ], [ -2.468083576075323, 51.649407859362682 ], [ -2.465790694526994, 51.651042592059483 ], [ -2.464566162380982, 51.650878456955972 ], [ -2.463714448908142, 51.650974408728942 ], [ -2.463316571399485, 51.65164492082782 ], [ -2.462748963518903, 51.651975338242494 ], [ -2.460442535615518, 51.652599416804989 ], [ -2.458779997856523, 51.651278831705909 ], [ -2.458432636722947, 51.65151847994553 ], [ -2.455800668071223, 51.651830751042461 ], [ -2.455951411216347, 51.652304050978515 ], [ -2.452520726350855, 51.651368747603996 ], [ -2.450657247012778, 51.650306888402255 ], [ -2.449208090706901, 51.649787322274783 ], [ -2.445656716368873, 51.649331469131219 ], [ -2.445043570707363, 51.649889478408156 ], [ -2.445229196842058, 51.649957987583569 ], [ -2.445029264971886, 51.650643057152401 ], [ -2.444629784166214, 51.650885468826424 ], [ -2.444804067117561, 51.651109616379351 ], [ -2.444281558139852, 51.651336403197519 ], [ -2.44416020816488, 51.651638074441067 ], [ -2.443322711762089, 51.652024249921965 ], [ -2.442984733285543, 51.652489433685339 ], [ -2.442644615911436, 51.652295661654477 ], [ -2.441935553208066, 51.652214738447547 ], [ -2.439556972499991, 51.649896670618475 ], [ -2.439076158197298, 51.650542242370335 ], [ -2.438672484838386, 51.650205686025366 ], [ -2.437707501790271, 51.650102322852348 ], [ -2.437064603963198, 51.649536451733759 ], [ -2.435506942811041, 51.649886599595014 ], [ -2.434490357745992, 51.649532526303425 ], [ -2.434305030226391, 51.649194247590366 ], [ -2.433049880633498, 51.64928877246772 ], [ -2.432177864881468, 51.649083358423219 ], [ -2.431703150435795, 51.64856277093034 ], [ -2.431876751991456, 51.648271706714439 ], [ -2.431802176477283, 51.647722590467545 ], [ -2.4320475777, 51.647238004251946 ], [ -2.432011971662659, 51.646989956688031 ], [ -2.430835794928993, 51.646559945000618 ], [ -2.427230491966149, 51.647241255703307 ], [ -2.426151098823684, 51.646961945230963 ], [ -2.425926362751782, 51.646581459450047 ], [ -2.424117159450851, 51.645833677586026 ], [ -2.423482170832871, 51.646078755856657 ], [ -2.422764988494484, 51.645584984179337 ], [ -2.421926660851629, 51.645414518597399 ], [ -2.42128557272021, 51.645477944856367 ], [ -2.420946184375182, 51.645038535435383 ], [ -2.420216826727378, 51.644614993764129 ], [ -2.41880613344551, 51.644293655663574 ], [ -2.416737704741536, 51.643308393773793 ], [ -2.415768374096149, 51.643658886349506 ], [ -2.415639038670033, 51.644213229572763 ], [ -2.415299296646752, 51.644353757465524 ], [ -2.415321907871578, 51.644624327873728 ], [ -2.413919275481692, 51.644059218331307 ], [ -2.413051411600185, 51.643490413404365 ], [ -2.412382435439872, 51.64271146609137 ], [ -2.411536199836601, 51.642789042939995 ], [ -2.410185448561206, 51.641874854424785 ], [ -2.407394585181527, 51.641356847600129 ], [ -2.407218355729421, 51.641196471158871 ], [ -2.40696884010188, 51.641247673536412 ], [ -2.407017984283043, 51.641572984827448 ], [ -2.406423440042848, 51.641667719029925 ], [ -2.404784772133554, 51.641360484941366 ], [ -2.404189613743223, 51.642350666557547 ], [ -2.404133350591639, 51.642857015257384 ], [ -2.402739988819236, 51.64249587422519 ], [ -2.40213966232318, 51.643406962180762 ], [ -2.401774568172401, 51.643473830281707 ], [ -2.401870113986149, 51.643660558412428 ], [ -2.401252200271076, 51.644216557556625 ], [ -2.401360573671157, 51.644371691817348 ], [ -2.401101468791152, 51.644662104259076 ], [ -2.400309811577192, 51.645192624706787 ], [ -2.398994222125593, 51.645632248460743 ], [ -2.39883823645013, 51.645808148509765 ], [ -2.39823783468051, 51.645569199884619 ], [ -2.397216483839058, 51.644462195092103 ], [ -2.395836127315136, 51.643610054338495 ], [ -2.396567619806918, 51.64280462254554 ], [ -2.395870633034205, 51.642428460674012 ], [ -2.394785560819355, 51.64211831958842 ], [ -2.395216171975116, 51.641447030743755 ], [ -2.39683490544894, 51.640161214564074 ], [ -2.396601420334136, 51.640056745894711 ], [ -2.39714460555341, 51.639552349361871 ], [ -2.395785012918386, 51.638741395465118 ], [ -2.394617985762697, 51.638628472103107 ], [ -2.392942787410724, 51.638924518931631 ], [ -2.391529147624174, 51.639711442549626 ], [ -2.390166399390646, 51.640713999005079 ], [ -2.389992143500879, 51.640443028935401 ], [ -2.388443301714674, 51.64014425712557 ], [ -2.385990861304208, 51.639941114145991 ], [ -2.385367109343339, 51.639320065877278 ], [ -2.385477420969552, 51.63921992876007 ], [ -2.385352891079851, 51.638669149248088 ], [ -2.386118434254522, 51.637610098242241 ], [ -2.386328571379746, 51.637523114881354 ], [ -2.388267322510226, 51.637299998191644 ], [ -2.38818390966087, 51.637172634225898 ], [ -2.388323920130202, 51.636994104330412 ], [ -2.389993893129772, 51.636441062993597 ], [ -2.391352673781165, 51.636333978091066 ], [ -2.391598468970301, 51.636183945238805 ], [ -2.391550207885503, 51.635947612815599 ], [ -2.392637006803586, 51.636146317893932 ], [ -2.3929491548601, 51.635982487197445 ], [ -2.393333422007448, 51.6361403902524 ], [ -2.396317574048576, 51.636008912435116 ], [ -2.397000757656144, 51.635647862975382 ], [ -2.397293414640006, 51.635736849748511 ], [ -2.397444394777382, 51.635986225224457 ], [ -2.398351280001673, 51.635758432035772 ], [ -2.398341475060128, 51.635468938281115 ], [ -2.3987438795207, 51.63522119051914 ], [ -2.399361579502424, 51.635464572308869 ], [ -2.399875741601714, 51.635110373240401 ], [ -2.400477041985556, 51.635141581079957 ], [ -2.400293594219425, 51.634981218771735 ], [ -2.400554118312832, 51.634708780191801 ], [ -2.400459178907854, 51.634425869216678 ], [ -2.3996969885367, 51.634345771360408 ], [ -2.399254006446898, 51.633743056622933 ], [ -2.39873708379946, 51.633957937069709 ], [ -2.398355547764272, 51.633934963265503 ], [ -2.398176770435028, 51.633490447885507 ], [ -2.397748230263496, 51.633391227347019 ], [ -2.397683623676227, 51.63311450338913 ], [ -2.39750233180638, 51.633035117885377 ], [ -2.396664560866987, 51.633382311141908 ], [ -2.396453223838603, 51.633177093407127 ], [ -2.396571575200989, 51.632828739579175 ], [ -2.39593046375111, 51.632544972750082 ], [ -2.395308435948397, 51.632619069578297 ], [ -2.395321635746634, 51.632315115966584 ], [ -2.395011019792736, 51.631815309589193 ], [ -2.393658075827358, 51.631740755150616 ], [ -2.393645563608084, 51.631300169261998 ], [ -2.392971611922201, 51.630051735183386 ], [ -2.391289019700665, 51.628941585699565 ], [ -2.390661343015156, 51.628866373878019 ], [ -2.390433942075337, 51.628463356518239 ], [ -2.389702184479185, 51.628209609898583 ], [ -2.388912073244873, 51.627538704886135 ], [ -2.389548928621172, 51.627172458468699 ], [ -2.389331011418121, 51.627040148318713 ], [ -2.389167003881376, 51.626609951824463 ], [ -2.389581288840586, 51.62640363375651 ], [ -2.388973111399246, 51.62606938248387 ], [ -2.389435927468697, 51.625786409805514 ], [ -2.389167369887602, 51.625637098884589 ], [ -2.389400745400919, 51.625391830791891 ], [ -2.389293748229544, 51.62522041090434 ], [ -2.389511122128517, 51.624789937610537 ], [ -2.389300842731849, 51.624699759229109 ], [ -2.388936814567736, 51.624861954847852 ], [ -2.388833604418968, 51.624617713135308 ], [ -2.388443522997589, 51.624449117824078 ], [ -2.388758714377174, 51.624300568653574 ], [ -2.388535042175411, 51.623994703350647 ], [ -2.38872497471998, 51.623572412158275 ], [ -2.388618157293414, 51.623407283138171 ], [ -2.389108164861394, 51.623451501846603 ], [ -2.389537036124464, 51.623255023040379 ], [ -2.389424473100767, 51.623100700314247 ], [ -2.388962753627569, 51.62316065863822 ], [ -2.388887132672759, 51.622938887206359 ], [ -2.389627085761559, 51.622477826504593 ], [ -2.389210114695729, 51.622533142842393 ], [ -2.388852223565686, 51.622241206314001 ], [ -2.388858949370915, 51.622011072031924 ], [ -2.389371045938758, 51.621757598911273 ], [ -2.389286795957778, 51.621529474305525 ], [ -2.389581873188081, 51.621246158287022 ], [ -2.38924288641801, 51.621130429542823 ], [ -2.389412627133618, 51.620883484652325 ], [ -2.389240407174279, 51.620340056809084 ], [ -2.38947915489697, 51.620210725395552 ], [ -2.389404749160666, 51.619963691758223 ], [ -2.389543627652221, 51.619645837889173 ], [ -2.388933638253139, 51.619590333410251 ], [ -2.389149819646947, 51.619371100018675 ], [ -2.389193814893633, 51.61894569612781 ], [ -2.389752771311303, 51.618939346372315 ], [ -2.38958350522396, 51.618740268261433 ], [ -2.389930687909915, 51.618466665820016 ], [ -2.389303664012677, 51.618102815670156 ], [ -2.38957848242142, 51.617820465558587 ], [ -2.389359759350119, 51.617574899646741 ], [ -2.390020471563605, 51.617646413066055 ], [ -2.390165779736665, 51.617413031267382 ], [ -2.389877890635426, 51.617017494139283 ], [ -2.39073103831554, 51.616964319103957 ], [ -2.3903944979132, 51.616797259679601 ], [ -2.390427027486773, 51.616549870695238 ], [ -2.390005315270475, 51.616393071053949 ], [ -2.390452262721699, 51.616299000349088 ], [ -2.390500493571589, 51.616021896164888 ], [ -2.390863990892461, 51.61597304538784 ], [ -2.390903804327539, 51.615728328595807 ], [ -2.39159667099267, 51.615346602592815 ], [ -2.391587254700638, 51.615096656577109 ], [ -2.391237861668196, 51.614943125566768 ], [ -2.391699406194891, 51.614706978960804 ], [ -2.391251546947745, 51.614346945251448 ], [ -2.391767002242265, 51.613997270263724 ], [ -2.391522718995733, 51.61363125425698 ], [ -2.391842686206985, 51.613397287235671 ], [ -2.390773653738782, 51.613026830147618 ], [ -2.390769350997096, 51.612692372555045 ], [ -2.391010076638892, 51.612465862667634 ], [ -2.390502577569776, 51.612395642757271 ], [ -2.3902618495576, 51.612108713353457 ], [ -2.39057212115442, 51.61157815269781 ], [ -2.391196812036903, 51.611513959110781 ], [ -2.39127447477347, 51.611309655133354 ], [ -2.391809273852887, 51.611357308624939 ], [ -2.391671376756563, 51.611106892556698 ], [ -2.392161923971524, 51.61106300673098 ], [ -2.393189238764193, 51.610619927810291 ], [ -2.393343656454454, 51.610274061723075 ], [ -2.394166816620838, 51.609605950403427 ], [ -2.393842615518367, 51.609195263566434 ], [ -2.394453054031109, 51.608974695805173 ], [ -2.394239547403608, 51.608669705314995 ], [ -2.394624671051732, 51.608280005733079 ], [ -2.39455068131188, 51.60775243384068 ], [ -2.395188309191183, 51.607512085320408 ], [ -2.395176205089613, 51.607283721347002 ], [ -2.394791035490119, 51.607323669794418 ], [ -2.394462348676581, 51.606888729925359 ], [ -2.394714143375008, 51.606777231258086 ], [ -2.395040435291721, 51.606936223124748 ], [ -2.3954362113281, 51.606788282918686 ], [ -2.395066754953549, 51.606484718225801 ], [ -2.395239510040521, 51.60592314688008 ], [ -2.395430666582214, 51.605821738567222 ], [ -2.395151855376495, 51.605303036781528 ], [ -2.395430435372906, 51.605124030485641 ], [ -2.394806666942402, 51.604625276541604 ], [ -2.394961129360961, 51.604466554149127 ], [ -2.394910762902535, 51.60382114960511 ], [ -2.39388976218216, 51.60313136727251 ], [ -2.394492004353229, 51.603141928041197 ], [ -2.394494654634341, 51.602788570168428 ], [ -2.394711698901559, 51.602667300587015 ], [ -2.394568759626289, 51.602506882228099 ], [ -2.394835457611185, 51.602455647785888 ], [ -2.394974313634318, 51.602159359581805 ], [ -2.394908810851462, 51.601758500631817 ], [ -2.395169475835327, 51.601684813769566 ], [ -2.395299209723987, 51.601325634380842 ], [ -2.395662305129277, 51.601408904940818 ], [ -2.395783758830124, 51.601097393472784 ], [ -2.396361129161602, 51.600742994007184 ], [ -2.396489367707331, 51.600377526132952 ], [ -2.396024625264149, 51.599734420191275 ], [ -2.395176146546283, 51.599629415905213 ], [ -2.394491641576359, 51.599104797010959 ], [ -2.394457766323526, 51.59853394317679 ], [ -2.394845216326506, 51.597763918634442 ], [ -2.394659896384956, 51.597367956858342 ], [ -2.393102539542556, 51.597074668012063 ], [ -2.39187222975377, 51.597380897372794 ], [ -2.390031347404598, 51.597017503122039 ], [ -2.38914705290806, 51.597101338916993 ], [ -2.388881830740288, 51.596988060798068 ], [ -2.388451657033466, 51.59715676735059 ], [ -2.388091681703877, 51.596931351424445 ], [ -2.38802113715846, 51.597117742578675 ], [ -2.387744597848921, 51.597198657143345 ], [ -2.387456454384997, 51.597105137012839 ], [ -2.386829476637812, 51.597227745750374 ], [ -2.385901938416759, 51.596971833621062 ], [ -2.385479896754047, 51.597090075423203 ], [ -2.385159752313931, 51.596787216059489 ], [ -2.385001257079749, 51.596821983609125 ], [ -2.385042715816907, 51.596938701777319 ], [ -2.384295946990622, 51.596901599801505 ], [ -2.384038696703008, 51.596870981481317 ], [ -2.384034306863386, 51.596689332457913 ], [ -2.382717016952396, 51.596779030880413 ], [ -2.381490155301607, 51.596467430690197 ], [ -2.380002831470514, 51.596421920800339 ], [ -2.37872150399978, 51.596685031358746 ], [ -2.378192795005272, 51.59716152471141 ], [ -2.377111294652397, 51.597309725782829 ], [ -2.376848462589734, 51.597654031863648 ], [ -2.376303826251677, 51.597618926175386 ], [ -2.375760999761879, 51.597961430978124 ], [ -2.375379866428684, 51.597617391991477 ], [ -2.374416487760911, 51.597555751502142 ], [ -2.374052281423936, 51.597690846248405 ], [ -2.373575603134363, 51.597480229911831 ], [ -2.372452511940456, 51.597668969992583 ], [ -2.370579518754981, 51.597612879115061 ], [ -2.370085017920192, 51.597872508152719 ], [ -2.370081908244647, 51.598558541802461 ], [ -2.36908728992712, 51.599108372994699 ], [ -2.3687694409004, 51.599077012987536 ], [ -2.368327691854239, 51.599621413002097 ], [ -2.367784611302568, 51.59976612836784 ], [ -2.367484730022335, 51.600353316289244 ], [ -2.367616770615899, 51.600444588125242 ], [ -2.366764896776442, 51.600975075548277 ], [ -2.366674745445634, 51.601251312810057 ], [ -2.366818123788742, 51.601670820198635 ], [ -2.366583927395295, 51.60305528425426 ], [ -2.365584368367885, 51.603733640069031 ], [ -2.362235061807085, 51.602710051202592 ], [ -2.362737687543008, 51.602008991738927 ], [ -2.362946629323111, 51.601235041164877 ], [ -2.36212964995662, 51.601073071368383 ], [ -2.359860835755725, 51.601002749647343 ], [ -2.357542124563282, 51.601565435784728 ], [ -2.357247553257312, 51.600830871693638 ], [ -2.356832218454405, 51.600512944391241 ], [ -2.356053136412053, 51.600214996643345 ], [ -2.355099299434031, 51.600098337129118 ], [ -2.354818528619455, 51.598715364534591 ], [ -2.35405561730487, 51.59938841218586 ], [ -2.353514955201816, 51.598547614577114 ], [ -2.353613807025592, 51.598263181363308 ], [ -2.352788866954544, 51.596694876048069 ], [ -2.349904625588195, 51.597100908827848 ], [ -2.349868242911752, 51.597261107502106 ], [ -2.347195660021305, 51.59741196983763 ], [ -2.345059100372815, 51.596844610383059 ], [ -2.345049109247335, 51.596672954100988 ], [ -2.34402280017971, 51.596497900837761 ], [ -2.344037552384133, 51.595788463104952 ], [ -2.34429669032089, 51.595113364470805 ], [ -2.344314535932006, 51.594608861678402 ], [ -2.344115263405587, 51.59422823219488 ], [ -2.343369014902477, 51.595196083836761 ], [ -2.342962513309081, 51.594893362390899 ], [ -2.342628488533546, 51.594809843998121 ], [ -2.342588812256837, 51.595104881784586 ], [ -2.339482071923744, 51.594132968638625 ], [ -2.338259582013817, 51.595320592403759 ], [ -2.337909367354163, 51.595220028600217 ], [ -2.337931457014513, 51.595085133269585 ], [ -2.335256124339245, 51.594252988576166 ], [ -2.335051675655772, 51.596488812332296 ], [ -2.334179395572385, 51.596632424447279 ], [ -2.333296039577599, 51.595476014709135 ], [ -2.331273567574961, 51.595485339545633 ], [ -2.331147969992536, 51.595286053438343 ], [ -2.330823979034669, 51.593813257346248 ], [ -2.330379283497915, 51.593203992761737 ], [ -2.330983512920772, 51.592526153146117 ], [ -2.331182586832403, 51.592503119271633 ], [ -2.33106629059591, 51.591601602988419 ], [ -2.330869893967923, 51.591599460527128 ], [ -2.330373413863329, 51.592198793828707 ], [ -2.329198572492558, 51.59282519939525 ], [ -2.328890692303677, 51.592170601121879 ], [ -2.32859052730275, 51.591989868996016 ], [ -2.32840572750456, 51.59318256865317 ], [ -2.327798209332903, 51.593212133255228 ], [ -2.327310923786925, 51.592896999078967 ], [ -2.327057321054739, 51.592967908866527 ], [ -2.326753034049749, 51.59280956562678 ], [ -2.324993414278703, 51.593226320244383 ], [ -2.323828257358478, 51.593187205693233 ], [ -2.322653746951422, 51.593675117428489 ], [ -2.319850507144412, 51.593914795552415 ], [ -2.31969618718062, 51.593312788357309 ], [ -2.319387331259915, 51.592907157199214 ], [ -2.319671355260464, 51.592658293138456 ], [ -2.317740267454853, 51.591061290204486 ], [ -2.318736219914905, 51.590638632004989 ], [ -2.3186257463728, 51.590532864532413 ], [ -2.317593687050345, 51.590744293312966 ], [ -2.316574044385084, 51.589833519876983 ], [ -2.313474682241087, 51.590836273476988 ], [ -2.312767455693502, 51.591282297207471 ], [ -2.311590400205579, 51.591617205984541 ], [ -2.310646990339961, 51.592130450912116 ], [ -2.308257156208086, 51.592864128143525 ], [ -2.307878473810935, 51.592360762485875 ], [ -2.308613649065739, 51.591796851929601 ], [ -2.308152014569621, 51.591627189018617 ], [ -2.306909345050649, 51.591645728276589 ], [ -2.306106047123665, 51.591976007855123 ], [ -2.305802931344419, 51.59219261912196 ], [ -2.305601904189262, 51.592989818399445 ], [ -2.304005249977793, 51.592762866318026 ], [ -2.302325940070474, 51.592274442325646 ], [ -2.301791227391229, 51.591958425714481 ], [ -2.301340698953847, 51.592150236085338 ], [ -2.301085648930611, 51.592007879666852 ], [ -2.301016542774162, 51.591600775547882 ], [ -2.300102045147939, 51.591480871714879 ], [ -2.300027669551002, 51.591807444509811 ], [ -2.299625221680249, 51.592071934382211 ], [ -2.297889351902017, 51.592386558818518 ], [ -2.296874364696937, 51.593028414084174 ], [ -2.296441990161243, 51.59380092431843 ], [ -2.296553673503761, 51.594993811652152 ], [ -2.294394179523162, 51.594795116986688 ], [ -2.291587983519886, 51.593920059022842 ], [ -2.291764378266195, 51.593734451626041 ], [ -2.289858271973296, 51.593203267316802 ], [ -2.290233785258385, 51.59254957389976 ], [ -2.289304454686306, 51.592360319232469 ], [ -2.290331244197314, 51.591072926319889 ], [ -2.292704337652322, 51.589963834954474 ], [ -2.293727934123245, 51.58908999342578 ], [ -2.294089841053377, 51.588572950681503 ], [ -2.29303294290834, 51.58830143838437 ], [ -2.293428830291336, 51.587701615904258 ], [ -2.291877204621569, 51.5877027911705 ], [ -2.29211042041553, 51.587381221101722 ], [ -2.291009093131862, 51.586929845784105 ], [ -2.290531629323968, 51.58741300811068 ], [ -2.287675664391987, 51.586582024320592 ], [ -2.286384281357879, 51.585968374679744 ], [ -2.28601203938222, 51.585533237200195 ], [ -2.285346653900522, 51.585526768184813 ], [ -2.283507285098432, 51.584962958351561 ], [ -2.283793812678396, 51.584634084773363 ], [ -2.284127752054691, 51.584714175241992 ], [ -2.284597609998135, 51.584150158160426 ], [ -2.286555262651742, 51.584470874897384 ], [ -2.287281672071755, 51.583156375191187 ], [ -2.285759838510563, 51.583063913354557 ], [ -2.285288885859958, 51.582746767014832 ], [ -2.284936898298666, 51.583241197132686 ], [ -2.284415174067759, 51.583120216114786 ], [ -2.282076127265286, 51.582267166775893 ], [ -2.280892548735147, 51.581312432063825 ], [ -2.280720610350774, 51.581043090196005 ], [ -2.282053451394207, 51.580700924692906 ], [ -2.281281909951052, 51.579621156579726 ], [ -2.282749895048961, 51.57851613941174 ], [ -2.280245121959878, 51.577892756801255 ], [ -2.278673046776333, 51.577803019865954 ], [ -2.276753845168845, 51.579464649159718 ], [ -2.276808009278581, 51.579605735235454 ], [ -2.276565966776921, 51.579895835315611 ], [ -2.274333134411876, 51.579142156518394 ], [ -2.274477497435404, 51.578910806733688 ], [ -2.273225340857874, 51.578264470494133 ], [ -2.272563202100845, 51.577589874389645 ], [ -2.273955263721872, 51.574382124300143 ], [ -2.273996507596004, 51.572359008401627 ], [ -2.270349924106984, 51.5725454511499 ], [ -2.268903621049119, 51.572465181081263 ], [ -2.266433565310434, 51.571748839242481 ], [ -2.263426848293026, 51.571305114183176 ], [ -2.260352134931933, 51.570048695540571 ], [ -2.260303702711808, 51.569900487812191 ], [ -2.260523798506436, 51.569778560223121 ], [ -2.262255335826719, 51.569064404603388 ], [ -2.263999715508298, 51.568071451479355 ], [ -2.264437011891275, 51.567601969364183 ], [ -2.264606709171837, 51.567265315184649 ], [ -2.264441200282208, 51.566827843705831 ], [ -2.265112439583236, 51.566395673973801 ], [ -2.266471730014054, 51.564711145419487 ], [ -2.266478992558163, 51.56446834106994 ], [ -2.266065491128286, 51.56431916698012 ], [ -2.267410214176918, 51.562884638909964 ], [ -2.267289271367175, 51.561692727918803 ], [ -2.26795697486925, 51.559928855897233 ], [ -2.268377409206115, 51.560049243311134 ], [ -2.268627903245282, 51.55970880232546 ], [ -2.267902383153833, 51.559483944132083 ], [ -2.268106063017239, 51.558787474061333 ], [ -2.267689812551514, 51.558162623368354 ], [ -2.268286501011684, 51.556609338891363 ], [ -2.268408298998787, 51.555744155229206 ], [ -2.267804466758534, 51.553874421591487 ], [ -2.267386641570556, 51.55394548817133 ], [ -2.267033957684896, 51.553322287446889 ], [ -2.267397889944657, 51.552660599059756 ], [ -2.267125552464626, 51.552475061210153 ], [ -2.267558174349296, 51.552212409747277 ], [ -2.266893577124978, 51.551769786433432 ], [ -2.267044577208774, 51.551684947537417 ], [ -2.26684510117187, 51.55161438997235 ], [ -2.266813256735744, 51.551354595279527 ], [ -2.267692924790479, 51.550596359286608 ], [ -2.268372648624755, 51.549692056437912 ], [ -2.264249113762942, 51.545652671026268 ], [ -2.263455945153186, 51.545159890200573 ], [ -2.261725960740881, 51.544741199990206 ], [ -2.26164709660967, 51.543554489106008 ], [ -2.262041935571962, 51.542747038041149 ], [ -2.262217355586714, 51.541661422283916 ], [ -2.262486058567417, 51.541498931751121 ], [ -2.262917235129565, 51.540504427985766 ], [ -2.263820495942986, 51.539369533707664 ], [ -2.264819446205273, 51.53758605004289 ], [ -2.266505833947524, 51.536262304463165 ], [ -2.265663254636472, 51.535426185961292 ], [ -2.264072822376485, 51.53539831878453 ], [ -2.263911714615679, 51.534960834357108 ], [ -2.263247130351492, 51.53471774195657 ], [ -2.263466352826799, 51.534475359219968 ], [ -2.263366382546683, 51.534392886379756 ], [ -2.261866181583959, 51.534505012742287 ], [ -2.260261260789144, 51.533952896041527 ], [ -2.260543347278885, 51.532082945866605 ], [ -2.260106145326577, 51.532016500422372 ], [ -2.260101260977379, 51.53143115652275 ], [ -2.260327047202351, 51.531068314177368 ], [ -2.259892490587377, 51.53046324931627 ], [ -2.260010220886866, 51.530369504016591 ], [ -2.259178452207264, 51.529868688884804 ], [ -2.258532336822606, 51.529050151486786 ], [ -2.257668117951575, 51.528415463018021 ], [ -2.255582616825308, 51.528738325055549 ], [ -2.254948892003327, 51.52856972579908 ], [ -2.253726135775975, 51.528764830840494 ], [ -2.252112431428694, 51.528138912678081 ], [ -2.252338235699779, 51.527792265462587 ], [ -2.252392342312548, 51.526874115846013 ], [ -2.25335726468908, 51.526720931049276 ], [ -2.253452895792945, 51.526285573103202 ], [ -2.253847693389477, 51.526005074924093 ], [ -2.254929684979947, 51.525665553904531 ], [ -2.254822567747257, 51.525318726522393 ], [ -2.254927141243429, 51.524423836638306 ], [ -2.254753507797949, 51.524040299402429 ], [ -2.25578802274791, 51.522958122763207 ], [ -2.25608166228582, 51.522363137049197 ], [ -2.255813394285843, 51.522078685630547 ], [ -2.260063186419594, 51.520440997151709 ], [ -2.262694592408256, 51.51963044397958 ], [ -2.263605912520164, 51.519220122759926 ], [ -2.263723183242187, 51.518559895144307 ], [ -2.267522325591904, 51.518574655869735 ], [ -2.271558441491479, 51.518214717231508 ], [ -2.275118236044667, 51.5175194844659 ], [ -2.279858696975647, 51.516169456014531 ], [ -2.28171764458475, 51.515453801463316 ], [ -2.286935844558597, 51.512937016514805 ], [ -2.291804971738683, 51.511120383694788 ], [ -2.296388488968322, 51.509746704272338 ], [ -2.296145602997476, 51.509629473722804 ], [ -2.296640630933542, 51.509076123414665 ], [ -2.296272893382791, 51.50881367869399 ], [ -2.297120656649234, 51.508008553723734 ], [ -2.296733816276589, 51.507456536277289 ], [ -2.296831239548753, 51.507366400514456 ], [ -2.296288470614796, 51.506766236258933 ], [ -2.297456226619446, 51.506215674042025 ], [ -2.299267223540902, 51.505537614663659 ], [ -2.306027043814682, 51.503970021057647 ], [ -2.306047524264091, 51.503800077113105 ], [ -2.308628707607018, 51.503501078869711 ], [ -2.311891892806919, 51.502864834409877 ], [ -2.315503173371846, 51.501321209815991 ], [ -2.319568160746804, 51.499180091802806 ], [ -2.32164335515492, 51.498256376226315 ], [ -2.324327612026502, 51.497510808267791 ], [ -2.319216187548819, 51.494571079854239 ], [ -2.317033425415605, 51.492437998715353 ], [ -2.313648119078655, 51.490477902014305 ], [ -2.313108413162778, 51.489288041489523 ], [ -2.311699042396277, 51.488119281523318 ], [ -2.311426066543476, 51.487374554528579 ], [ -2.310427625140803, 51.48815861212455 ], [ -2.309718863140244, 51.488148801856973 ], [ -2.308431340751925, 51.487509308731454 ], [ -2.306433849121015, 51.487096383611508 ], [ -2.306194554376773, 51.486845318802132 ], [ -2.30557792105783, 51.486811871525298 ], [ -2.304405494989342, 51.486359003919837 ], [ -2.304334262266213, 51.486271996216821 ], [ -2.304562518370548, 51.486151760401732 ], [ -2.30423488534722, 51.486042047497335 ], [ -2.304227737321248, 51.485842421679749 ], [ -2.303476154822628, 51.485869629426759 ], [ -2.3035853205518, 51.486036540959823 ], [ -2.302877021891276, 51.486091408546201 ], [ -2.302015238305951, 51.486441594645569 ], [ -2.301784313192037, 51.486356794651904 ], [ -2.301620187502669, 51.486587423953893 ], [ -2.30092878442126, 51.486793250445352 ], [ -2.300936771623596, 51.487122404866476 ], [ -2.300514345882352, 51.48727809866444 ], [ -2.299657210355987, 51.48725692239428 ], [ -2.29746756848404, 51.487829882938627 ], [ -2.297229195906795, 51.487713541734792 ], [ -2.295583519470492, 51.487795099113512 ], [ -2.294879289754339, 51.487584644574362 ], [ -2.293695399531571, 51.486905177677656 ], [ -2.29302422309459, 51.487123491337798 ], [ -2.292322791100819, 51.486901418719519 ], [ -2.291957748953834, 51.487010196043109 ], [ -2.291879126891313, 51.487324195684273 ], [ -2.291323443060973, 51.48736962427833 ], [ -2.291243824414293, 51.487081187442023 ], [ -2.290561163219666, 51.486859057639911 ], [ -2.290469127473108, 51.486652450375871 ], [ -2.2913403346894, 51.486629613003295 ], [ -2.290589110129043, 51.485353790659801 ], [ -2.290797294287423, 51.485265182596528 ], [ -2.29025211938896, 51.483541017227367 ], [ -2.290565632485446, 51.48347372204951 ], [ -2.29006778699791, 51.482186480420694 ], [ -2.289636073019261, 51.47883458139934 ], [ -2.288854223607366, 51.478151373711455 ], [ -2.290343425647054, 51.477076749383855 ], [ -2.291248236263149, 51.475574786851617 ], [ -2.291618977682161, 51.47296895501804 ], [ -2.291797137319134, 51.472928061144458 ], [ -2.292480342423038, 51.471003978652284 ], [ -2.292928732892267, 51.470214346700118 ], [ -2.29340384179224, 51.468652224258513 ], [ -2.29282324276102, 51.467459582496666 ], [ -2.294008002667127, 51.46722910467269 ], [ -2.294583910151932, 51.466787108741549 ], [ -2.294596668007473, 51.463849481012907 ], [ -2.295324494159185, 51.460439029015603 ], [ -2.295327787124616, 51.460269039130317 ], [ -2.295147423366591, 51.460199379619574 ], [ -2.295745836664805, 51.458591989233611 ], [ -2.293338497987202, 51.457786066917286 ], [ -2.289247209297006, 51.457653314873745 ], [ -2.287756899247483, 51.456871977186069 ], [ -2.286595464507621, 51.457113122192055 ], [ -2.285318593775271, 51.457988439808332 ], [ -2.285127718322855, 51.457846788746693 ], [ -2.28569081020863, 51.457448014054222 ], [ -2.287516533446205, 51.455503185593976 ], [ -2.288043189245482, 51.454564969894925 ], [ -2.288947326232272, 51.446422671186717 ], [ -2.290062603686001, 51.442576936718247 ], [ -2.294618432523423, 51.428803922025075 ], [ -2.297339474403669, 51.428966938562731 ], [ -2.298821308338191, 51.428800466006457 ], [ -2.299365317197626, 51.428185845329715 ], [ -2.301655894101443, 51.426323194288869 ], [ -2.301468951642616, 51.425902000097537 ], [ -2.303632600748276, 51.425099713067979 ], [ -2.303745377343799, 51.425189310998178 ], [ -2.30765264888681, 51.424692716342257 ], [ -2.308281915245369, 51.424366467685665 ], [ -2.30986819715063, 51.423085478885483 ], [ -2.312618000535081, 51.422448759188789 ], [ -2.313786503628844, 51.42317931996682 ], [ -2.313858415691777, 51.424017175355431 ], [ -2.313625244056836, 51.424409811864052 ], [ -2.313813048547551, 51.424526166327297 ], [ -2.313753731237151, 51.42490314566033 ], [ -2.313353675670733, 51.425291733959668 ], [ -2.313248042326039, 51.425607621551649 ], [ -2.313423871742777, 51.425879608840972 ], [ -2.313162514203234, 51.426574441144986 ], [ -2.313813658855941, 51.426933248557305 ], [ -2.313734524184037, 51.427135803684905 ], [ -2.314156354855844, 51.427395355009239 ], [ -2.314235597608735, 51.42764063292644 ], [ -2.314198244527835, 51.427848469665093 ], [ -2.313775000133464, 51.428213749903406 ], [ -2.3140211537505, 51.428656339369475 ], [ -2.313851662994252, 51.428913070898311 ], [ -2.315035265284715, 51.429501551473464 ], [ -2.316027523673754, 51.429684142455351 ], [ -2.317685798616933, 51.430271314615368 ], [ -2.317671591158113, 51.430496977771163 ], [ -2.317935134244953, 51.430550286805826 ], [ -2.31815268362895, 51.431016316579488 ], [ -2.318890992904203, 51.431274181727929 ], [ -2.32016262329909, 51.432102467649727 ], [ -2.321072772882244, 51.432455132915074 ], [ -2.321105467736228, 51.432601564421908 ], [ -2.321503676683643, 51.432558223730076 ], [ -2.322151120825305, 51.432791148406835 ], [ -2.322221035325296, 51.433119145440273 ], [ -2.322657028875526, 51.433337277536943 ], [ -2.323489365648337, 51.434471554198595 ], [ -2.324158535513619, 51.434718790188896 ], [ -2.324313453149454, 51.435256084750073 ], [ -2.324609585775717, 51.435434146064239 ], [ -2.324395817878863, 51.435513841634169 ], [ -2.324714439634884, 51.435818675497195 ], [ -2.325030701332412, 51.43699302301146 ], [ -2.326250558786503, 51.437176693511709 ], [ -2.326846062731041, 51.436967297236585 ], [ -2.327347839615824, 51.437120597185711 ], [ -2.328617552503092, 51.437043242363366 ], [ -2.328841536357162, 51.437180235729308 ], [ -2.329421040092333, 51.437139055857536 ], [ -2.329668646180636, 51.437360388116765 ], [ -2.330742727450224, 51.437475206586534 ], [ -2.330803193366376, 51.437684480028942 ], [ -2.331624328634414, 51.437643505593499 ], [ -2.331855670807563, 51.437795753702829 ], [ -2.332529868696965, 51.437530373678825 ], [ -2.332722084406294, 51.437652078581088 ], [ -2.333705945284229, 51.437429947949255 ], [ -2.335843181848731, 51.437540697558646 ], [ -2.336073688612981, 51.437383537636435 ], [ -2.338011617474452, 51.437987597491812 ], [ -2.33939979052212, 51.438159858630662 ], [ -2.342039017868961, 51.439405611677898 ], [ -2.342899262839726, 51.439388714467555 ], [ -2.343291703621747, 51.439535883968119 ], [ -2.343536547319605, 51.43918899906776 ], [ -2.34695150888321, 51.438555816183964 ], [ -2.347898691839339, 51.438617818049394 ], [ -2.350634634296108, 51.438379452428102 ], [ -2.351795628689918, 51.438741914956324 ], [ -2.35276755994155, 51.437919822582714 ], [ -2.353839267383765, 51.43735019208227 ], [ -2.354994777733106, 51.437204579829782 ], [ -2.355834931674494, 51.436821705257451 ], [ -2.356524142531584, 51.436280088404736 ], [ -2.357671508052502, 51.435840533260972 ], [ -2.358836478820275, 51.435788429959302 ], [ -2.360357288058508, 51.436188358014064 ], [ -2.361044927361707, 51.436553083083801 ], [ -2.361476070437141, 51.437405980881572 ], [ -2.364180388390411, 51.437176385540653 ], [ -2.364276926132984, 51.437382922938156 ], [ -2.36722065016053, 51.437056330187268 ], [ -2.369666568027833, 51.435827568030703 ], [ -2.370226754741977, 51.435897711328067 ], [ -2.371266402933215, 51.435488027109727 ], [ -2.371855449984981, 51.435037426392661 ], [ -2.373232868672892, 51.434424308871563 ], [ -2.375900285316555, 51.433759401141259 ], [ -2.377254988300567, 51.432833400613525 ], [ -2.379076928304628, 51.433453336222485 ], [ -2.38034100438552, 51.43410471976263 ], [ -2.383990014942615, 51.432662300885518 ], [ -2.384393361877749, 51.432729294855321 ], [ -2.385120311831114, 51.432280062224542 ], [ -2.38604284866309, 51.431988387823431 ], [ -2.388547975205006, 51.431901901513179 ], [ -2.391710134132683, 51.432117895219172 ], [ -2.393449335251461, 51.431951163373967 ], [ -2.396699500306869, 51.43202739676655 ], [ -2.397189015337444, 51.431252500618271 ], [ -2.397859144740923, 51.431392253674908 ], [ -2.399070319200484, 51.432059795665936 ], [ -2.401193261949073, 51.431700084573222 ], [ -2.403099850684236, 51.431597357282243 ], [ -2.403052615249566, 51.430812506385088 ], [ -2.404167412408649, 51.429664989238177 ], [ -2.405773698842572, 51.428647809061204 ], [ -2.409903011606075, 51.426535748523541 ], [ -2.411197695208569, 51.42607798323381 ], [ -2.413455334762511, 51.425862390099262 ], [ -2.414764171657084, 51.426331576833917 ], [ -2.416364089422934, 51.426074118140789 ], [ -2.417965077067512, 51.425312257679181 ], [ -2.420874394222553, 51.424335248346921 ], [ -2.424037132725166, 51.423718699723729 ], [ -2.427634457690852, 51.424214584649377 ], [ -2.430146729968987, 51.424172037973541 ], [ -2.431383616667874, 51.423725138169893 ], [ -2.435090830826496, 51.423359866425791 ], [ -2.435721843024884, 51.42347617692289 ], [ -2.436319064431456, 51.423206889024343 ], [ -2.437427288660864, 51.423290040236189 ], [ -2.438444417078307, 51.423171987039417 ], [ -2.439482301107175, 51.4228201313732 ], [ -2.44129840834571, 51.422493203738227 ], [ -2.442796687683437, 51.422753716751579 ], [ -2.444007287936907, 51.422571960342729 ], [ -2.444456702443487, 51.422351821819149 ], [ -2.444106095161139, 51.421046679781007 ], [ -2.44364522338434, 51.420535869035383 ], [ -2.441524990976041, 51.419293139309097 ], [ -2.443800295124112, 51.418281990296869 ], [ -2.44435714745618, 51.418605373908626 ], [ -2.445874727816165, 51.418947574983633 ], [ -2.446026152468695, 51.418254659879885 ], [ -2.446544496417276, 51.418019778247455 ], [ -2.450059766241879, 51.417365225176049 ], [ -2.452090632100411, 51.417539973756526 ], [ -2.454463124556206, 51.418385835459688 ], [ -2.455656484658474, 51.418513429382671 ], [ -2.457034839203075, 51.418143912609757 ], [ -2.457677771659074, 51.417722331676913 ], [ -2.458219444054347, 51.416957760334071 ], [ -2.458542680669806, 51.416782916405666 ], [ -2.460934245287635, 51.41666476321992 ], [ -2.464308721615182, 51.417321304225936 ], [ -2.465537090988903, 51.416927112153438 ], [ -2.467470971667353, 51.416610096935138 ], [ -2.469452417694516, 51.415904440709426 ], [ -2.470836795374536, 51.416566055073154 ], [ -2.472181409801494, 51.416989512664486 ], [ -2.473501225700361, 51.418074022536963 ], [ -2.474013144483518, 51.418205889767655 ], [ -2.47532494317067, 51.41809899814308 ], [ -2.47636017590216, 51.418499392112068 ], [ -2.478114220578245, 51.419844564829901 ], [ -2.479930061286118, 51.420751599804127 ], [ -2.48044065317562, 51.421441846211188 ], [ -2.481126745505313, 51.421589238244962 ], [ -2.48326889089541, 51.421391561027654 ], [ -2.484863965953019, 51.420717800812866 ], [ -2.486422898022738, 51.420586390447717 ], [ -2.487126831816338, 51.420114055652206 ], [ -2.488849203028705, 51.418445248716353 ], [ -2.49000859438625, 51.417671568409226 ], [ -2.492314344060039, 51.417989194639645 ], [ -2.492896217238615, 51.418347390364779 ], [ -2.492476915752655, 51.419732934076784 ], [ -2.49269734113127, 51.420846114794635 ], [ -2.492603803226562, 51.421376954089432 ], [ -2.490318457833817, 51.424044522614977 ], [ -2.488642676662168, 51.42523754288014 ], [ -2.488419221882386, 51.426267993688157 ], [ -2.488562059597947, 51.426717840785081 ], [ -2.490469800540346, 51.427977689444113 ], [ -2.491510027084896, 51.428942622210648 ], [ -2.493950565972149, 51.429432331120907 ], [ -2.496138756782668, 51.428672318239286 ], [ -2.496943341914825, 51.428587916916577 ], [ -2.49763657710615, 51.428843050996868 ], [ -2.497985652841876, 51.428803813751017 ], [ -2.502492411631867, 51.427128334687595 ], [ -2.503974808213247, 51.426029434806466 ], [ -2.505721143200838, 51.425664054718261 ], [ -2.507297873076301, 51.424785027606255 ], [ -2.508181153282117, 51.424672431922787 ], [ -2.508468213531788, 51.425011063805762 ], [ -2.50807417306847, 51.426445183679157 ], [ -2.508156085394993, 51.427468055636957 ], [ -2.508287437924941, 51.427901748376897 ], [ -2.508997829326568, 51.428532574389408 ], [ -2.509579648242662, 51.428734187427395 ], [ -2.510461966465064, 51.428784281274602 ], [ -2.510419161188802, 51.428944563262625 ], [ -2.510856616284203, 51.429089178766858 ], [ -2.510419822352514, 51.429131533233289 ], [ -2.510700442208358, 51.429271528873905 ], [ -2.511884653746007, 51.429305014351328 ], [ -2.51360473910797, 51.429670623776509 ], [ -2.516990751823846, 51.43081838008483 ], [ -2.519901695673812, 51.431277516618991 ], [ -2.521795980150971, 51.431763675342047 ], [ -2.523541877569515, 51.432608231899067 ], [ -2.525354513632164, 51.434126014755655 ], [ -2.527097373490651, 51.436444380532748 ], [ -2.526800511356212, 51.439394939807954 ], [ -2.526892505258131, 51.440894352121603 ], [ -2.526448412196593, 51.442558875658335 ], [ -2.526574087917753, 51.443604098574191 ], [ -2.527418159918259, 51.444426577209434 ], [ -2.528576453970668, 51.445057064718974 ], [ -2.531054825778265, 51.44560066445834 ], [ -2.537211507978284, 51.444579940266195 ], [ -2.538618795127773, 51.445075160126166 ], [ -2.539327182876971, 51.445719294421117 ], [ -2.539118504967807, 51.446334387376638 ], [ -2.538127393846533, 51.446850600122666 ], [ -2.535606413392633, 51.447342344892412 ], [ -2.535036698232074, 51.446612968237154 ], [ -2.534768089241134, 51.446531494944679 ], [ -2.531666127259257, 51.446444032853691 ], [ -2.530480785888674, 51.447468134597301 ], [ -2.530457914435372, 51.44785935200666 ], [ -2.529931314909733, 51.448233971319823 ], [ -2.528952334961618, 51.448570180245696 ], [ -2.527229495940143, 51.448666126527861 ], [ -2.52612412554339, 51.449146705180567 ], [ -2.525511320983162, 51.449158443829916 ], [ -2.525582484141521, 51.448970253474194 ], [ -2.525129291664243, 51.448974082934328 ], [ -2.524211391187317, 51.449374699611788 ], [ -2.522362457929481, 51.449767776975627 ], [ -2.521770528436976, 51.450102199824691 ], [ -2.518936662239174, 51.452612659558362 ], [ -2.519176744023299, 51.453734687510511 ], [ -2.518661596062758, 51.45411819388341 ], [ -2.51835197701242, 51.455372096932535 ], [ -2.519183009566746, 51.457067796432831 ], [ -2.51921463484984, 51.457574817897644 ], [ -2.518602506948954, 51.458169186665678 ], [ -2.518463064536292, 51.459079763794421 ], [ -2.51671161329898, 51.459610750537649 ], [ -2.516228146123298, 51.460001387133246 ], [ -2.515362342221042, 51.459933195405426 ], [ -2.515184052731389, 51.460467208715613 ], [ -2.514258014197855, 51.461438765222773 ], [ -2.513033576690709, 51.461617709680489 ], [ -2.513289884153927, 51.462142535578245 ], [ -2.512749526300702, 51.46221690300343 ], [ -2.512683754841838, 51.462384386675645 ], [ -2.512245618129016, 51.462335064982327 ], [ -2.512148694390968, 51.463059285128431 ], [ -2.511660075590919, 51.463908455303162 ], [ -2.511346460297257, 51.465209996624935 ], [ -2.512248781988785, 51.465319318116848 ], [ -2.513251658419395, 51.465662985685391 ], [ -2.512899157060823, 51.466193173288431 ], [ -2.512875186520338, 51.467262432510502 ], [ -2.512589751852669, 51.467476720994071 ], [ -2.512284196013724, 51.468607437423287 ], [ -2.512639243655309, 51.468683190616758 ], [ -2.512451654371601, 51.468901635099172 ], [ -2.512922685086454, 51.469052388035543 ], [ -2.512929661644513, 51.469293353095651 ], [ -2.51261668824106, 51.470398034347717 ], [ -2.511507680255672, 51.470231998206195 ], [ -2.510834800222967, 51.471596229280891 ], [ -2.51118470181449, 51.473407428149535 ], [ -2.511181894874503, 51.474186158420139 ], [ -2.512851834740658, 51.477497605540336 ], [ -2.513758411219981, 51.478861312622648 ], [ -2.514339460143644, 51.479431453888999 ], [ -2.514469956460948, 51.480023436287802 ], [ -2.515264422088594, 51.481523357205255 ], [ -2.515045831438118, 51.481544093669136 ], [ -2.515127454913194, 51.481759560894538 ], [ -2.516711062657161, 51.485156814385789 ], [ -2.511392682866152, 51.489291071947093 ], [ -2.510998616176547, 51.489987818835097 ], [ -2.515965292699978, 51.49257448753584 ], [ -2.515318360688447, 51.493076401452541 ], [ -2.515864591612921, 51.493868804894959 ], [ -2.516144889888083, 51.493554664664181 ], [ -2.517471141250464, 51.493272856152323 ], [ -2.518036885273835, 51.492986215747784 ], [ -2.520685565301794, 51.492583280791386 ], [ -2.523339917816512, 51.492441120983557 ], [ -2.525329534189247, 51.493227028244597 ], [ -2.527472072823452, 51.492655506097186 ], [ -2.527702526012364, 51.492907059506628 ], [ -2.527852809918305, 51.493569140908868 ], [ -2.527972134880103, 51.493556018990695 ], [ -2.527937832217857, 51.493824944152962 ], [ -2.528554516201714, 51.494086531457974 ], [ -2.528100079266846, 51.494401486025005 ], [ -2.528133876379425, 51.494828490322085 ], [ -2.527753258136073, 51.49492368981862 ], [ -2.529295364362595, 51.495992089642954 ], [ -2.529228473366476, 51.496184845746058 ], [ -2.529477550058349, 51.496298780059135 ], [ -2.529665962456461, 51.496148711852527 ], [ -2.530276857790714, 51.496409417320955 ], [ -2.531740755697126, 51.495698679600174 ], [ -2.53280061209391, 51.496285522541712 ], [ -2.534328646652024, 51.496746175029529 ], [ -2.537703385892039, 51.497074214406524 ], [ -2.537676347706461, 51.496855816209795 ], [ -2.538375688499714, 51.495576710156051 ], [ -2.538950900571979, 51.495003985647195 ], [ -2.541742620519305, 51.49574196846558 ], [ -2.542536588950806, 51.494551390819929 ], [ -2.542160504042497, 51.492954438697545 ], [ -2.543865349930368, 51.492665995532384 ], [ -2.545049146070618, 51.492644317505686 ], [ -2.545559350816182, 51.492793858290661 ], [ -2.551850262783649, 51.492250153506568 ], [ -2.555347027951369, 51.492687675301788 ], [ -2.556154598390171, 51.49406230949171 ], [ -2.554661223755787, 51.496349622171287 ], [ -2.556824647167915, 51.496564181506287 ], [ -2.560075855413039, 51.49644343358829 ], [ -2.560511518675352, 51.495911809920038 ], [ -2.5612237341189, 51.495608080366615 ], [ -2.56158974440823, 51.495856221707228 ], [ -2.562239740609839, 51.495293900944816 ], [ -2.564787832640362, 51.495517164906069 ], [ -2.564719116031625, 51.49613611856315 ], [ -2.565337700386616, 51.496186172360431 ], [ -2.565063980529813, 51.497582134299947 ], [ -2.565971636575172, 51.498289864073463 ], [ -2.567765482879168, 51.498889026255583 ], [ -2.569086105722617, 51.4995506852311 ], [ -2.569926486249777, 51.49924717973763 ], [ -2.57309445728215, 51.500403362180528 ], [ -2.57547593025771, 51.500753144451373 ], [ -2.577194691972206, 51.500750987782475 ], [ -2.578116463272656, 51.500958676332253 ], [ -2.579832019799019, 51.500712805243843 ], [ -2.58122008711461, 51.501223878060308 ], [ -2.581713820262912, 51.501191765734482 ], [ -2.582495537417829, 51.501601468145026 ], [ -2.582412847788992, 51.501777254174989 ], [ -2.584517162202276, 51.502642489736225 ], [ -2.585626402104035, 51.501845743350223 ], [ -2.585243045927762, 51.501157123061944 ], [ -2.588148450865404, 51.5012360698394 ], [ -2.587761271283397, 51.502606495880372 ], [ -2.587674642313055, 51.503379354223007 ], [ -2.587847335315288, 51.50381094887954 ], [ -2.587712718651984, 51.504436538353943 ], [ -2.58787508687405, 51.5049608611331 ], [ -2.588319705027256, 51.505133916291669 ], [ -2.588510598355956, 51.505529552476681 ], [ -2.588535841258577, 51.506483427055812 ], [ -2.588389922035093, 51.507347281887014 ], [ -2.588018865780922, 51.507731355004374 ], [ -2.588544322950741, 51.507694470597357 ], [ -2.589627626832567, 51.508233940201421 ], [ -2.590501514863232, 51.508406715278355 ], [ -2.591221241854905, 51.509683479299852 ], [ -2.590266761739933, 51.51075015662127 ], [ -2.589226405269918, 51.511536801316517 ], [ -2.585850346680231, 51.512672216557 ], [ -2.58510429895361, 51.512476386429633 ], [ -2.584146139907678, 51.512825531418009 ], [ -2.582974053247217, 51.513012941999385 ], [ -2.582540818911891, 51.513391912987785 ], [ -2.582384899449814, 51.514162323448495 ], [ -2.581400022479722, 51.515580636884849 ], [ -2.580986634999152, 51.517409783729477 ], [ -2.585022533700172, 51.517342076062555 ], [ -2.587987700546971, 51.517063778295423 ], [ -2.594265366994196, 51.515840822820017 ], [ -2.594118496179937, 51.515739901758174 ], [ -2.59449754245414, 51.51552125642678 ], [ -2.594662638434277, 51.515689501908327 ], [ -2.595422922016071, 51.515311612481483 ], [ -2.598882276411231, 51.514705037511504 ], [ -2.601700744778099, 51.513917376602805 ], [ -2.606324272607675, 51.513523034263109 ], [ -2.609743672512172, 51.513397435331932 ], [ -2.612446284179514, 51.513549736658661 ], [ -2.621091826402241, 51.514867351906723 ], [ -2.622724208687345, 51.514521517377617 ], [ -2.626128036050305, 51.514730902792444 ], [ -2.627509379646895, 51.514571514959634 ], [ -2.634750917268544, 51.512716222769569 ], [ -2.638773649366454, 51.512047889060142 ], [ -2.638942241281022, 51.512149534984587 ], [ -2.645087403488808, 51.511992649781718 ], [ -2.648479568149587, 51.512298531898864 ], [ -2.652537444555164, 51.513099682654421 ], [ -2.654483106980029, 51.513725440268821 ], [ -2.65395502695915, 51.514484541243426 ], [ -2.65438993439304, 51.514561218206538 ], [ -2.654490757962858, 51.514963542475684 ], [ -2.654109036699217, 51.515472741834152 ], [ -2.653201281379614, 51.516090132444795 ], [ -2.653728536182441, 51.517586109371457 ], [ -2.653823702797999, 51.51819071791968 ], [ -2.653685643649464, 51.518714826819505 ], [ -2.652756280580995, 51.51923875854358 ], [ -2.65271461572452, 51.519649068271576 ], [ -2.652264449754476, 51.51991315271129 ], [ -2.651662232979636, 51.519931872008051 ], [ -2.651476268438206, 51.520232238664335 ], [ -2.651671514267032, 51.520581904204199 ], [ -2.651399366259446, 51.520705666512136 ], [ -2.652666307491629, 51.521813616249268 ], [ -2.652599796176256, 51.52189938179135 ], [ -2.653650670722635, 51.523118188639678 ], [ -2.657408607752302, 51.525943005169488 ], [ -2.658090906219495, 51.526774434702013 ], [ -2.660125923298637, 51.527648681882219 ], [ -2.663365496972627, 51.52965894555507 ], [ -2.663494231679165, 51.529594305654562 ], [ -2.665420031175603, 51.530967248167606 ], [ -2.664609444562704, 51.531533835477084 ], [ -2.66572338504938, 51.533681006819137 ], [ -2.663733938541788, 51.534870107927546 ], [ -2.664472870768095, 51.536014175075593 ], [ -2.663684061990169, 51.536997810005971 ], [ -2.673808750932124, 51.544432744190644 ], [ -2.67755183351855, 51.5405250712315 ], [ -2.67831306032973, 51.539541412780807 ], [ -2.679758251112324, 51.538219397245342 ], [ -2.680647464494658, 51.537222486551883 ], [ -2.680592295631178, 51.537102354420668 ], [ -2.68104734902308, 51.536775120950985 ], [ -2.68099146712508, 51.536607261667989 ], [ -2.681362104383632, 51.536223886490319 ], [ -2.681257585224592, 51.536078782312018 ], [ -2.681537674409133, 51.535722000496889 ], [ -2.680858999229015, 51.53555335394082 ], [ -2.680424258342531, 51.535018156181742 ], [ -2.681188033239811, 51.535576612495873 ], [ -2.682039010220572, 51.535693018109825 ], [ -2.682768288262449, 51.534905654921999 ], [ -2.682992959830558, 51.534889964399397 ], [ -2.682927239049214, 51.534740141232767 ], [ -2.683105318327449, 51.534502604058417 ], [ -2.684524867045481, 51.533218431126087 ], [ -2.684481098198971, 51.533082054021037 ], [ -2.685012683054738, 51.532481003082218 ], [ -2.685843601761002, 51.531938425756593 ], [ -2.685850677643139, 51.53173703107538 ], [ -2.686224603789832, 51.531395869056247 ], [ -2.686864701013342, 51.530339151857532 ], [ -2.686866385639578, 51.530072079110106 ], [ -2.687152372158209, 51.529914894290592 ], [ -2.687028148280427, 51.529416553321042 ], [ -2.687320660746971, 51.529314162680024 ], [ -2.687978154292548, 51.529422669903397 ], [ -2.692735438886793, 51.524677689989183 ], [ -2.694416281310978, 51.523272296475277 ], [ -2.694674933480761, 51.523213234982549 ], [ -2.694587507768936, 51.523153526502455 ], [ -2.695209631143482, 51.52245831598561 ], [ -2.701622615132472, 51.522668309659231 ], [ -2.698994770384039, 51.524915702429425 ], [ -2.698822850881668, 51.525268286892242 ], [ -2.69911949252715, 51.525431107497099 ], [ -2.7005273645545, 51.525222161511344 ], [ -2.700863092427152, 51.525399126641567 ], [ -2.702055146125604, 51.525206733196683 ], [ -2.702355306762784, 51.525419862998895 ], [ -2.70229189955465, 51.525794275149217 ], [ -2.70209557852241, 51.526058019404793 ], [ -2.701320784540003, 51.526381854788085 ], [ -2.699427489996249, 51.526621572133074 ], [ -2.698877690157024, 51.527056411713524 ], [ -2.698899747527976, 51.527464470720425 ], [ -2.698244606265581, 51.527890136955534 ], [ -2.698368981726668, 51.528103334530037 ], [ -2.698956566064365, 51.528256332523817 ], [ -2.698537066790418, 51.529098673915499 ], [ -2.699317154252495, 51.52986815726161 ], [ -2.69851954705254, 51.529934035739707 ], [ -2.698292953118196, 51.530101771421457 ], [ -2.698254970604742, 51.530633337016077 ], [ -2.697956601096445, 51.531020021757762 ], [ -2.697986040008019, 51.531437025712506 ], [ -2.697282986003121, 51.531749620103191 ], [ -2.696700917649108, 51.532427433406937 ], [ -2.696637198741557, 51.532792854796348 ], [ -2.697178676957101, 51.533316571807518 ], [ -2.697110875354893, 51.53340686472405 ], [ -2.696578868096014, 51.53341002570739 ], [ -2.696231289082928, 51.53311356526271 ], [ -2.696047364886485, 51.533531925825379 ], [ -2.696242802162317, 51.533867942729671 ], [ -2.69650299856382, 51.53391403943192 ], [ -2.697428505848638, 51.533718781941381 ], [ -2.697203789666467, 51.534018642324412 ], [ -2.697411247263409, 51.534098309773093 ], [ -2.696921351754177, 51.534399746153227 ], [ -2.697159998550778, 51.534645614862896 ], [ -2.697754084173317, 51.534651070957032 ], [ -2.697242582092398, 51.535047920443624 ], [ -2.697434394822624, 51.535612366993661 ], [ -2.697195355587728, 51.535916806908375 ], [ -2.697236702053584, 51.536638646266631 ], [ -2.696919712778699, 51.536844580211728 ], [ -2.696804300809722, 51.537219297544937 ], [ -2.696299034680646, 51.53708476684502 ], [ -2.695777550079904, 51.537297394816456 ], [ -2.695704079135105, 51.537491992668045 ], [ -2.696483291627036, 51.537629483844221 ], [ -2.696494385509172, 51.537881109467122 ], [ -2.696238640024637, 51.538034631592673 ], [ -2.694675821381771, 51.537854141031886 ], [ -2.695093279768842, 51.538287813085695 ], [ -2.694713710777112, 51.538921268155818 ], [ -2.694719859089435, 51.539324926802635 ], [ -2.695081747718122, 51.539512540049074 ], [ -2.695827743836139, 51.539551263787864 ], [ -2.696277792235068, 51.540132157461066 ], [ -2.695747511267196, 51.540339354055519 ], [ -2.695622814402168, 51.540581987072891 ], [ -2.694717300542827, 51.540577466170561 ], [ -2.694894884516957, 51.540785947238987 ], [ -2.694846613492404, 51.541113521857888 ], [ -2.695367537766311, 51.54132886676598 ], [ -2.695536227740241, 51.541897048500729 ], [ -2.694529114796858, 51.542709597085768 ], [ -2.69440346689533, 51.542976504541436 ], [ -2.693784647686764, 51.543345208717405 ], [ -2.69380653205183, 51.543744279527317 ], [ -2.693605431750988, 51.5440772518497 ], [ -2.693852291545392, 51.544759133361808 ], [ -2.693985264188151, 51.545066758249654 ], [ -2.694645048705034, 51.545395534447103 ], [ -2.694616965073065, 51.545542310858799 ], [ -2.693431882414902, 51.546128392334168 ], [ -2.693281229761784, 51.546276701957225 ], [ -2.693741185331564, 51.546459245065215 ], [ -2.691506849652164, 51.547758220504541 ], [ -2.691717692359412, 51.548065388689473 ], [ -2.691293798962213, 51.54826204933493 ], [ -2.691556159851033, 51.548445765345157 ], [ -2.692126717527532, 51.548409140892907 ], [ -2.693467237478764, 51.547984045398486 ], [ -2.694750479521598, 51.547297515066411 ], [ -2.696330986579673, 51.546068969127333 ], [ -2.696715687932674, 51.545387747751185 ], [ -2.697375788712492, 51.544794867530797 ], [ -2.697552934385552, 51.544405400669682 ], [ -2.69787048192171, 51.544232721264102 ], [ -2.699634100352611, 51.544141224124949 ], [ -2.700936830071498, 51.544650492072194 ], [ -2.700898695728592, 51.544985199654995 ], [ -2.701144767927332, 51.545701228769019 ], [ -2.700956911261675, 51.546328163766219 ], [ -2.700479059496729, 51.546762668819021 ], [ -2.699571849644603, 51.546756397452626 ], [ -2.698575753098539, 51.546970878237602 ], [ -2.698220757637854, 51.547238256417764 ], [ -2.698839279045093, 51.547229179553526 ], [ -2.698852466203461, 51.547337058499402 ], [ -2.697791050971926, 51.54780639939522 ], [ -2.697213522460419, 51.54738636341505 ], [ -2.696370750592217, 51.548104374750189 ], [ -2.695628893086032, 51.548252600163615 ], [ -2.692877921840326, 51.549720150796787 ], [ -2.69156022100553, 51.550994831226639 ], [ -2.687379625768219, 51.552837510754955 ], [ -2.686461241670178, 51.553060511486521 ], [ -2.68450867451906, 51.552789578928312 ], [ -2.683223441877977, 51.55287977027902 ], [ -2.681240365898319, 51.553557565232602 ], [ -2.680356526376604, 51.554066255958674 ], [ -2.679693688867009, 51.554587053108051 ], [ -2.679750982555675, 51.555334871332846 ], [ -2.680365838960501, 51.55469021486077 ], [ -2.681789044741508, 51.553699189434361 ], [ -2.682754623824235, 51.553353611036066 ], [ -2.684735384512057, 51.55329172704846 ], [ -2.685406805243107, 51.553528799598013 ], [ -2.685995444646741, 51.553543336520079 ], [ -2.68609190421162, 51.553718146854727 ], [ -2.685527041839142, 51.554620614292652 ], [ -2.684710687458398, 51.555194472824276 ], [ -2.684545591049696, 51.55563607474194 ], [ -2.684167254708911, 51.555895455841068 ], [ -2.683909976887423, 51.556431888473035 ], [ -2.68331398801285, 51.556802200691713 ], [ -2.683462818844772, 51.557011764896849 ], [ -2.683136567840919, 51.557279828039825 ], [ -2.682870915733249, 51.557846060404366 ], [ -2.682291077817255, 51.557843142138367 ], [ -2.682385110455758, 51.557959451462999 ], [ -2.682048725851442, 51.558131388746951 ], [ -2.681976481306843, 51.558509434347513 ], [ -2.681359051512256, 51.558705385663913 ], [ -2.681118773750268, 51.559029663902521 ], [ -2.679700270387211, 51.559869548568201 ], [ -2.67895080629324, 51.56001061052303 ], [ -2.680278090193959, 51.560986580724332 ], [ -2.680393991615726, 51.560631654406237 ], [ -2.682333246929514, 51.559794037083073 ], [ -2.683669361318805, 51.559911204068733 ], [ -2.683739409536964, 51.559387549402267 ], [ -2.684197987304759, 51.559384875612807 ], [ -2.684142916603938, 51.559654056114951 ], [ -2.685426622095259, 51.559647461308067 ], [ -2.685269024216872, 51.560097919131124 ], [ -2.685631744137873, 51.559952875478388 ], [ -2.686182833381707, 51.559379574338855 ], [ -2.68687194805018, 51.559253201804815 ], [ -2.686999654279246, 51.559306387641954 ], [ -2.68692954131392, 51.559728559536481 ], [ -2.687413390713974, 51.559768872135059 ], [ -2.687371071206082, 51.560022698247082 ], [ -2.689295579143514, 51.560508584205671 ], [ -2.691773580381619, 51.56058847123343 ], [ -2.693131271771177, 51.560220809234025 ], [ -2.693719571258084, 51.560300928904653 ], [ -2.693690457834232, 51.560474587738199 ], [ -2.693920500155328, 51.560514576332238 ], [ -2.694143613502586, 51.560864903904381 ], [ -2.694009548088574, 51.561629038375827 ], [ -2.694158367170776, 51.561646135746692 ], [ -2.69446833895352, 51.561443757760806 ], [ -2.694611502628538, 51.560707434584941 ], [ -2.695036088031769, 51.560362350971168 ], [ -2.695875299019506, 51.560337600057693 ], [ -2.699136381464774, 51.55926892975922 ], [ -2.699859191005196, 51.559279001995677 ], [ -2.700869751843892, 51.558673225727368 ], [ -2.701482412758742, 51.558736980817613 ], [ -2.701681160681132, 51.558621632457367 ], [ -2.702124020112757, 51.558903932415781 ], [ -2.702048189073126, 51.55903841154764 ], [ -2.702238092785115, 51.559198177121239 ], [ -2.702021739014623, 51.559568198885458 ], [ -2.702444267610848, 51.559842529225854 ], [ -2.702412923479042, 51.560525247939502 ], [ -2.702578385040446, 51.560588078628214 ], [ -2.702673626987218, 51.560964235062876 ], [ -2.702470368542186, 51.561821469997248 ], [ -2.701515164832503, 51.562649854477662 ], [ -2.701071343439686, 51.564464319439836 ], [ -2.700539537108479, 51.564968360275245 ], [ -2.699324571920375, 51.565332560100394 ], [ -2.698153080232338, 51.566928332847631 ], [ -2.697913956012818, 51.56705110633078 ], [ -2.697754341947896, 51.567930544650288 ], [ -2.697289221510121, 51.567985445947656 ], [ -2.6971812200107, 51.568188428786961 ], [ -2.698094552216399, 51.568853751917104 ], [ -2.69713548459912, 51.569257754667227 ], [ -2.694318382777464, 51.56987689931168 ], [ -2.694073000658189, 51.570059118728118 ], [ -2.694452651050891, 51.570162941425203 ], [ -2.694655862483892, 51.570523183305539 ], [ -2.694918477164453, 51.570620596169547 ], [ -2.697535271722502, 51.570109596729864 ], [ -2.697897067422784, 51.570181154297813 ], [ -2.697976126732926, 51.570449542962471 ], [ -2.710695408398487, 51.569641301536727 ], [ -2.708535439045781, 51.573629453747742 ], [ -2.706472787268318, 51.576751163301694 ], [ -2.703667559818078, 51.580301747109019 ], [ -2.702485889197005, 51.581260125521759 ], [ -2.699627926523646, 51.583019703705283 ], [ -2.694052604983358, 51.585383461091077 ], [ -2.689369198668501, 51.586641113170373 ], [ -2.682679588317429, 51.587921053973247 ], [ -2.680195357338215, 51.588590053158882 ], [ -2.671186476667818, 51.591698065720998 ], [ -2.66743746803905, 51.593265988707948 ], [ -2.663107571048552, 51.595895425931324 ], [ -2.658458343155317, 51.598052510207552 ], [ -2.654751566618742, 51.599006566549271 ], [ -2.651091751595601, 51.599517902559313 ], [ -2.647470941994793, 51.600341721603066 ], [ -2.646303957569757, 51.600827441200011 ], [ -2.645465640742998, 51.60137246598088 ], [ -2.642623925956069, 51.604324633594018 ], [ -2.640286123034171, 51.607086114805206 ], [ -2.638528900209647, 51.608748289742351 ], [ -2.63786424539474, 51.609849802377788 ], [ -2.637631963875533, 51.611516248594299 ], [ -2.637770526881691, 51.612125119132898 ], [ -2.638525533828323, 51.613343855956828 ], [ -2.639291026654889, 51.614170437347433 ], [ -2.64487120411163, 51.61668267111466 ], [ -2.6468012663864, 51.618745505628105 ], [ -2.647324265799068, 51.620072430758896 ], [ -2.64743797512391, 51.621567995194283 ], [ -2.647157145031922, 51.623049555407562 ], [ -2.64663724525002, 51.624580971615224 ], [ -2.645400705605619, 51.627024379151379 ], [ -2.644348446019458, 51.628519159281694 ], [ -2.643247995316836, 51.629668933000374 ], [ -2.641106620802154, 51.631597604357381 ], [ -2.636556277607092, 51.634233440746591 ], [ -2.633947261501882, 51.636545729453495 ], [ -2.632556223869354, 51.637094539865821 ], [ -2.628887610656303, 51.6416000233516 ] ] ] }' ] ];
    },

    sub (GET + /area/*) {
        my ($self, $area) = @_;
        my $response;
        if ($area eq '999') {
          $response = { code => 404, error => "No Area matches the given query." };
          return [ 404, [ 'Content-Type' => 'application/json' ], [ $self->json->encode($response) ] ];
        } else {
          $response = { "id" => $area, "name" => "Area $area", "type" => "UTA" };
          return $self->output($response);
        }
    },

    sub (GET + /area/*/children + ?*) {
        my ($self, $area, $query) = @_;
        if ($area eq '2514') {
            return $self->output({
                151907 => {parent_area => 2514, id => 151907, name => "Bordesley & Highgate", type => "MTW"},
                151942 => {parent_area => 2514, id => 151942, name => "Birchfield", type => "MTW"},
            });
        }
        if ($area eq '2508') {
            return $self->output({144390 => {parent_area => 2508, id => 144390, name => "Brownswood", type => "LBW"}});
        }
        if ($area eq '2326') {
            return $self->output({23261 => {parent_area => 2326, id => 23261, name => "Lansdown", type => "DIW"}});
        }
        if ($area eq '2226') {
            return $self->output({22261 => {parent_area => 2226, id => 22261, name => "Lansdown and Park", type => "CED"}});
        }
        if ($area eq '164185') {
            return $self->output({53295 => {parent_area => 164185, id => 53295, name => "Weston By Welland", type => "CPC"}});
        }
        if ($area eq '164186') {
            return $self->output({53296 => {parent_area => 164186, id => 53296, name => "Sulgrave", type => "CPC"}});
        }
        if ($area eq '2457') { # Epsom Ewell
            return $self->output({167337 => {parent_area => 2457, id => 167337, name => "Auriol", type => "DIW"}});
        }
        if ($area eq '2487') { # Harrow
            return $self->output({165128 => {parent_area => 2487, id => 165128, name => "Belmont", type => "LBW"}});
        }
        if ($area eq '2488') { # Brent
            return $self->output({165138 => {parent_area => 2488, id => 165138, name => "Alperton", type => "LBW"}});
        }
        if ($area eq '2489') { # Barnet
            return $self->output({165692 => {parent_area => 2489, id => 165692, name => "Barnet Vale", type => "LBW"}});
        }
        if ($area eq '2505') { # Camden
            return $self->output({165469 => {parent_area => 2505, id => 165469, name => "Belsize", type => "LBW"}});
        }
        if ($area eq '2561') { # Bristol
            return $self->output({148666 => {parent_area => 2561, id => 148666, name => "Ashley", type => "UTW"}});
        }
        if ($area eq '2608') { # South Gloucestershire
            return $self->output({153253 => {parent_area => 2608, id => 153253, name => "Bitton & Oldland Common", type => "UTW"}});
        }
        if ($area eq '2642') { # North Somerset
            return $self->output({145739 => {parent_area => 2642, id => 145739, name => "Backwell", type => "UTW"}});
        }
        my $response = {
            "60705" => { "parent_area" => 2245, "generation_high" => 25, "all_names" => { }, "id" => 60705, "codes" => { "ons" => "00HY226", "gss" => "E04011842", "unit_id" => "17101" }, "name" => "Trowbridge", "country" => "E", "type_name" => "Civil parish/community", "generation_low" => 12, "country_name" => "England", "type" => "CPC" },
            "62883" => { "parent_area" => 2245, "generation_high" => 25, "all_names" => { }, "id" => 62883, "codes" => { "ons" => "00HY026", "gss" => "E04011642", "unit_id" => "17205" }, "name" => "Bradford-on-Avon", "country" => "E", "type_name" => "Civil parish/community", "generation_low" => 12, "country_name" => "England", "type" => "CPC" },
        };
        if ($query->{min_generation}) {
            $response->{"58805"} = { "parent_area" => 2245, "generation_high" => 10, "id" => 58805, "name" => "Bishops Cannings", "generation_low" => 1, "type" => "CPC" };
        }
        return $self->output($response);
    },

    sub (GET + /area/*/example_postcode) {
        my ($self, $area) = @_;
        return [ 200, [ 'Content-Type' => 'application/json' ], [ '"AB12 1AA"' ] ];
    },

    sub (GET + /nearest/**.*) {
        my ($self, $point) = @_;
        foreach (@PLACES) {
            if ($point eq "4326/$_->[2],$_->[1]") {
                return $self->output({
                    postcode => { wgs84_lat => $_->[1], wgs84_lon => $_->[2], postcode => $_->[0], distance => 93 },
                });
            }
        }
        return $self->output({});
    },

}

LWP::Protocol::PSGI->register(t::Mock::MapIt->to_psgi_app, host => 'mapit.uk');

__PACKAGE__->run_if_script;
