What is Monte Carlo Modeling*?

Similar documents
Monte-Carlo modeling used to simulate propagation of photons in a medium

2017 Summer Course on Optical Oceanography and Ocean Color Remote Sensing. Monte Carlo Simulation

Today. Participating media. Participating media. Rendering Algorithms: Participating Media and. Subsurface scattering

Physics 202, Lecture 23

Participating Media. Part I: participating media in general. Oskar Elek MFF UK Prague

The Spherical Harmonics Discrete Ordinate Method for Atmospheric Radiative Transfer

6-1 LECTURE #6: OPTICAL PROPERTIES OF SOLIDS. Basic question: How do solids interact with light? The answers are linked to:

The Rendering Equation. Computer Graphics CMU /15-662

Photon Maps. The photon map stores the lighting information on points or photons in 3D space ( on /near 2D surfaces)

At the interface between two materials, where light can be reflected or refracted. Within a material, where the light can be scattered or absorbed.

Quantifying the Dynamic Ocean Surface Using Underwater Radiometric Measurement

Light. Electromagnetic wave with wave-like nature Refraction Interference Diffraction

Geometrical Optics INTRODUCTION. Wave Fronts and Rays

Light: Geometric Optics

Monte-Carlo-Based Impulse Response Modeling for Underwater Wireless Optical Communication

Light. Form of Electromagnetic Energy Only part of Electromagnetic Spectrum that we can really see

MET 4410 Remote Sensing: Radar and Satellite Meteorology MET 5412 Remote Sensing in Meteorology. Lecture 9: Reflection and Refraction (Petty Ch4)

Retrieval of optical and microphysical properties of ocean constituents using polarimetric remote sensing

D&S Technical Note 09-2 D&S A Proposed Correction to Reflectance Measurements of Profiled Surfaces. Introduction

Monte Carlo simulations. Lesson FYSKJM4710 Eirik Malinen

Illumination Under Trees. Nelson Max University of Tokyo, and University of California, Davis

LIGHT. Speed of light Law of Reflection Refraction Snell s Law Mirrors Lenses

13. Brewster angle measurement

Monte Carlo simulations

Simulation of Diffuse Optical Tomography using COMSOL Multiphysics

Algebra Based Physics

Chapter 35. The Nature of Light and the Laws of Geometric Optics

Reading. Ray Tracing. Eye vs. light ray tracing. Geometric optics. Required:

Chapter 32 Light: Reflection and Refraction. Copyright 2009 Pearson Education, Inc.

Fiber Optic Communication Systems. Unit-03: Properties of Light.

Introduction. Experiment A: Snell s Law. Physics 1CL REFLECTION AND REFRACTION OF LIGHT Summer Session II 2010

Lecture 7 Notes: 07 / 11. Reflection and refraction

A Direct Simulation-Based Study of Radiance in a Dynamic Ocean

Research Metodelogy Prediction Model for Wave Scattering

EE119 Homework 3. Due Monday, February 16, 2009

Moscow-Bavarian Joint Advanced Student School 2006 / Medical Imaging Principles of Computerized Tomographic Imaging and Cone-Beam Reconstruction

Ray Optics. Lecture 23. Chapter 34. Physics II. Course website:

Lecture Ray Model of Light. Physics Help Q&A: tutor.leiacademy.org

Ocean Optics Inversion Algorithm

Reflection and Refraction of Light

Reflection and Shading

Optics. a- Before the beginning of the nineteenth century, light was considered to be a stream of particles.

Lecture 6 Introduction to Scattering

Wavefronts and Rays. When light or other electromagnetic waves interact with systems much larger than the wavelength, it s a good approximation to

Light: Geometric Optics

Reading. Ray Tracing. Eye vs. light ray tracing. Geometric optics. Required: Watt, sections , (handout) Further reading:

Physics 1502: Lecture 28 Today s Agenda

CHAPTER 4 RAY COMPUTATION. 4.1 Normal Computation

Monte Carlo Study of the Scattering Error of a Quartz Reflective Absorption Tube

COMPUTER SIMULATION TECHNIQUES FOR ACOUSTICAL DESIGN OF ROOMS - HOW TO TREAT REFLECTIONS IN SOUND FIELD SIMULATION

