How to determine checkmated positions using DOS/CMD, from numerous FEN/EPD chess positions? I have a collection of checkmated chess positions, in FEN/EPD format.
Most of the time, each of these positions contains some useless pieces, that I really want to remove, in the aim of getting cleaner schemes.

Then, I'm searching for a batch possibility to check if my whole chess collection is checkmate or not. Ideally, it would be a tool/solution using DOS/CMD, because I have to clean many FEN checkmates.

I've googled for various DOS chess tools, but in vain. I also searched to use some chess engines (under cmd), Arena/WinBoard, EPD2Diag, PGN-Extract, etc. but also without success.

Here are two examples:

[FEN "3q4/6b1/4k3/4r3/3p2Q1/B1N1R3/5R2/6K1 w - - 0 1"]




[FEN "1K6/1b6/1b6/1P6/7r/7p/7Q/4qN1k w - - 0 1"]


Here, it's obviously both checkmate for White, but knowing I have few hundreds of others, how can I get a DOS batch possibility to check all in once?
I don't know if any such tool exists. If you want to program yourself you need to watch out for:

Change of mating theme: If you remove pieces you might get new/different mates, e.g. in:

    6rk/5Npp/8/8/8/8/2K5/7R b - - 0 1


if you remove the white knight and the black pawn on h7 you have a new mate, which might not be desirable.

Impossible positions: If you remove pieces you might end up with positions that cannot be reached in normal play. This can be as easy as positions where three pieces attack the king at the same time, but it can also be a lot more difficult. So in addition to checking for mate, you also need to run some retrograde analysis to check whether the position is legal