added gopen function