AI Glossary / Data engineering and architecture / Intermediate
Relational Synthesis Algorithm
Definition
A relational synthesis algorithm constructs a collection of relation schemas from a specified set of attributes and functional dependencies. In database normalization, the term commonly refers to a third normal form, or 3NF, synthesis algorithm. With the appropriate minimal-cover and key steps, this construction produces a dependency-preserving, lossless-join decomposition into 3NF relations. These guarantees apply to the supplied dependency model, not to the accuracy of the business assumptions behind it.
What it means
Instead of repeatedly splitting a large table wherever a problem is found, synthesis builds smaller schemas around dependencies. A dependency such as ProductID → ProductName says that equal product identifiers must imply equal product names in the modeled context. The algorithm organizes these rules into relations where they can be enforced locally. It helps answer which facts belong together, but it does not discover the correct meaning of a product, customer, or historical record by itself.
How it works
Begin with a universal relation schema R and functional dependencies F. Compute an equivalent minimal cover, removing redundant dependencies and unnecessary determinant attributes and using singleton right sides. Form a schema containing the determinant and dependent attribute for each dependency; standard variants may combine dependencies with the same determinant. If no resulting schema contains a candidate key of R, add a relation whose attributes form such a key. Redundant contained schemas may be removed in common variants. Validate the result against the intended rules before translating it into database tables.
Three practical examples
- Training administration: dependencies linking a course code to its title and an instructor code to contact details guide separate course and instructor relations.
- Product catalogs: product facts and supplier facts can be separated while preserving the association between the two.
- AI experiment records: stable model-version facts and dataset-version facts can be organized separately from the runs that connect them, provided their identifiers have explicit scopes.
Think of it this way
Think of assembling labeled folders around statements about which identifier determines which facts. The key relation preserves the connecting skeleton when the fact folders alone would lose associations. The analogy is limited: mathematical losslessness is a property of relations and dependencies, not merely a promise that every paper has been placed somewhere.
Worked example
Consider R(A,B,C,D), with only A → B and C → D as the nontrivial generating dependencies. A minimal cover already consists of these two rules. The first construction gives AB and CD. Neither contains a candidate key of R: AC is needed to determine all four attributes. Add AC, producing AB, CD, and AC. To see why the connecting relation matters, imagine original tuples (a1,b1,c1,d1) and (a2,b2,c2,d2). Joining AB and CD alone permits four combinations, including associations absent from the original data. AC stores only (a1,c1) and (a2,c2), so the three-way join preserves the intended two associations. The dependencies can be checked within AB and CD. This is an original illustration under the stated complete dependency assumptions, not a universal recipe for four-column tables.
Illustrative case study
Fictional example: Lantern Training records course descriptions alongside instructor details for each assignment. Its designer first asks whether a course can have several instructors and whether titles change by version. After defining those rules, the team uses synthesis to propose schemas and checks the reconstructed assignment records. This invented case shows why interviewing data owners comes before running an algorithm. No measured improvement or real organization is implied.
Common misconceptions and mistakes
Do not omit the key step and assume that preserving dependencies automatically guarantees a lossless join. Do not infer permanent dependencies just because a small sample currently has unique values. Different minimal covers or algorithm variants can produce different valid designs. Also, 3NF is not identical to BCNF, and a synthesis result need not satisfy stronger normal forms. A relation containing a key is not, by itself, a general proof that any arbitrary decomposition is lossless; the guarantee depends on the complete construction.
Business use
Synthesis offers a reviewable way to turn agreed data rules into a logical design. That helps teams explain why repeated descriptions or missing associations are being addressed. For AI projects, it can clarify version identities and prevent joins from manufacturing training or evaluation associations. The design still needs implementation decisions about nullability, foreign keys, history, transactions, and workload. Use the output as a rigorously motivated proposal, then test representative business operations and boundary cases.
People also ask
Does synthesis generate realistic synthetic data?
No. Here synthesis means constructing relation schemas, not generating example records.
Does it find the functional dependencies automatically?
The classical algorithm takes them as input; discovering and validating them is separate work.
Is the output always BCNF?
No. The standard guarantee is 3NF with dependency preservation and a lossless join, under the algorithm's assumptions.
Check your understanding
The dependency schemas AB and CD preserve A → B and C → D. Why add AC when AC is a candidate key of the original relation?
Answer: It records which A and C values belong together and supplies the key relation required by the construction when neither existing schema contains a key.
Related terms
- Third normal form (3NF)
- Minimal Cover
- Functional dependency
- Candidate key
- Normalization
- Spurious Tuple
- third normal form
- dependency preservation
- lossless decomposition
- universal relation
- BCNF
Learn next
compute attribute closures for a four-attribute example, identify its candidate keys, and apply synthesis manually. Project two or three original tuples into the proposed relations and join them back. Explain separately why dependencies are preserved and why the join is lossless.
More in Data engineering and architecture
- Relational data stream management system - A relational data stream management system applies relational query concepts to continuously arriving data.
- Relational database - A relational database is a database that presents data through tables based on relational concepts, with rows representing records and columns representing...
- Relational Model/Tasmania - Relational Model/Tasmania, abbreviated RM/T, is Edgar F. Codd's 1979 proposal for extending the relational model to represent more meaning about data.
- Relaxed sequential - Relaxed sequential describes a parallel-programming approach in which parallel execution is an opportunity for acceleration rather than a requirement for...
- Relvar - A relvar, short for relation variable, is a variable whose value is a relation.
- Remote procedure call - A remote procedure call (RPC) is a way for a program to request execution of an operation in another process, often on another computer, through an...
Sources
Sources: Grant Weddell, University of Waterloo CS 348, Schema Refinement, https://cs.uwaterloo.ca/~gweddell/cs348/normalization-handout.pdf ; University of Otago COSC344, Functional Dependencies and Normalisation, https://www.cs.otago.ac.nz/cosc344/lectures/L8_2022.pdf . Primary instructor excerpts consulted for the synthesis construction, minimal covers, and dependency reasoning. Examples and business scenarios are original. This entry scopes the broad supplied label to standard 3NF synthesis; other synthesis algorithms may differ.
Previous: Relational reinforcement learning Next: Relational uncertainty