#include <bits/stdc++.h>

using namespace std;

typedef long long ll;
#define eb emplace_back
#define Min(x, y) (x = min(x, y))
#define Max(x, y) (x = max(x, y))
#define fir(x, y, z) for(int x = (y); x <= (z); ++ x)
#define fdr(x, y, z) for(int x = (y); x >= (z); -- x)
#define fre(x) freopen(#x".in", "r", stdin), freopen(#x".out", "w", stdout)

namespace io {
	const int n = 1e6;
	char c, b[n], *i, *j;
	inline char gc() {
		if (i == j) {
			j = (i = b) + fread(b, 1, n, stdin);
			if (i == j) return EOF;
		} return *i ++;
	}
	#define gc getchar
	template <typename T = int>
	inline T read() {
		T s = 0; int x = 0;
		while (!isdigit(c = gc())) x |= c == '-';
		for (; isdigit(c); c = gc())
			s = (s << 1) + (s << 3) + (c & 15);
		return x ? - s : s;
	}
}

using io :: read;

const int N = 30;

int n, m;
int tot = 1, head[N], ver[N << 1], nxt[N << 1];

inline void add(int x, int y) {
	ver[++ tot] = y; nxt[tot] = head[x]; head[x] = tot;
}

int tim, dfn[N], low[N], c[N];
int top, sta[N];
int cnt;
vector<int> scc[N];

inline void Tarjan(int x, int in_edge) {
	dfn[x] = low[x] = ++ tim;
	sta[++ top] = x;
	for (int i = head[x]; i; i = nxt[i]) {
		int y = ver[i];
		if (!dfn[y]) {
			Tarjan(y, i);
			low[x] = min(low[x], low[y]);
		} else if (i != (in_edge ^ 1)) low[x] = min(low[x], dfn[y]);
	}
	if (dfn[x] == low[x]) {
		++ cnt;
		do {
			scc[cnt].eb(sta[top]);
			c[sta[top]] = cnt;
		} while (sta[top --] != x);
	}
}

int e[N];
int t, h[N], Ver[N << 1], Nxt[N << 1];

inline void Add(int x, int y) {
	Ver[++ t] = y; Nxt[t] = h[x]; h[x] = t;
}

const int P = 1e9 + 7;

inline int power(int x, int y) {
	int res = 1;
	for (; y; y >>= 1, x = 1ll * x * x % P)
		if (y & 1) res = 1ll * res * x % P;
	return res;
}

int f[N];

inline void dfs0(int x, int fa) {
	f[x] = fa;
	for (int i = h[x]; i; i = Nxt[i]) {
		int y = Ver[i];
		if (y != fa) dfs0(y, x);
	}
}

int cho[N], Cnt[N];
int oth;
ll ans = 0;
int flag = 0;

inline void dfs(int x) {
	if (x > n) {
		if (!flag) {
			flag = 1;
			return;
		}
		fir (i, 1, n) cho[c[i]] = Cnt[c[i]] > 0;
		int sum = 0;
		fir (i, 1, cnt) {
			if (!cho[i]) continue;
			int y, res = 1;
			for (y = f[i]; y && !cho[y]; y = f[y]) ++ res;
			if (y) sum += res;
		}
		(ans += 1ll * oth * power(2, cnt - 1 - sum) % P) %= P;
		return;
	}
	dfs(x + 1);
	Cnt[c[x]] ++;
	dfs(x + 1);
	Cnt[c[x]] --;
}

int main() {
	fre(barrack);
	n = read(), m = read();
	fir (i, 1, m) {
		int u = read(), v = read();
		add(u, v); add(v, u);
	}
	Tarjan(1, 0);
	fir (i, 1, n) {
		for (int j = head[i]; j; j = nxt[j]) {
			int y = ver[j];
			if (c[i] == c[y]) {
				++ e[c[i]];
			} else {
				Add(c[i], c[y]);
			}
		}
	}
	
	oth = power(2, m - (cnt - 1));
	fir (i, 1, cnt) e[i] >>= 1;
	dfs0(1, 0);
	dfs(1);
	printf("%d\n", ans);
	return 0;
}
/*
4 4
1 2
2 3
3 1
1 4

184


*/