如何用输出轴的转速和功率选型电动机?

输出轴转速800r/min,转矩2.53125π/3,减速比1.7,该如何算出输入轴转矩和功率,现在是要算电动机功率,方便电动机选型

@ada
给这段代码注释

void find_bmshebeishu()//统计设备总数(按部门)
{
    int i, j, len = 0, n = 0;
    int a[10000] = { 0 }, count[10000] = { 0 };
    char str[10][10000];
    STU* p, * pi, * pj, * pre;
    p = head.next;
    pi = head.next;
    pj = head.next;
    pre = head.next;
    while (p != NULL)
    {
        n++;
        p = p->next;
    }
    for (i = 0; i < n; i++)
    {
        pj = head.next;
        for (j = 0; j < n; j++)
        {
            if (strcmp(pi->bm, pj->bm) == 0 && a[i] != 1 && i != j)
            {
                a[j] = 1;
            }
            pj = pj->next;
        }
        pi = pi->next;
    }
    for (i = 0; i < n; i++)
    {
        if (a[i] == 0)
        {
            strcpy(str[len], pre->bm);
            len++;
        }
        pre = pre->next;
    }
    pre = head.next;
    for (i = 0; i < len; i++)
    {
        pre = head.next;
        for (j = 0; j < n; j++)
        {
            if (strcmp(str[i], pre->bm) == 0)
            {
                count[i]++;
            }
            pre = pre->next;
        }
        printf("%s有%d个\n", str[i], count[i]);
    }
}