Can someone explain the algorithm to compute Monero transaction fee?
The computation of the current dynamic fee algorithm is explained, in detail, here: https://web.getmonero.org/2017/12/11/A-note-on-fees.html.
I have seen somewhere it is based transaction size (or something called "weight"?), and some other vague explanation.
"weight" is just another ...
The order for both ed25519 and curve25519 curves can be found from libgcrypt-1.8.5/cipher/ecc-curves.c in hex is 1000000000000000000000000000000014DEF9DEA2F79CD65812631A5CF5D3ED.
Examine the following that normalizes either an ed25519 or curve25519 private key to their common shared order:
% echo ...