Phys 102 Lecture 17 Introduction to ray optics

specular diffuse reflection.

Chapter 36. Image Formation

2/1/10. Outline. The Radiance Equation. Light: Flux Equilibrium. Light: Radiant Power. Light: Equation. Radiance. Jan Kautz

Supplementary Figure 1 Optimum transmissive mask design for shaping an incident light to a desired

ABSTRACT. data in 3D form from samples in both reflection and transmission modes. The current

Electron Dose Kernels (EDK) for Secondary Particle Transport in Deterministic Simulations

Chapter 24. Wave Optics. Wave Optics. The wave nature of light is needed to explain various phenomena

by Hu, Chen and Lu OPDISM Optical Parameters Determined by Integrating Sphere Measurement Xin-Hua Hu, Cheng Chen, Jun Q. Lu

Physics 1C. Lecture 22A. "There are two ways of spreading light: to be the candle or the mirror that reflects it." --Edith Wharton

3/10/2019. Models of Light. Waves and wave fronts. Wave fronts and rays

Fig The light rays that exit the prism enter longitudinally into an astronomical telescope adjusted for infinite distance.

What is the Monte Carlo Method?

Solar Panel Irradiation Exposure efficiency of solar panels with shadow

Introduction to Light

A Survey of Modelling and Rendering of the Earth s Atmosphere

Monte Carlo Radiation Transfer

Lecture 24 EM waves Geometrical optics

Formulas of possible interest

Local Illumination. CMPT 361 Introduction to Computer Graphics Torsten Möller. Machiraju/Zhang/Möller

The Rendering Equation. Computer Graphics CMU /15-662, Fall 2016

INFOGR Computer Graphics. J. Bikker - April-July Lecture 10: Shading Models. Welcome!

NKS GammaUser

CPSC GLOBAL ILLUMINATION

Chapter 26 Geometrical Optics

Basics of treatment planning II

Part I The Basic Algorithm. Principles of Photon Mapping. A two-pass global illumination method Pass I Computing the photon map

Light: Geometric Optics (Chapter 23)

Phys102 Lecture 21/22 Light: Reflection and Refraction

Physics 10. Lecture 28A. "If Dracula can t see his reflection in the mirror, how come his hair is always so neatly combed?

1.6 Rough Surface Scattering Applications Computer Graphic Shading and Rendering

PURDUE UNIVERSITY GRADUATE SCHOOL Thesis/Dissertation Acceptance

MCRT on a 3D Cartesian Grid

Ray Tracing. Brian Curless CSEP 557 Fall 2016

Chapter 3 Geometric Optics

Instructions for the command prompt usage of the steady state Monte Carlo program for fluorescence propagation in a fiber-optic probe based setup

GPU Based Convolution/Superposition Dose Calculation

- Volume Rendering -

1. Particle Scattering. Cogito ergo sum, i.e. Je pense, donc je suis. - René Descartes

CS 5625 Lec 2: Shading Models

Engineered Diffusers Intensity vs Irradiance

Chapter 24. Wave Optics. Wave Optics. The wave nature of light is needed to explain various phenomena

Reflection models and radiometry Advanced Graphics

Modeling Custom Surface Roughness with LucidShape 2D Scatter Curve BSDF Material

1.Rayleigh and Mie scattering. 2.Phase functions. 4.Single and multiple scattering

Dispersion Polarization

- Volume Rendering -

Physics 4C Chapter 33: Electromagnetic Waves

Physics Midterm I

Chapter 33 cont. The Nature of Light and Propagation of Light (lecture 2) Dr. Armen Kocharian

Transcription:

What is Monte Carlo Modeling*? Monte Carlo Modeling is a statisitcal method used here to simulate radiative transfer by simulating photon (or more exactly light rays/beams) interaction with a medium. MC models can be built such that increasing complexity can be added as the model develops. *based partially on a ppt file found at: www.ece.utexas.edu/bell/montecarlo.ppt

Program Some steps and concepts needed to implement a Monte Carlo model of photon propagation in a medium: Random Number Generation Attenuation of beam in the medium Scattering of Photons Variable weight photon Index Mismatch of Boundary Layers Grid Structure Detector Inverse MC (from detector source)

