Robert S. Laramee 1 Visualization, Lecture Flow visualization, Part 2 (of 3)

Slides:



Advertisements
Similar presentations
Example Project and Numerical Integration Computational Neuroscience 03 Lecture 11.
Advertisements

Formal Computational Skills
Vector Field Visualization Jian Huang, CS 594, Spring 2002 This set of slides reference slides developed by Prof. Torsten Moeller, at CS, Simon Fraser.
Arc-length computation and arc-length parameterization
Numerical Methods for Partial Differential Equations CAAM 452 Spring 2005 Lecture 9 Instructor: Tim Warburton.
QR Code Recognition Based On Image Processing
CS 282.  Any question about… ◦ SVN  Permissions?  General Usage? ◦ Doxygen  Remember that Project 1 will require it  However, Assignment 2 is good.
1 Higher Dimensional Vector Field Visualization: A Survey Zhenmin Peng, Robert S. Laramee Department of Computer Science Swansea University, Wales UK
An Information-Theoretic Framework for Flow Visualization Lijie Xu, Teng-Yok Lee, & Han-Wei Shen The Ohio State University.
Ordinary Differential Equations
CS774. Markov Random Field : Theory and Application Lecture 04 Kyomin Jung KAIST Sep
CS 128/ES Lecture 12b1 Spatial Analysis (3D)
Segmentation Divide the image into segments. Each segment:
Continuum Crowds Adrien Treuille, Siggraph 王上文.
19.5 Numeric Integration and Differentiation
1 CE 530 Molecular Simulation Lecture 7 David A. Kofke Department of Chemical Engineering SUNY Buffalo
Boyce/DiPrima 9th ed, Ch 8.4: Multistep Methods Elementary Differential Equations and Boundary Value Problems, 9th edition, by William E. Boyce and Richard.
1 Statistical Mechanics and Multi- Scale Simulation Methods ChBE Prof. C. Heath Turner Lecture 11 Some materials adapted from Prof. Keith E. Gubbins:
11/19/02 (c) 2002, University of Wisconsin, CS 559 Last Time Many, many modeling techniques –Polygon meshes –Parametric instancing –Hierarchical modeling.
Robert S. Laramee 1 Over Two Decades of Integration- Based, Geometric Vector Field Visualization.
Erin Catto Blizzard Entertainment Numerical Integration.
Lei Zhang and Guoning Chen, Department of Computer Science, University of Houston Robert S. Laramee, Swansea University David Thompson and Adrian Sescu,
CDS 301 Fall, 2009 Vector Visualization Chap. 6 October 7, 2009 Jie Zhang Copyright ©
Department of Electrical Engineering, Southern Taiwan University Robotic Interaction Learning Lab 1 The optimization of the application of fuzzy ant colony.
Robert S. Laramee 1 1 Flow Like You've Never Seen It Robert S. Laramee Visual and Interactive Computing.
Workshop on Stochastic Differential Equations and Statistical Inference for Markov Processes Day 3: Numerical Methods for Stochastic Differential.
Flow Visualization: The State-of-the-Art
Abj 3.1: Introduction to Motion and Velocity Field: Pathlines, Streamlines, and Streaklines Geometry of Motion Pathline Streamline No flow across a.
2D Flow Visualization streamline, pathline, hedges, spotnoise 郭翰琦 陈珩.
December 9, 2014Computer Vision Lecture 23: Motion Analysis 1 Now we will talk about… Motion Analysis.
Hank Childs, University of Oregon Lecture #6 CIS 410/510: Advection (Part 1)
Differential Equations Copyright © Cengage Learning. All rights reserved.
Numerical Methods.
Vector Field Visualization
Field Visualisation Jane Tinslay, SLAC October 2006.
Design and Implementation of Geometric and Texture-Based Flow Visualization Techniques Robert S. Laramee Markus Hadwiger Helwig Hauser.
1 Feature Extraction and Visualization of Flow Fields State-of-the-Art Report Feature Extraction and Visualization of Flow Fields Frits.
Robert S. Laramee 1 Flow Visualization: The State-of-the-Art Robert S. Laramee The Visual and Interactive.
Data Visualization Fall 2015.
Yanjmaa Jutmaan  Department of Applied mathematics Some mathematical models related to physics and biology.
Introduction to the Runge-Kutta algorithm for approximating derivatives PHYS 361 Spring, 2011.
ECE 576 – Power System Dynamics and Stability Prof. Tom Overbye Dept. of Electrical and Computer Engineering University of Illinois at Urbana-Champaign.
Lecture 39 Numerical Analysis. Chapter 7 Ordinary Differential Equations.
Introduction to Modeling Technology Enhanced Inquiry Based Science Education.
Announcements Topics: -Introduction to (review of) Differential Equations (Chapter 6) -Euler’s Method for Solving DEs (introduced in 6.1) -Analysis of.
Introduction to Parametric Curve and Surface Modeling.
Robert S. Laramee 1 1 Visualization, Lecture #3 Volume Visualization, Part 1 (of 4)
Robert S. Laramee 1 Visualization Lecture Flow visualization, An Introduction.
P2 Chapter 8 CIE Centre A-level Pure Maths © Adam Gibson.
Announcements Please read Chapters 11 and 12
Simplified Representation of Vector Fields
March 9th, 2015 Maxime Lapalme Nazim Ould-Brahim
From: Variational Integrators for Structure-Preserving Filtering
Farthest Point Seeding for Efficient Placement of Streamlines
ECE 576 – Power System Dynamics and Stability
2.9 Linear Approximations and Differentials
Using Flow Textures to Visualize Unsteady Vector Fields
Image Space Based Visualization of Unsteady Flow on Surfaces
Outline Peter N. Belhumeur, Joao P. Hespanha, and David J. Kriegman, “Eigenfaces vs. Fisherfaces: Recognition Using Class Specific Linear Projection,”
Class Notes 19: Numerical Methods (2/2)
Vector Field Visualization
Flow Like You've Never Seen It
Lecture 4 - Monte Carlo improvements via variance reduction techniques: antithetic sampling Antithetic variates: for any one path obtained by a gaussian.
Vector Field Visualization
ECE 576 POWER SYSTEM DYNAMICS AND STABILITY
Introduction to Parametric Curve and Surface Modeling
MATH 175: Numerical Analysis II
Romberg Rule of Integration
Chapter 4 . Trajectory planning and Inverse kinematics
Presentation transcript:

