Define a grammar to emmulate chess rules Is it possible to define a 《chess language》:
language={alphabet = {(chess pieces, squares of chess board)}, grammar={rules of movement of pieces over the board}}?

I looked online but I cannot find a way to define the grammar. Every way I can think of, is either stupidly long and complicated, or does not cover all the rules. 

I presume the hard part is that the grammar has to take in consideration the state of the board before evaluating a move as valid or not. 

Do you have insight how to approach this problem i.e: define a grammar that emulates chess rules? 

The way chess apps work(not engines), is that at every move they calculate all possible moves and then check if the user's move is among the calculated moves, else it is invalid. 

I want to accept the user's move and only then check if it's a valid one.
"The way chess apps work(not engines), is that at every move they calculate all possible moves and then check if the user's move is among the calculated moves, else it is invalid."

No, no, no, no, that's not how you check if a move is valid. 

If you want all possible moves, then you generate all possible moves. If you want to check if a move is valid, then you check if that move is valid, and nothing else. There's no reason to know anything about all the other moves if all you want to know is to check if one move is valid.