Basic concepts: The fundamental principle : we can map any probability distribution to a uniform distribution from 0 to 1: x0 ξ = p( x) dx = P( x0) Example: the probability of a photon travel to a distance l (or an optical depth τ=cl) without an interaction is exp(-τ). ξ l = τ exp( τ ) dτ = 1 exp( τ ) = log(1 ξ ) = log( ξ ) l = log( ξ ) / c For a uniform medium: )

Random Number Generation The first step in building a Monte Carlo model is to have a method to create random numbers. In Matlab the function rand.m generates a uniform distribution of random numbers (r.n.) in (0,1). see: gen_rand.m Random number generators produce pseudo random numbers.

Essential Properties of a Random Number Generator* Repeatability -- the same sequence should be produced with the same initial iti values (or seed). This is vital itl for db debugging. Randomness -- should produce independent uniformly distributed random variables that pass all statistical tests for randomness. Long gperiod -- a pseudo-random number sequence uses finite precision arithmetic, so the sequence must repeat itself with a finite period. This period should be much longer than the amount of random numbers needed for the simulation. Insensitive to seeds -- period and randomness properties should not depend on the initial seeds. *http://www.npac.syr.edu/users/paulc/lectures/montecarlo/p_montecarlo.html

Concepts Test if r.n. is uniformly uniformly, i.e., equally distributed Generate 10,000 000 r.n. and divide the (0,1) axis into 20 equal intervals. Observe the frequency of occurrence of r.n. in each interval. The ideal mean value is 500. Observe the standard deviation. The standard deviation should be less than 36.

Std=18.05 Results

Attenuation of a Collimated The goal of this step is to figure out how photons are attenuated in the medium. Beam Attenuation coefficient is c with units m -1. Attenuation obeys Beer-Lambert- Bouguer s Law: L= L 0 e - cz, where z is the depth within the medium. Th b bili f i The probability of attenuation within the medium in the interval [z, z+ dz] is cdz, for dz<<1/c.

Concepts After moving a step, a photon is either absorbed, scattered or transmitted. However, to simplify the problem, we only consider absorption in this step, that is, no scattering occurs. Therefore, c =a =1 m -1 in this program. To simplify further, assume index matched boundary (n 1 =n 2 ), fixed step, and fixed weight photon. Index matching means that no reflection occurs at the boundary. Fixed step means that absorption only happens at the end of a fixed step Δz. In the following program, Δz=20 cm. Fixed weight photon means that a photon is treated as an integral particle. A photon cannot be partially absorbed.

Flow Chart New photon N=10,000? Yes Stop Move photon Δz New Position z=z+δz P(a)=exp(aΔz) < rand [0,1]? Yes Increase absorption Events by one No

Results Matlab program (code MC_abs.m): a=1; %absorption [m^-1]; dz=0.2; %depth interval; depths=[0:dz:20/a]; %depth discritization interval=zeros(1,length(depths)); for i=1:10000 k=1; while rand(1)>exp(a*dz) dz) k=k+1; end interval(k)=interval(k)+1; end bar(interval); hold on plot([1:1:40],dz*10000*exp(-a*[1:1:40]*dz)); hold off xlabel('depth interval') ylabel('# of photons absorbed')

A better algorithm New photon N=10,000? Yes Stop Random number [0-1] Absorption depth Increase absorption event at given interval Probability of absorption at depth between z and z+dz: exp(-az)x(1-exp(-adz)) We can map [0,1] to the depths photon reach: z(abs)= -ln(1-r.n)/a =-ln(r.n)/a A single calculation per photon. Code: MC_abs.m (2 nd part)

Scattering of Photons in medium photons are either absorbed, transmitted through the medium or reflected back from the medium. reflection We keep track of each photon and tally where all the photons terminate. Boundaries are index matched (can do it differently if needed). The step length of each photon is variable. Absorption bottom absorption or reflection

Concepts In this step we will simulate the scattering of a photon in the medium. Scattering is accomplished by accounting for the position and direction of each photon. If a photon exits the medium (z<0), it has been reflected. Determining which depends on the z position at the exit point. At this point the photon is terminated (could be reflected back). Termination of the photon can also occur due to absorption in the medium or bottom. Step length is no longer a fixed value. It is calculated ltd as: z = -log(r.n.)/c

