# Brick Planner (Wall Planner)
Android application (Java) for designing a brick wall with a door and/or
window — how many bricks are needed, what is the allowance for reserve and
approximate price, plus visualization of the masonry.
## What does the app do?
- **Language**: Bulgarian, English, Français, Deutsch, Español — selectable from
spinner and is preserved between startups, regardless of the system language of
the device.
- **Measurement system**: Metric (m/cm/mm) or English (feet/inches) —
all previously entered values are automatically recalculated upon change.
- **Wall and brick dimensions**: wall width/height, brick dimensions
the brick and the width of the joint.
- **Masonry model**: row connection (50% offset) or straight masonry.
- **Opens**: optional door (width, height, distance from left
edge) and optional window (width, height, distance from the left
edge, height of the sill from the floor) — are subtracted from the masonry area.
- **Reserve and price**: technological reserve in percentages, optionally price of
brick and number of bricks in a pallet/package.
- **Visualization**: `WallView` (custom View) draws a wall elevation with
the selected masonry model and depicts the door/window.
- **History**: calculations are stored in a local SQLite database
(`DatabaseHelper`) and are viewed/deleted from a separate screen.
## Calculation formula in brief
1. Wall area = width × height.
2. Opening area = (width × height of door, if any) + (width ×
window height, if any).
3. Net masonry area = wall area − opening area.
4. Face of one brick (with joint) = (width of brick + joint) × (height of
brick + joint).
5. Bricks needed (net) = rounded up (net area / brick face).
6. Total reserve = user-entered reserve + 5% additional surcharge,
if the wall has a door and/or window (due to cut bricks on the edges).
7. Bricks to order = rounded up (net bricks × (1 + reserve / 100)).
8. Pallets/packages = rounded up (bricks to order / bricks in
pallet/package), if specified.
9. Price = bricks per order × brick price, if set.
Rows/columns (brick courses) are calculated separately using the grid method
(width/height of the wall divided by the brick pitch with the joint) and
are for information only — the basic calculation of the number is by area,
to remain correct in the presence of holes of arbitrary shape/position.
Android application (Java) for designing a brick wall with a door and/or window