Robert S. Laramee 1 Visualization, Lecture Flow visualization, Part 2 (of 3)

Robert S. Laramee 2 Retrospect: Previous Lecture Flow Visualization, Part 1:  introduction, overview  simulation vs. measurement vs. modelling  2D vs. surfaces vs. 3D  steady vs time-dependent  direct vs. geometric FlowVis  experimental FlowVis  PIV + example  Vortices behind wing tips

Robert S. Laramee 3 Overview: Lecture Flow Visualization, Part 2:  direct FlowVis with arrows  numerical integration  Euler-integration  Runge-Kutta-integration  streamlines  in 2D  particle paths  in 3D, sweeps  illuminated streamlines  streamline placement

Robert S. Laramee 4 Direct Flow Visualization with Arrows Hedgehog plots, etc.

Robert S. Laramee 5 Direct FlowVis with Arrows Properties:  direct FlowVis  normalized arrows vs. velocity coding  2D: quite useful, 3D: often problematic  often difficult to understand, mentally integrate (time component missing)  frequently used!

Robert S. Laramee 6 Arrows in 2D Scaled arrows vs. color-coded arrows

Robert S. Laramee 7 Arrows in 3D Common problems:  ambiguity  perspective shortening  1D objects generally difficult to grasp in 3D Remedy:  3D-Arrows (are of some help )

Robert S. Laramee 8 Arrows in 3D Compromise: arrows only in layers

Robert S. Laramee 9 Arrows in 3D Combines well with other 3D vis.:

Robert S. Laramee 10 Integration of Streamlines Numerical Integration

