To set different initial energy to every node
# set initial energy for first node$ns node-config -initialEnergy 50
set node_(0) [$ns node]
# set initial energy for second node
$ns node-config -initialEnergy 100
set node_(1) [$ns node]
# set initial energy for third node
$ns node-config -initialEnergy 70
set node_(2) [$ns node]
and similarly for more nodes...