Live data from Hacker News

Double-entry bookkeeping as a directed graph

matheusportela.com

281–290 of 388 posts

Re: Double-entry bookkeeping as a directed graph

#281
post #263

Earlier quoted context omitted.

The purpose of the words "credit" and "debit" is the same purpose of the structure of double-entry bookkeeping: to make every statement unambiguous, no matter what order or context you put the words in. By replacing familiar verbs like "paid" and "earned" with the nouns "debit" and "credit", we can write sentences where the order of words doesn't change the meaning, and where we never need to figure out what tense (p…

> Bob's account has a credit of $12 and a debit of $7 (I'm 80% sure that the above reads that Bob actually owns $5 he can spend. But I'm equally sure that I get Debits and Credits backward, so I probably read it wrong.) In any case, you've only described a single account at rest. You need to go one step further and describe an entire transaction in those terms, so that someone can swoop in and say "you got it backwar…

You read it correctly. The account's "balance" would be a "credit of $5".

A transaction involves multiple accounts, so it would be written as multiple sentences: "Alice's account has a credit of $7. Bob's account has a debit of $7." If you want to write about the transaction itself, you could do that with a verb: "Transaction #23254 applies a debit of $7 to Bob's account, and a credit of $7 to Alice's account." A double-entry book is just a table with a column for each account, and a column for the date/time each credit or debit was transacted.

The whole point here is that when someone swoops in, every sentence spoken is guaranteed to be unambiguous; no matter what context that someone brings with them. So long as "credit" and "debit" are used exclusively as nouns, there can be no confusion.

Re: Double-entry bookkeeping as a directed graph

#282
post #259

Earlier quoted context omitted.

What matters is that the labels are different on each side of the equation. That contradicts your suggestion that we should use the intuitive meaning of the words and it contradicts your suggestion to 'just use "credit" for any increase, and "debit" for any decrease'. Let's say a company raises equity (i.e it issues new shares), money comes into the bank account. In traditional terminology that would result in: debit…

It doesn't matter whether you encode the signs in the terminology or in the equation. If you say X + Y = 0 i.e. X = - Y and stipulate that a transaction adds to X and subtracts from Y, that is completely equivalent to saying X - Y = 0 i.e. X = Y and stipulating that a transaction adds to both X and Y.

Sure, but if you want to keep your terminology consistent with the math, you would then have to make a distinction based on the types of the accounts involved in a journal entry.

E.g, this would be correct:

  increase bank
  increase equity
but this would be incorrect:

  increase bank
  increase receivables
If all numbers are positive then there would be no way to check whether the journal entries balance out without considering the account types.

If, on the other hand, you encode the sign in the amounts then the sign would disagree with the semantics of the label and you would have to flip signs based on the account type at the time of recording the entries:

  increase bank $100
  increase receivables -$100
I don't suppose this is what you meant.

Re: Double-entry bookkeeping as a directed graph

#283
post #262

Earlier quoted context omitted.

you don't need to record the halves, nothing stops your pizza order to be automatically recordered as -A_cash +A_inventory -A_inventory + L_expenses Sure, if your pizza is frozen and consumed in another period, your books will not reflect reality, but so what, when talking about the very basics of accounting you offset that misrepresentation of a simple example by gaining an important pedagogic benefit! Which one, th…

Perhaps this is obvious to you, but I don't see what I'm gaining by doing this. My inventory management system will have different things unless I'm also recording these pizzas in there for the day. And it will show my inventory valuation as fluctuating when I do things like lunch or dinner for the team. It really seems useless to me when running the business.

That's fine, many accounting practices eschew precision for simplicity, you don't mark-to-market everything, depreciation is linear, etc, so if you don't see any value in this, but only troubles with integration with other systems etc, then it's useless to you. But then the article wasn't about running a real business

Re: Double-entry bookkeeping as a directed graph

#284
post #78
post #26

