<｜begin▁of▁sentence｜>### Instruction:
Given a graph with edge set [('A', 'B', 2), ('A', 'C', 3), ('B', 'C', 1), ('C', 'D', 4)], can you compute the current-flow betweenness centrality for each node using NetworkX, taking into account the weights of the edges, normalizing the centrality values and using an LU decomposition based solver?
### Response:
import networkx as nx
import numpy as np

# Create a weighted graph
G = nx.Graph()
G.add_edge('A', 'B', weight=2)
G.add_edge('A', 'C', weight=3)
G.add_edge('B', 'C', weight=1)
G.add_edge('C', 'D', weight=4)

# Compute the current flow betweenness centrality
betweenness = nx.current_flow_betweenness_centrality(G, normalized=True, weight='weight', dtype=np.float32, solver='lu')

# Print the betweenness centrality for each node
for node, centrality in betweenness.items():
    print(f'Node {node}: {centrality:.4f}')
<|EOT|>