Robert S. Laramee 11 Streamlines – Theory Correlations:  flow data v: derivative information  dx/dt = v(x); spatial points x  R n, Time t  R, flow vectors v  R n  streamline s: integration over time, also called trajectory, solution, curve  s(t) = s 0 +  0  u  t v(s(u)) du; seed point s 0, integration variable u  difficulty: result s also in the integral  analytical solution usually impossible.

Robert S. Laramee 12 Streamlines – Practice Basic approach:  theory: s(t) = s 0 +  0  u  t v(s(u)) du  practice: numerical integration  idea: (very) locally, the solution is (approx.) linear  Euler integration: follow the current flow vector v(s i ) from the current streamline point s i for a very small time (dt) and therefore distance Euler integration: s i+1 = s i + v(s i ) · dt, integration of small steps (dt very small)

Robert S. Laramee 13 Euler Integration – Example 2D model data: v x = dx/dt =  y v y = dy/dt = x/2 Sample arrows: True solution: ellipses

Robert S. Laramee 14 Euler Integration – Example  Seed point s 0 = ( 0 | -1 ) T ; current flow vector v(s 0 ) = ( 1 | 0 ) T ; dt = ½ v x = dx/dt =  y v y = dy/dt = x/

Robert S. Laramee 15 Euler Integration – Example  New point s 1 = s 0 + v(s 0 ) · dt = ( 1/2 | -1 ) T ; current flow vector v(s 1 ) = ( 1 | 1/4 ) T ; v x = dx/dt =  y v y = dy/dt = x/

Robert S. Laramee 16 Euler Integration – Example  New point s 2 = s 1 + v(s 1 ) · dt = ( 1 | -7/8 ) T ; current flow vector v(s 2 ) = ( 7/8 | 1/2 ) T ; v x = dx/dt =  y v y = dy/dt = x/

Robert S. Laramee 17 Euler Integration – Example  s 3 = ( 23/16 | -5/8 ) T  ( 1.44 | ) T ; v(s 3 )= ( 5/8 | 23/32 ) T  ( 0.63 | 0.72 ) T ; v x = dx/dt =  y v y = dy/dt = x/

Robert S. Laramee 18 Euler Integration – Example  s 4 = ( 7/4 | -17/64 ) T  ( 1.75 | ) T ; v(s 4 )= ( 17/64 | 7/8 ) T  ( 0.27 | 0.88 ) T ;

Robert S. Laramee 19 Euler Integration – Example  s 9  ( 0.20 | 1.69 ) T ; v(s 9 )  ( | 0.10 ) T ;

Robert S. Laramee 20 Euler Integration – Example  s 14  ( | ) T ; v(s 14 )  ( 0.10 | ) T ;

Robert S. Laramee 21 Euler Integration – Example  s 19  ( 0.75 | ) T ; v(s 19 )  ( 3.02 | 0.37 ) T ; clearly: large integration error, dt too large, 19 steps

Robert S. Laramee 22 Euler Integration – Example  dt smaller (1/4): more steps, more exact. s 36  ( 0.04 | ) T ; v(s 36 )  ( 1.74 | 0.02 ) T ;  36 steps

Robert S. Laramee 23 Comparison Euler, Step Sizes Euler quality is proportional to dt

Robert S. Laramee 24 Euler Example – Error Table dt#stepserror 1/219~200% 1/436~75% 1/1089~25% 1/100889~2% 1/ ~0.2%

Robert S. Laramee 25 Runge-Kutta Integration -Better than Euler Runge-Kutta Approach:  theory: s(t) = s 0 +  0  u  t v(s(u)) du  Euler:s i = s 0 +  0  u<i v(s u )  dt  Runge-Kutta integration:  idea: cut short the curve arc  RK-2 (second order RK): 1.: do half a Euler step 2.: evaluate (interpolate) flow vector there 3.: use it at the origin  RK-2 (two evaluations of v per step): s i+1 = s i + v(s i +v(s i )·dt / 2) · dt

Robert S. Laramee 26 RK-2 Integration – One Step  Seed point s 0 = ( 0 | -2 ) T ; current flow vector v(s 0 ) = ( 2 | 0 ) T ; preview vector v(s 0 +v(s 0 )·dt / 2) = (2|0.5) T ; dt = 1

