摘要
在基于N元皇后问题回溯算法的基础上 ,提出一种更快速的求解算法 ,该算法借助于矩阵不但避免了求解复杂的逻辑表达式 ,而且由于改进了使用循环结果的条件 ,从而减少了比较次数 ,使得算法的运行效率更高 .同时 ,还讨论了N元皇后的彼此不等价的互不攻击的布局问题 ,并给出了具体算法 .
Based on the backtracking algorithm for N adic queen problem, we give a faster algorithm which involves matrices. Using this algorithm, we can avoid calculating complicated logic expressions and reduce the comparisons since the loop termination condition is improved. Furthermore we also discuss the inequivalent distributions in which the N adic queens do not attack on each other, and give an algorithm.
出处
《四川师范大学学报(自然科学版)》
CAS
CSCD
2001年第5期467-470,共4页
Journal of Sichuan Normal University(Natural Science)