I believe double-entry bookkeeping needs more attention. I think double-entry bookkeeping is, at least to me, as fundamental to economics (and of course business) as logic to math. Even if some actors don't use it explicitly, it still holds. If I buy ten apples for 10 bucks, I have ten more apples in stock and ten bucks less. Many economic discussions (not only on HN) get out of hands because people don't try to see…

Economics is funny because its very anti complex math. For the local economics (household even company level) that makes total sense but for anyone doing research or systems modeling for things bigger than a company the total distain for calculus and non-equilibrium systems really prevents any discussion. I think its because if you remove stability most of supply and demand arguments fall apart. Its crazy because sta…

Banks don't have that limitation for creating credit/money [1]. Technically, they just need to extend the balance sheet. Limitations are rather that they need to find good projects that yield enough returns to cover the interest rate.

I think this is yet another good example of thinking with double entry bookkeeping.

[1] https://www.investopedia.com/articles/investing/022416/why-b...

Re: Double-entry bookkeeping as a directed graph

#285
post #112

Earlier quoted context omitted.

Remember, this was all done on paper before software with tagging and such existed. I'll give a description shot, since I've been doing finance work recently. Other people can feel free to correct. A company using double entry (as opposed to single) has a "chart of accounts." This means they have a bunch of imaginary accounts for tracking everything, including: - Assets (e.g. cash on hand.) - Liabilities (e.g. loans)…

So double entry is defeated if you uses a computer to enter the entries. For example if you brought a laptop for 1000, but you accidently wrote 2000 AND the computer automatically entered 2000 in the asset account it would still balance even though it was a mistake to enter 2000. In addition, you can still make the same mistake by hand for both entries. So I’m still not getting how double entries catch mistakes

There are several categories of mistake that you can make when bookkeeping. Some are caught by the double-entry system when a trial balance is prepared.

The error you've described is an "error of original entry" and will be invisible if you only look at the trial balance. It can ultimately be caught when you compare the banking ledger with what's actually in the bank.

Other errors that don't appear in the trial balance can be incredibly hard to detect and in fact, may never be noticed. This is where the real art of bookkeeping is IMO.

The types of errors that do affect the trial balance are things like forgetting to enter a purchase in the purchase ledger but entering the transaction into the banking ledger correctly. Silly errors really, but we can all need help to stop us making those.

Re: Double-entry bookkeeping as a directed graph

#286
post #46
post #18

Earlier quoted context omitted.

i was about to write the same thing. knowing that double-entry is meant to apply to myself only, i actually found the example confusing, because well, of course bob is going to have an entry in his accounting book, but i don't care about bobs accounts, i don't want to track that. i only care about mine. i buy a book. how do i record this transaction using double entry bookkeeping in my accounting book? and bob is not…

You gained $20 worth of assets, so the counterpart of the $20 leaving your bank account is countered by your assets-account gaining $20 Now each year your book loses 1/5th of its value, due to wear and tear (4$ disappearing from your assets-account), this is countered by your depreciation-account (4$ tax write off, every year!) After 5 years, it is worth $0 according to your books, but you manage to sell it again for…

It’s been 15 years since I took an accounting course. Why would my bank account be debited when the balance went up? Is a debit not negative? Is the cash balance presented as a negative?

Re: Double-entry bookkeeping as a directed graph

#287
post #259

Earlier quoted context omitted.

It doesn't matter whether you encode the signs in the terminology or in the equation. If you say X + Y = 0 i.e. X = - Y and stipulate that a transaction adds to X and subtracts from Y, that is completely equivalent to saying X - Y = 0 i.e. X = Y and stipulating that a transaction adds to both X and Y.

Sure, but if you want to keep your terminology consistent with the math, you would then have to make a distinction based on the types of the accounts involved in a journal entry. E.g, this would be correct: increase bank increase equity but this would be incorrect: increase bank increase receivables If all numbers are positive then there would be no way to check whether the journal entries balance out without conside…

