PhysSandbox
Mecânica clássicaOndas e somEletricidade e magnetismoÓptica e luzGravidade e órbitasLaboratóriosAulas
🌙Astronomia e o céu🌡️Termodinâmica🌍Biofísica, fluidos e geociências📐Visualização matemática🔧Engenharia🧪Química
PTENRUESFRDE

Simuladores relacionados

Continue com temas próximos desta categoria — ou todos os 53 em «Biofísica, fluidos e geociências».

Toda a categoria →
NovoUniversidade / pesquisa

Predador–presa: resposta funcional de Holling

Abrir o simulador

Lotka–Volterra e tipos I–III de Holling: saturação da caça, capacidade de suporte da presa, nuliclinas e ciclos limite.

NovoUniversidade / pesquisa

Colheita logística e rendimento máximo sustentável

Abrir o simulador

Crescimento logístico com extração constante: MSY = rK/4, estoque estável, limiar de colapso e trajetória do efetivo.

NovoUniversidade / pesquisa

Equilíbrio de Hardy–Weinberg

Abrir o simulador

Frequência do alelo p, genótipos p², 2pq, q²; seleção, mutações e trajetórias didáticas da deriva.

NovoEscola

Curva de retenção de água no solo

Abrir o simulador

Curva de van Genuchten θ(ψ), saturação efetiva S_e, condutividade de Mualem K(θ), capacidade de campo, ponto de murcha e água disponível para as plantas.

NovoUniversidade / pesquisa

Vento geostrófico e térmico

Abrir o simulador

Balanço entre o gradiente de pressão e a força de Coriolis: as isóbaras fixam o vento geostrófico; o gradiente meridional de temperatura dá o cisalhamento vertical entre 1000 e 300 hPa.

NovoUniversidade / pesquisa

Estabilidade de encosta infinita

Abrir o simulador

Fator de segurança do equilíbrio-limite para um escorregamento raso planar: ângulo da encosta, coesão, atrito, profundidade e pressão neutra da chuva.

PhysSandbox

Simuladores interativos de física, química e engenharia para alunos, professores e para quem tem curiosidade.

Física

  • Mecânica clássica
  • Ondas e som
  • Eletricidade e magnetismo

Ciência

  • Óptica e luz
  • Gravidade e órbitas
  • Astronomia e o céu

Mais

  • Termodinâmica
  • Biofísica, fluidos e geociências
  • Visualização matemática
  • Engenharia
  • Química

© 2026 PhysSandbox. Simuladores científicos interativos e gratuitos.

PrivacidadeTermosContato
Início/Biofísica, fluidos e geociências/Natural Selection: Beetles, Predators and Camouflage

Natural Selection: Beetles, Predators and Camouflage

Beetles with a colour trait on an adjustable background: predators eat high-contrast ones, survivors breed with mutation σ.

Environment

0.3
0.7

Population

0.03
120
2

Each generation has two phases: predators remove beetles with probability growing with the contrast between beetle and background, then survivors breed back to the carrying capacity; each offspring inherits its parent’s colour ± a random mutation. Changing population size restarts the run; the other sliders act live.

Atalhos de teclado

  • •Space / Enter — play / pause
  • •R — reset population

Grandezas medidas

Generation0
Mean colour0.500
Background colour0.30
|mean − background|0.200
Std. deviation σ_pop0.120
Survivors last generation120 / 120
Removed by predators0.0%

Sobre o modelo

This is an individual-based model of natural selection acting on one continuous, heritable trait. Each beetle carries a colour value c between 0 (light) and 1 (dark) and sits on a background of colour b. A generation has two phases. In the predation phase every beetle is removed with probability P = min(0.95, 1.5·s·|c − b|), where s is the predation strength: the greater the contrast with the background, the more likely a predator spots it. In the reproduction phase the survivors breed back to the carrying capacity N; each offspring copies a randomly chosen surviving parent and adds a Gaussian mutation with standard deviation σ. Nothing else is modelled: there are no sexes, no genes or alleles, no age structure, no predator population dynamics, and the background does not react to the beetles. The mean colour drifts toward b over roughly 15–30 generations and the spread narrows; a sudden change of background shows re-adaptation, and σ = 0 shows that without new variation selection eventually fixes a single colour. Because selection is random sampling, every run differs — compare several runs before drawing conclusions. For the same ideas expressed with discrete alleles and frequencies p and q, continue with the Hardy–Weinberg Population Genetics simulator (earth-life-fluids/hardy-weinberg-population-genetics).

Para quem: Middle- and high-school biology (grades 7–11) introducing adaptation, variation, heredity and natural selection with a visual, hands-on model.

Conceitos-chave

  • Natural selection
  • Variation
  • Heritability
  • Mutation
  • Camouflage
  • Selection pressure
  • Carrying capacity
  • Adaptation

Como funciona

A population of beetles carries a continuous colour trait from 0 (light) to 1 (dark) and lives on a background with its own colour. In each generation predators spot and remove beetles with probability proportional to the contrast |colour − background| times the predation strength; the survivors then reproduce until the population is back at the carrying capacity, with each offspring inheriting its parent’s colour plus a small random mutation σ. Over generations the mean colour of the population drifts toward the background — natural selection acting on heritable variation — and the histogram narrows. Flip the background suddenly and watch the population re-adapt; set σ = 0 and the variation is eventually lost altogether.

Fórmulas principais

P(eaten) = min(0.95, 1.5 · s · |c − b|) (s = predation strength, b = background)
c_offspring = clamp(c_parent + N(0, σ²), 0, 1)
mean c̄ = Σc/N, σ_pop = √(Σ(c − c̄)²/N)

Perguntas frequentes

Why does the population not become exactly the background colour?
Mutation keeps injecting new colours every generation, and predation is probabilistic, so a few mismatched beetles always survive by chance. The mean settles close to the background and fluctuates around it; the standard deviation stays near a balance between mutation adding spread and selection removing it.
What happens when the mutation σ is set to 0?
No new variation enters. Selection removes the most contrasting colours each generation while offspring are exact copies of their parents, so the colour range shrinks until every beetle is identical and the histogram collapses to one bar. The population is then "stuck" and cannot re-adapt if the background changes.
Do the beetles choose or change their colour to match the background?
No. An individual never changes colour during its life. Only the population changes, because beetles that happen to match survive and pass their colour to more offspring. That difference between individual change and population change is the heart of natural selection.
Why are two runs with identical settings different?
Which beetles get eaten and which mutations appear are random draws, as in a real population. Small populations show larger run-to-run differences; raise the population size to see the mean colour curve become smoother.