Memcoin ยท TX1 / TX2 ยท design & architecture

The payment.
And spending it.

TX1 is the payment โ€” one transaction, one step. The moment it enters the mempool, the sender's funds belong permanently to the recipient, at zero fee. TX2 is how the recipient later spends what's theirs, also at zero fee. Two transaction types, one hard boundary between them: 1 MEM.

Overview

Two payment paths.
One chain.

The standard transaction is fee-bearing, immediately spendable, general-purpose โ€” for transfers of any size. TX1/TX2 is built for a different job: zero-fee, irrevocable payments bounded at 1 MEM. Both coexist under the same consensus.

Standard transaction

Immediate. Any size.

Fee-bearing, spendable as soon as it confirms. The right tool for transfers with no cap and no lock.

TX1 / TX2

Final at mempool entry. Capped at 1 MEM.

TX1 is the payment โ€” final the instant it reaches the network. TX2 is the recipient spending their own unlocked balance, not a second half of the payment.

Design philosophy

Four commitments.

Zero fee, both directions

No cost, either side.

TX1 carries no fee. TX2 carries no fee. A recipient can consolidate many unlocked outputs into one TX2 and split the total across up to three addresses, at no cost.

Forward security

Certainty sent to the future.

The 3-day lock doesn't build certainty over time โ€” it transfers certainty forward from the moment TX1 is broadcast. The payment is already final; the lock is a property of the output, not of the payment.

Irrevocable commitment

No cancellation path.

Once broadcast, the sender permanently loses control. There's no expiry on the recipient's claim โ€” if TX2 is never broadcast, the funds stay locked to the recipient indefinitely. A refund requires the recipient to voluntarily send it back.

A hard ceiling

Large amounts, elsewhere.

TX1/TX2 is bounded at 1 MEM per payment by consensus. Anything larger uses a standard fee-bearing transaction โ€” settled immediately, no lock period.

UTXO lifecycle

One direction.
Never chains, never nests.

TX1 is the only way to create a CLTV+P2PKH output. TX2 is the only way to spend one โ€” and it always produces plain P2PKH outputs. Locked outputs can't chain or nest; the payment graph stays flat.

Sender's balance

P2PKH

An ordinary spendable output โ€” the sender's funds before any payment is made.

โ†’TX1
~3-day lock

CLTV+P2PKH

Locked to the recipient. Visible and attributed to them immediately โ€” spendable only once the lock expires.

โ†’TX2
Recipient's balance

P2PKH

Ordinary spendable output again โ€” no restrictions, usable like any other balance.

TX1 ยท the payment

Spends a single P2PKH output, locks the payment amount to the recipient, with an optional change output back to the sender. Final โ€” and the sender's control ends โ€” the moment it enters the mempool.

The lock period

The locked output sits on-chain for ~3 days (432 blocks), visible and already attributed to the recipient, but not yet spendable. The payment is settled; the lock is just the gap before availability.

TX2 ยท spending it

Once unlocked, the recipient broadcasts TX2 โ€” consolidating up to 1,000 unlocked outputs from any number of past TX1s, split across up to three P2PKH addresses, at zero fee.

Rule layers

Consensus vs. policy.

Consensus rules

Cannot be bypassed by a miner.

Enforced by every node on every block, unconditionally. A block that violates one is rejected by the entire network regardless of who mined it โ€” the structural shape of TX1/TX2, the lock period, the value ceiling, and the output floor all live here.

Policy rules

Adjustable, no fork required.

Enforced at mempool admission, defending against abuse within the bounds consensus already sets. Operators tighten or relax them as conditions change โ€” the consensus output floor is the hard backstop beneath any policy value.

TX1 rules

The payment,
rule by rule.

