Skip to main content

Compute functional dependencies for database schema design and normalization: implication, closure, synthesis

Project description

REUSE status Binder

Overview

This package provides an Open Educational Resource (OER) to refresh prior knowledge about functional dependencies (FDs) and normalization of relational database schemata. Towards that goal, the package implements algorithms for the manipulation of functional dependencies; the package’s doc string explains the used vocabulary and contains examples.

Selected algorithms:

  • FD.rminimize(): Return a minimal cover of r-minimal FDs
  • FDSet.closure(): Return closure of attributes under given FDs
  • FDSet.lminimize(): Return minimum subset of lhs that determines rhs
  • FDSet.key(): Return a key
  • FDSet.basis(): Return non-redundant r- and l-minimal basis
  • RelSchema.synthesize(): Normalize via synthesis into set of 3NF schemata

A 3NF synthesis example is available as notebook on mybinder.org.

Side goal

Besides, the package may serve as sample Python code that respects usual coding conventions, which are checked with pre-commit hooks. The configuration file .pre-commit-config.yaml specifies test tools used here.

Origin of code

The code here is based on that file, which will not be maintained any longer.

Changelog

Changelog information is based on Keep a Changelog, where version numbers adhere to Semantic Versioning.

[Unreleased]

[1.1.0] - 2020-12-28

Added

  • Parameter minimize in RelSchema.synthesize().
  • Sample notebook with 3NF example by Codd at mybinder.

Fixed

  • Import in init.py.
  • Project URL in docstring.
  • Raw URL for coverage badge in setup.py.
  • URL for REUSE badge in README.md.

[1.0.1] - 2020-12-22

Fixed

  • Package URL and coverage badge in setup.py.

[1.0.0] - 2020-12-22

No change in functionality.

[1.0.0-rc.1] - 2020-12-22

Initial release. Code from there packaged for independent distribution.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

functional_dependencies-1.1.0.tar.gz (32.8 kB view hashes)

Uploaded Source

Built Distribution

functional_dependencies-1.1.0-py2.py3-none-any.whl (32.9 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page