Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Flocking Simulation with Phoenix Channels
Search
Christian Bäuerlein
April 19, 2018
Programming
1
400
Flocking Simulation with Phoenix Channels
Code can be found here:
https://github.com/fabrik42/flocking_elixir
Christian Bäuerlein
April 19, 2018
Tweet
Share
More Decks by Christian Bäuerlein
See All by Christian Bäuerlein
Single File Ruby Programs @ RubyUnconf 2023
fabrik42
0
170
Single File Ruby Programs 2.0
fabrik42
1
210
Single File Ruby Programs
fabrik42
0
290
Agile Software Development for Software Developers
fabrik42
0
53
Phoenix Live View
fabrik42
0
620
Rails API-only considerations
fabrik42
0
380
Org-Mode
fabrik42
0
550
Cleaner, scalable views with object oriented components
fabrik42
0
370
Headless Browser Experiments
fabrik42
0
410
Other Decks in Programming
See All in Programming
Premier Disciplin for Micro Frontends Multi Version/ Framework Scenarios @OOP 2026, Munic
manfredsteyer
PRO
0
100
Vibe Coding - AI 驅動的軟體開發
mickyp100
0
180
AIで開発はどれくらい加速したのか?AIエージェントによるコード生成を、現場の評価と研究開発の評価の両面からdeep diveしてみる
daisuketakeda
1
2.5k
並行開発のためのコードレビュー
miyukiw
1
1.3k
AI時代の認知負荷との向き合い方
optfit
0
170
CSC307 Lecture 02
javiergs
PRO
1
780
OSSとなったswift-buildで Xcodeのビルドを差し替えられるため 自分でXcodeを直せる時代になっている ダイアモンド問題編
yimajo
3
630
Oxlintはいいぞ
yug1224
5
1.4k
AIと一緒にレガシーに向き合ってみた
nyafunta9858
0
270
OCaml 5でモダンな並列プログラミングを Enjoyしよう!
haochenx
0
150
ぼくの開発環境2026
yuzneri
0
250
「ブロックテーマでは再現できない」は本当か?
inc2734
0
1.1k
Featured
See All Featured
The Language of Interfaces
destraynor
162
26k
Gemini Prompt Engineering: Practical Techniques for Tangible AI Outcomes
mfonobong
2
280
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
61
52k
エンジニアに許された特別な時間の終わり
watany
106
230k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
650
WCS-LA-2024
lcolladotor
0
450
Rails Girls Zürich Keynote
gr2m
96
14k
A Modern Web Designer's Workflow
chriscoyier
698
190k
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
0
67
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
350
Building a Modern Day E-commerce SEO Strategy
aleyda
45
8.7k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
0
140
Transcript
Flocking Simulation with Phoenix Channels
Flocking Theory
None
Use case: Cinematic effects
Boid: One member of a flock
* Location
* Location * Perception Radius
* Location * Perception Radius * Velocity * Heading
You Need Three Behaviours
1. Cohesion
1. Cohesion
1. Cohesion
2. Alignment
2. Alignment
2. Alignment
3. Separation
3. Separation
3. Separation ! !
3. Separation ! !
* Cohesion * Alignment * Separation = Next move
Architecture
Phoenix BoidsChannel Receives Updates Changes Settings GenServer WorldStateUpdater Calling itself
30 times per second Simulation Calculates new positions per boid based on world state <canvas> Renderer Renders updated world state Socket Connection Receives Updates Changes Settings
Demo Time!
Read on! http://harry.me/blog/2011/02/17/neat-algorithms-flocking/ http://www.red3d.com/cwr/boids/