Clean and speed up applyTransaction

- Remove duplicate database once the accountState is retrieved (seems like noticable increase in speed)
- Re-use receiverAddress in multiple locations
- Fewer times casting byte[] to BigInteger
- Avoid duplicate code to invoking Program and VM