PandA-2024.02
Data Structures | Macros | Functions | Variables
tiny_fixed.c File Reference
#include <stdio.h>
#include "fixedptc.c"
#include "tiny_fixed.h"
Include dependency graph for tiny_fixed.c:

Go to the source code of this file.

Data Structures

struct  photon
 

Macros

#define SHELL_MAX   101
 Tiny MCML benchmark. More...
 
#define NUMPHOTONS   16
 

Functions

fixedpt get_uniform_fixed (int *seed)
 
void processPhoton (int seed)
 
void process ()
 
int main ()
 

Variables

const fixedpt mu_a = 131072
 
const fixedpt mu_s = 1310720
 
const fixedpt microns_per_shell = 327680
 
const long photons = NUMPHOTONS
 
const fixedpt albedo = 59578
 
const fixedpt shells_per_mfp = 595782
 
fixedpt heat [SHELL_MAX] = {0}
 

Macro Definition Documentation

◆ NUMPHOTONS

#define NUMPHOTONS   16

Definition at line 7 of file tiny_fixed.c.

◆ SHELL_MAX

#define SHELL_MAX   101

Tiny MCML benchmark.

"Simulates light propagation from a point source in an infinite medium with isotropic scattering." Original source: http://omic.ogi.edu/software/mc

Definition at line 6 of file tiny_fixed.c.

Referenced by main(), and processPhoton().

Function Documentation

◆ get_uniform_fixed()

fixedpt get_uniform_fixed ( int *  seed)

Definition at line 25 of file tiny_fixed.c.

References k.

Referenced by processPhoton().

Here is the caller graph for this function:

◆ main()

int main ( void  )

Definition at line 125 of file tiny_fixed.c.

References heat, process(), SHELL_MAX, and sum.

Here is the call graph for this function:

◆ process()

void process ( )

Definition at line 105 of file tiny_fixed.c.

References max, offset, photons, processPhoton(), and seeds.

Referenced by main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ processPhoton()

void processPhoton ( int  seed)

Definition at line 53 of file tiny_fixed.c.

References albedo, fixedpt_div(), FIXEDPT_FBITS, fixedpt_ln(), fixedpt_mul(), FIXEDPT_ONE, fixedpt_sqrt(), get_uniform_fixed(), heat, test_panda::shell, SHELL_MAX, shells_per_mfp, photon::u, photon::v, photon::w, photon::weight, photon::x, photon::y, and photon::z.

Referenced by process().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ albedo

const fixedpt albedo = 59578

Definition at line 21 of file tiny_fixed.c.

Referenced by processPhoton().

◆ heat

fixedpt heat[SHELL_MAX] = {0}

Definition at line 23 of file tiny_fixed.c.

Referenced by main(), and processPhoton().

◆ microns_per_shell

const fixedpt microns_per_shell = 327680

Definition at line 18 of file tiny_fixed.c.

◆ mu_a

const fixedpt mu_a = 131072

Definition at line 16 of file tiny_fixed.c.

◆ mu_s

const fixedpt mu_s = 1310720

Definition at line 17 of file tiny_fixed.c.

◆ photons

const long photons = NUMPHOTONS

Definition at line 20 of file tiny_fixed.c.

Referenced by process().

◆ shells_per_mfp

const fixedpt shells_per_mfp = 595782

Definition at line 22 of file tiny_fixed.c.

Referenced by processPhoton().


Generated on Mon Feb 12 2024 13:03:09 for PandA-2024.02 by doxygen 1.8.13