> you would then have to make a distinction based on the types of the accounts involved in a journal entry

That's right. The distinction is based on whether the account represents an asset or a liability.

> increase bank

> increase receivables

You would have to define what you mean by "bank" in order for this to make sense. But in general, receivables represent money that a company is owed from orders that have not yet been paid for, i.e. they are a effectively a loan from the company to its customer, and like all loans they are an asset to the creditor, which in this case is the company. When a payment is made against an outstanding receivable, the receivable is debited (the loan balance is reduced) and the company's cash balance is credited. Because cash and receivables are both assets, these add together and cancel out just as you would expect.

The rules under my system are still very simple:

1. Every financial asset is someone else's liability, and vice versa. Cash is an asset to its owner and a liability to society at large. Loans are assets to the creditor and a liability to the debtor. Purchase orders are a liability to the purchaser and an asset to the supplier. Etc. etc.

2. Every financial transaction is a change in someone's liability coupled with a change of equal magnitude in someone else's assets.

3. The absolute value of your assets minus the absolute value of your liabilities is your net worth.

A completely equivalent formulation is that liabilities have negative signs attached to them, and then your net worth is the sum of your assets and liabilities, but this is just a question of where you hide the negative sign. A - B is the same as A + (- B). It really doesn't matter except insofar as one convention might make it easier to think about things. Most people are used to seeing their liabilities expressed as positive numbers, i.e. if you owe money on your credit card bill, the balance due is positive, and if you have a credit balance, the balance due is negative. But it's all just a shell game with where you hide the signs.

Re: Double-entry bookkeeping as a directed graph

#288
post #149

Earlier quoted context omitted.

> Debit means an entry in the left column. Credit means an entry in the right column But that just shifts the arbitrariness of the whole thing from the words "debit" and "credit" to the words "left" and "right".

I think his intent was to prevent students from fixating on making the words debit and credit "mean" something by themselves. A debit doesn't have some intrinsic meaning about the "flow of money". It's just an entry in the left column. On the other hand, a debit to Accounts Receivable actually means something.

But at that point how can you tell if something goes left or right?

Re: Double-entry bookkeeping as a directed graph

#289
post #252

Earlier quoted context omitted.

No money was created or destroyed. The "cash gifted" account would have a corresponding entry in the recipients books reflecting the cash received. Unless he's delinquent about updating his books in which case it's implied but not realized. Few (unmedicated) individuals are going to track every transaction to that level though. If it was important to account for the cash donation, the company would require a receipt…

Cash went out. One half of the double entry is correct. But nothing came back in return. There is no corresponding element of trade to account for. The transaction doesn't balance. Which is obvious in human terms. That's the point of a gift – the transaction isn't supposed to balance! But formal accounting methods are not as fluid as people are. So, of course, in reality money was created (and then destroyed, it bein…

You're misunderstanding double-entry bookkeeping. Something does not have to come into the company got every transaction moving something out of the company. If your company gives $1000 to Billy, you document a $1000 debit from your gift account and a $1000 to Billy's account payable. The goal isn't to get any one account to zero but to get a source and destination recorded separately for every movement of funds.

Lending would be at least two sets of doubly-recorded transactions.

Re: Double-entry bookkeeping as a directed graph

#290
post #286
post #46

Earlier quoted context omitted.

You gained $20 worth of assets, so the counterpart of the $20 leaving your bank account is countered by your assets-account gaining $20 Now each year your book loses 1/5th of its value, due to wear and tear (4$ disappearing from your assets-account), this is countered by your depreciation-account (4$ tax write off, every year!) After 5 years, it is worth $0 according to your books, but you manage to sell it again for…

It’s been 15 years since I took an accounting course. Why would my bank account be debited when the balance went up? Is a debit not negative? Is the cash balance presented as a negative?

In your books, your bank account is an asset, and therefore an increase in the balance is recorded with a debit. In the bank's books, it's the other way around.
Post reply on HN