gAnmgFun