Skip to content

Commit

Permalink
Merge pull request #12 from nrc-cnrc/develop
Browse files Browse the repository at this point in the history
Merging develop branch into master
  • Loading branch information
ftessier committed Nov 26, 2015
2 parents 4eb37cf + 426170b commit 6999c9d
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 31 deletions.
3 changes: 3 additions & 0 deletions HEN_HOUSE/src/egsnrc.mortran
Original file line number Diff line number Diff line change
Expand Up @@ -1552,7 +1552,10 @@ $start_new_particle;

"Now done with multiple scattering,
"update energy and see if below cut
"below subtracts only energy deposited"
peie = peie - edep;
"below subtracts energy deposited + work due to E field"
"peie = peie - de;"
eie = peie;
e(np) = peie;

Expand Down
11 changes: 9 additions & 2 deletions HEN_HOUSE/src/emf_macros.mortran
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,8 @@ IF(EPERP2.NE.0.0)[EPERP=SQRT(EPERP2);TUSTEP=MIN(TUSTEP,$EMULMT/EPERP);]
;
" "
REPLACE {$SET-TUSTEP-ENERGY-CHANGE-EM-FIELD;} WITH {;
IF(EDOTU.NE.0.0) TUSTEP=MIN(TUSTEP,ABS($EMELMT*(1.+1./GAMMA0)/EDOTU));
IF(EDOTU.NE.0.0) TUSTEP=MIN(TUSTEP,ABS($EMELMT/((1.+1./GAMMA0)*EDOTU)));
"fixed, $EMELMT used to be multiplied by (1+1./GAMMA0)--BW"
}
;
" "
Expand Down Expand Up @@ -373,6 +374,11 @@ REPLACE {$GET-EM-FIELD(#,#,#,#,#);} WITH {;
REPLACE {$GET-POTENTIAL(#,#,#,#);} WITH {;{P1}=0.0;};
;

"potential in a constant E field--BW"
REPLACE {$GET-POTENTIAL(#,#,#,#);} WITH {;
{P1}=-GAMMA0*BETA20*RM*(EX0*{P2}+EY0*{P3}+EZ0*{P4});
}

"3.0*3.0/0.511 explanation "
"nT = 3.0 (this example) = Magnetic field strength in Tesla V.s/m**2 "
"3.0 = Speed of light, in m/s *10**8 "
Expand All @@ -393,7 +399,8 @@ REPLACE {$GET-POTENTIAL(#,#,#,#);} WITH {;{P1}=0.0;};
" which can be defined by input, EMH, July 2015 "
"***********************************************"
REPLACE {$GET-EM-FIELD(#,#,#,#,#);} WITH {;
fbtemp=-IQ(NP)/RM*10**6;
"fixed e-field normalization below--factor of 10^6 must be in denominator!--BW"
fbtemp=-IQ(NP)/(RM*10**6);
{P1}X0=ExIN*fbtemp;{P1}Y0=EyIN*fbtemp;{P1}Z0=EzIN*fbtemp;
fbtemp=3.0/0.511;
{P2}X0=BxIN*fbtemp;{P2}Y0=ByIN*fbtemp;{P2}Z0=BzIN*fbtemp;
Expand Down
59 changes: 30 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ sections, and the egs++ class library to model elaborate geometries and
particle sources.


## Documentation

The EGSnrc user manuals are available on the EGSnrc web page:
http://nrc-cnrc.github.io/EGSnrc/.


## Licence

EGSnrc is distributed as free software under the terms of the GNU Affero
Expand All @@ -20,13 +26,14 @@ before downloading the software. In practice, this licence imposes no
restriction on using EGSnrc. However, if you want to further convey
verbatim or modified versions of the code, or any work based on any
EGSnrc component (including any such work operated remotely over a
network), you must do so under the same licence terms. Contact us if you
wish to licence EGSnrc under different terms.
network), you must do so under the same licence terms. Please [Contact NRC]
(http://www.nrc-cnrc.gc.ca/eng/solutions/advisory/egsnrc_index.html)
if you wish to licence EGSnrc under different terms.


## Prerequisites

EGSnrc can be installed on computers running Linux, OSX or Windows
EGSnrc can be installed on computers running Linux, OS X or Windows
operating systems. As a general-purpose Monte Carlo toolkit, EGSnrc
provides source code and utilities to build and run your own
radiation transport simulation applications. To use EGSnrc
Expand All @@ -43,31 +50,25 @@ Please read the [installation instructions]
(https://github.com/nrc-cnrc/EGSnrc/wiki/Installation-overview) in the
wiki for more details about these software components.


## Installation

Installation involves downloading the EGSnrc source code, and then
configuring EGSnrc for your computer. The recommended way to obtain the
source code is to clone the EGSnrc repository on your computer using the
git revision control software, via the SSH clone URL:
configuring EGSnrc for your computer. We recommend using the `git`
revision control software to obtain the source code. The following shell
command will clone the EGSnrc repository to your current working
directory:
```bash
git clone git@github.com:nrc-cnrc/EGSnrc.git
git clone https://github.com/nrc-cnrc/EGSnrc.git
```

Once you have downloaded the source code, you must run a configuration
GUI or script to set up and compile EGSnrc software components for your
computer. Please read the full [installation instructions]
(https://github.com/nrc-cnrc/EGSnrc/wiki/Installation-overview) in the
wiki for more details on how to download and configure EGSnrc.


## Documentation

The EGSnrc user manuals in PDF format can be downloaded from the
[releases](https://github.com/nrc-cnrc/EGSnrc/releases) page. Download
the `EGSnrc-manuals.zip` archive, and unzip it. If you installed EGSnrc,
you may want to move the extracted PDF files to the
`EGSnrc/HEN_HOUSE/doc`
directory for convenience.
Alternatively, you can download a [zip archive]
(https://github.com/nrc-cnrc/EGSnrc/archive/master.zip) of the EGSnrc
directory. Once you have downloaded the source code, you need to run a
configuration GUI or script to set up and compile EGSnrc software
components for your computer. Please read the full [installation
instructions]
(https://github.com/nrc-cnrc/EGSnrc/wiki/Installation-overview) for more
details on how to download and configure EGSnrc.


## Issues
Expand All @@ -82,12 +83,12 @@ pertains to an error condition which is precise and reproducible.

## Contributing

Please contribute to the EGSnrc project by implementing new features,
creating new data sets, correcting errors, and improving documentation.
You can submit small corrections and contributions as issues in the
You can contribute to the EGSnrc project by implementing new features,
creating new data sets, correcting errors, or improving documentation.
Feel free to submit small corrections and contributions as issues in the
[issue tracker](https://github.com/nrc-cnrc/EGSnrc/issues). For more
extensive contributions, familiarize yourself with git and github, work
on your own EGSnrc project fork and submit your changes via a pull
request. Note that significant additions will require a transfer of
extensive contributions, familiarize yourself with git and github,
work on your own EGSnrc project fork and submit your changes via a pull
request. Note that significant contributions will require a transfer of
copyright to the National Research Council of Canada before they can be
merged into the EGSnrc distribution.

0 comments on commit 6999c9d

Please sign in to comment.