#include<bits/stdc++.h>
#define int long long 
using namespace std;
const int N=2e5+10;
int n,top;
int a[N],b[N],c[N],pre[N],suf[N],stk[N];
long double ans;
void init(){
	int mx=0,ps=-1;
	for(int i=1;i<=n;i++) if(a[i]>mx) mx=a[i],ps=i;
	rotate(a+1,a+ps,a+n+1);
	rotate(b+1,b+ps,b+n+1);
	a[++n]=a[1],b[n]=b[1];
	for(int i=3;i<=n;i++) c[i]=2*(b[i-1]+c[i-1])-c[i-2],a[i]-=c[i];
}
long double slope(int tp1,int tp2){ 
	return 1.0*(a[tp2]-a[tp1])/(tp2-tp1); 
}
bool pd(int tp1,int tp2,int tp3){ 
	return slope(tp1,tp2)<=slope(tp2,tp3); 
}
void solve(){
	for(int i=1;i<=n;i++){
		while(top>1 && pd(stk[top-1],stk[top],i)) --top;
		stk[++top]=i;
	}
	stk[top+1]=n+1;
	for(int i=1;i<=top;i++) for(int j=stk[i];j<stk[i+1];j++) pre[j]=stk[i];
	for(int i=1;i<=top;i++) for(int j=stk[i-1]+1;j<=stk[i];j++) suf[j]=stk[i];
	for(int i=1;i<n;i++){
		if(pre[i]!=suf[i]) ans+=1.0*(a[suf[i]]*(i-pre[i])+a[pre[i]]*(suf[i]-i))/(suf[i]-pre[i]);
		else ans+=1.0*a[i];
	}
	for(int i=1;i<n;i++) ans+=c[i];
}
signed main(){
	scanf("%lld",&n);
	for(int i=1;i<=n;i++) scanf("%lld",&a[i]);
	for(int i=1;i<=n;i++) scanf("%lld",&b[i]);
	init();
	solve();
	printf("%.12Lf",1.0*ans/(n-1));
} //11123