R0
Exactly one input, and it must be P2PKH. A sender whose balance is spread across multiple addresses must consolidate first with a standard transfer.
R1
Total input value must equal total output value โ€” no fee is deducted.
R2
The CLTV output's locktime must fall within ยฑ30 blocks of the 432-block target from the current height, accommodating propagation delay. A TX1 that lingers past its valid pack window must be rebuilt with an updated locktime.
R3
The first output must match the CLTV+P2PKH template exactly, with a height-encoded โ€” not time-encoded โ€” locktime.
R3b
At most 2 outputs. A second output, if present, must be P2PKH change back to the sender. One TX1 issues exactly one payment to exactly one recipient.
R4
A sender address may broadcast at most 6 TX1s within any rolling 6-block window, across confirmed blocks and the mempool.
R5
The locked output value must not exceed 1 MEM โ€” enforced at both mempool admission and block validation.
R5b
mempoolminvalue โ€” the minimum a TX1 output must carry to enter the mempool. Default 100 kbit. Operators may raise it independently or through coordinated governance; it cannot go below the 10 kbit consensus floor.

R0, R1, R2, R3, R3b, R5 are consensus ยท R4, R5b are policy

TX2 rules

Spending it,
rule by rule.

TX2 spends unlocked CLTV+P2PKH outputs exclusively. It cannot spend standard P2PKH outputs, and CLTV and P2PKH inputs can never mix in one transaction.

R6
Total input value must equal total output value โ€” no fee is deducted.
R7
Every input must reference a CLTV+P2PKH output.
R7b
A single TX2 may have at most 1,000 inputs.
R8
When spending multiple inputs, their locktimes must fall within a 31-block spread, and nLockTime must satisfy all of them at once. TX1 payments issued more than ~5 hours apart can't be combined and must be spent separately.
R9
A recipient address may broadcast at most 10 TX2s within any rolling 144-block window.
R10
A TX2 must have between 1 and 3 outputs.
R10b
Every output must be standard P2PKH. TX2 can never create a CLTV+P2PKH output.

R6, R7, R10, R10b are consensus ยท R7b, R8, R9 are policy

Minimum output value

MIN_OUTPUT_VALUE (consensus) โ€” every output of every transaction must carry at least 10 kbit, without exception, checked before TX1/TX2 classification even occurs.

Miner incentives

Paid by the block.
Not the transaction.

TX1 and TX2 carry no fee โ€” miner income from these transactions comes entirely from the block reward, permanently fixed at 7 MEM after block 472,500.

Same population

Miners are the payers.

Yesmem runs without displacing normal computer use. Miners are ordinary users โ€” the same people making and receiving these payments โ€” so they include zero-fee transactions because the transactions are their own.

No gatekeeper

No one controls the next block.

Each mining thread needs a dedicated, non-shareable 8 GiB โ€” large pools are structurally unviable. Miners are distributed individuals, not a coordinated few who could choose to exclude zero-fee transactions.

Security & finality

Point of no return:
mempool entry.

What happens the instant TX1 enters the mempool?

The payment is final. The sender's funds are locked into a CLTV output only the recipient can spend once the lock expires. Any block that tries to spend it early violates OP_CLTV and is rejected by the entire network. The payment timeline moves only forward โ€” a reorg deep enough to displace a confirmed TX1 is highly unlikely, and even then TX1 simply re-enters the mempool and reconfirms, since the P2PKH output it spent remains unspent on the new chain.

What's enforced at consensus, and what isn't?

The lock period (R2) and the value ceiling (R5) are checked by every node on every block โ€” a TX1 with an invalid locktime or an out-of-range value is rejected outright, and no miner can bypass that.

How is the lifecycle kept structurally sound?

R3, R7, and R10b together guarantee CLTV+P2PKH outputs are created only by TX1 and spent only by TX2, and that TX2 outputs are always plain P2PKH. Locked outputs never chain or nest โ€” the payment graph stays flat, entirely by consensus.

Can the two payment paths be mixed?

No. Setting nLockTime > 0 on an ordinary P2PKH transaction isn't permitted โ€” it gets classified as TX2 and rejected at mempool entry by R7. Standard transactions and TX1/TX2 are structurally separate paths that never combine.