Deflection Angle Deflection angle (θ) : When a photon is scattered it is deflected by this angle relative to its propagation direction: θ ( θ ') sin( θ ') b β dθ ' = 2ππ 0 r.n. F i i l VSF l k t bl d For empirical VSF use a lookup table and interpolation to save time on computations.

For certain idealized functions we have analytical expressions: For Rayleigh, Raman and Pure-water scattering 0 2 1 2 6 3 2 6 2 3 = + + + ξ μ μ f f f f f Where f=0.835 for pure water 0.55 for Raman at 490nm and 1 for Rayleigh scattering. μ is the only positive root for a given ξ. Henyey-Greenstein: + + = ξ μ g g g g g s 2 1 1 1 2 1 2 2 g g g Where g>0 is the asymmetry parameter Program: Single_photon.m

Azimuthal Angle Azimuthal angle (φ) : When deflected by the Deflection angle, it is also deflected with respect to the orthogonal plane of propagation. φ = 2* π * r.n.

Flow Chart initialize array new photon increment reflected count no move photon In bottom no In medium yes yes absorbed? no calculate new direction or reflection angle if reflected from bottom yes

Variable Weight Photons Now, as a photon encounters the medium it s weight is decremented. Once the weight is small enough the photon will either terminate or be re-energized. A threshold is set to determine if the weight is significantly small. A photon is only re-energize every 1/threshold h photons to keep the energy balanced. This concept is called roulette. if(r.n. < threshold) h weight = weight * 20; else weight = 0;

Plane-Parallel semi infinite scattering medium illuminated from above: c = 1; % attenuation coefficient (1/m) w0 = 0.8; % single-scattering albedo N = 1e5; % number of photons to trace ns = 100; % max number of scatters per photon E = 0; % initialize detector for i=1:n z = 0; % initial position depth muz = 1; % incident id light direction (collimated) w = 1; % initial photon weight for j=1:ns s = - log(rand)/c; % geometric path length z = z + muz*s; % move photon if (z<0) E=E+w; break, end % count photons leaving out top w=w*w0; % absorb fraction of photon packet muz= 1-2*rand; % isotopic scattering end end E = E/N % normalize result See program: semi-infinite.m

Index Mismatch at boundary In this step, the index-mismatched boundary p, y between air and water is taken into effect. When light enters water, the total reflectance R t should include both the specular reflection R sp and the remitted diffuse reflectance R d.

Develop a Grid Structuret To keep track of the locations at which photons are absorbed within the water. To accomplish this develop a two/three- dimensional array of bins corresponding to the depth/location of the photon. With each absorption event, the photon s weight will be added into the bin corresponding to the photon s current location.

Detection ti of photons Including a detector to detect the number of photons which enter the detector field of view. The detector is placed within the previously defined grid boundaries.

Detector Variables Detector position (Lateral distance from ray and the height above water) The detector radius The field of view of the detector (FOV)

Inverse Monte Carlo Use the principle of reciprocity: if a photon makes it from a to b, a photon can make it from b to a along the same path. Only simmulates photons that made it to the detector (as opposed to the whole medium).

Monte Carlo vs. other RT MC is the most flexible of all RT can accommodate any arrangement of source, receiver and medium properties. MC is simple to conceptualize. MC is slow. Need to simmulate millions of photons to reduce statistical error.

Monte Carlo Programming A tutorial to Monte Carlo methods: http://people.revoledu.com/kardi/tutorial/simulation/index.html List of tutorials: http://www.cooper.edu/engineering/chemechem/mmc/tutor.html Monte Carlo Simulation for Statistical Physics by Paul Coddington at Northeast Parallel Architectures Center at Syracuse University: An electronic book covering Monte Carlo programming in depth includes discussion on Monte Carlo methods, specific algorithms, and problems and subtleties in Monte Carlo programming. http://www.npac.syr.edu/users/paulc/lectures/montecarlo/p_montecarlo.html Radiative transfer codes and documentation can also be found at: Radiative transfer codes and documentation can also be found at: http://www-star.st-and.ac.uk/~kw25/research/montecarlo/montecarlo.html