Robert S. Laramee 27 RK-2 – One more step  Seed point s 1 = ( 2 | -1.5 ) T ; current flow vector v(s 1 ) = ( 1.5 | 1 ) T ; preview vector v(s 1 +v(s 1 )·dt / 2)  (1|1.4) T ; dt =

Robert S. Laramee 28 RK-2 – A Quick Round RK-2: even with dt = 1 (9 steps) better than Euler with dt = 1/8 (72 steps)

Robert S. Laramee 29 RK-4 vs. Euler, RK-2 Even better: fourth order RK:  four vectors a, b, c, d  one step is a convex combination: s i+1 = s i + (a + 2·b + 2·c + d)/6  vectors:  a = dt·v(s i )… original vector  b = dt·v(s i +a/2)… RK-2 vector  c = dt·v(s i +b/2)… use RK-2 …  d = dt·v(s i +c)… and again

Robert S. Laramee 30 Euler vs. Runge-Kutta RK-4: pays off only with complex flows Here approx. like RK-2

Robert S. Laramee 31 Integration, Conclusions Summary:  analytic determination of streamlines usually not possible  hence: numerical integration  various methods available (Euler, Runge-Kutta, etc.)  Euler: simple, imprecise, esp. with small dt  RK: more accurate in higher orders  furthermore: adaptive methods, implicit methods, etc.

Robert S. Laramee 32 Flow Visualization with Streamlines Streamlines, Particle Paths, etc.

Robert S. Laramee 33 Streamlines in 2D  Adequate for overview

Robert S. Laramee 34 Visualization with Particles Particle paths = streamlines (steady flows) Variants (time- dependent data):  streak lines: steadily new particles  path lines: long-term path of one particle click2demo (F9!)

Robert S. Laramee 35 Streamlines in 3D Color coding: Speed Selective Placement

Robert S. Laramee 36 Illuminated Streamlines Illuminated 3D curves  better 3D perception

Robert S. Laramee 37 Streamline Placement in 2D

Robert S. Laramee 38 Problem: Choice of Seed Points Streamline placement:  If regular grid used: very irregular result

Robert S. Laramee 39 Overview of Algorithm Idea: streamlines should not lie too close to one another Approach:  choose a seed point with distance d sep from an already existing streamline  forward- and backward-integration until distance d test is reached (or …).  two parameters:  d sep … start distance  d test … minimum distance

Robert S. Laramee 40 Algorithm – Pseudo-Code  Compute initial streamline, put it into a queue  current streamline = initial streamline  WHILE not finished DO: TRY: get new seed point which is d sep away from current streamline IF successful THEN compute new streamline AND put to queue ELSE IF no more streamline in queue THEN exit loop ELSE next streamline in queue becomes current streamline

Robert S. Laramee 41 Streamline Termination When to stop streamline integration:  when distance to neighboring streamline ≤ d test  when streamline leaves flow domain  when streamline runs into fixed point (v = 0)  when streamline gets too near to itself (loop)  after a certain amount of maximal steps

Robert S. Laramee 42 New Streamlines

Robert S. Laramee 43 Different Streamline Densities Variations of d sep relative to image width: 6% 3% 1.5%

Robert S. Laramee 44 d sep vs. d test d test = 0.9 · d sep d test = 0.5 · d sep

Robert S. Laramee 45 Tapering and Glyphs Thickness in relation to distance Directional glyphs:

Robert S. Laramee 46 Literature For more information, please see:  B. Jobard & W. Lefer: “Creating Evenly-Spaced Streamlines of Arbitrary Density” in Proceedings of 8th Eurographics Workshop on Visualization in Scientific Computing, April 1997, pp  Data Visualization: Principles and Practice, Chapter 6: Vector Visualization by A. Telea, AK Peters 2008 FlowVis Videos available on Bob's web page.

Robert S. Laramee 47 Acknowledgements We thank the following for material used in this lecture:  Bruno Jobard  Malte Zöckler  Georg Fischel  Frits H. Post  Roger Crawfis  Helwig Hauser