Surface melting and effective anchoring in nematics