liveBook · Manning

Gene

A gene is a discrete unit of encoded information representing a hereditary biological trait or a variable within an evolutionary candidate solution.

How 5 Manning books explain it

Advanced Algorithms and Data Structures

A gene is an individual position in a genetic-algorithm chromosome that represents one optimization variable and its assigned value.

How it is used
Encodes one optimization variable within a candidate solution’s chromosome.
How deep it goes
Develops binary and permutation encodings with mutation and crossover operations; sketches maximum-flow genes without implementing that algorithm.
Examples
Uses knapsack item bits, traveling-salesperson vertex permutations, and maximum-flow edge values.
What you can do after
Build it from scratch: choose gene domains and adapt mutation and crossover to preserve encoding constraints.

Read how Advanced Algorithms and Data Structures explains gene →

Evolutionary Deep Learning: Genetic algorithms and neural networks

A gene is a heritable unit of biological information that influences an organism's traits and occupies a position on a chromosome.

How it is used
Connects inherited biological traits to the gene-and-chromosome representation used by genetic algorithms.
How deep it goes
Defines genes biologically and computationally, then demonstrates representations, but stops short of detailed molecular genetics.
Examples
Uses binary NumPy chromosomes and EvoLisa polygon genes containing coordinates, color, and transparency.
What you can do after
Apply genes by encoding traits as binary values, numeric arrays, or structured value groups for evolutionary optimization.

Read how Evolutionary Deep Learning: Genetic algorithms and neural networks explains gene →

Classic Computer Science Problems in Swift: Essential techniques for practicing programmers

Gene is a book-specific array-based representation of a nucleotide sequence as an ordered collection of codons.

How it is used
Represents nucleotide sequences for codon search and related algorithm exercises.
How deep it goes
Defines nucleotides, codons, array conversion, ordering, and searches without developing broader biological semantics.
Examples
Uses a nucleotide string, stringToGene(), an ACG codon, and linear or binary containment searches.
What you can do after
Build it from scratch as Swift enums, tuples, arrays, and a parser for codon sequences.

Read how Classic Computer Science Problems in Swift: Essential techniques for practicing programmers explains gene →

Grokking AI Algorithms, Second Edition

A gene is an individual value or position within an evolutionary algorithm chromosome that contributes to the encoded candidate solution.

How it is used
Represents one decision or value inside an evolutionary algorithm's encoded candidate solution.
How deep it goes
Explains gene structure, encoding, mutation, population creation, and fitness effects, while deferring nonbinary mechanisms to later treatment.
Examples
Uses binary Knapsack Problem chromosomes, a nine-gene word-selection exercise, mutation figures, and Python fitness and population code.
What you can do after
Build it from scratch by encoding decisions as genes, generating chromosomes, mutating values, and calculating fitness.

Read how Grokking AI Algorithms, Second Edition explains gene →

Optimization Algorithms: AI techniques for design, planning, and control problems

A gene is a segment of genetic material that encodes a specific biological property or functional product.

How it is used
Uses genes as building blocks for biological traits and as encoded parameters in genetic-algorithm candidate solutions.
How deep it goes
Explains genes through alleles, loci, genotypes, phenotypes, and encoding, stopping short of molecular mechanisms.
Examples
Illustrates genes with appetite, movement, feet, and skin traits, then applies them to binary ticket-price chromosomes.
What you can do after
Evaluate/understand how biological genes map to genetic-algorithm parameters and chromosomes with suitable encodings.

Read how Optimization Algorithms: AI techniques for design, planning, and control problems explains gene →

Related concepts

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.