diff --git a/css/font-awesome.css b/css/font-awesome.css new file mode 100644 index 0000000..4040b3c --- /dev/null +++ b/css/font-awesome.css @@ -0,0 +1,1672 @@ +/*! + * Font Awesome 4.2.0 by @davegandy - http://fontawesome.io - @fontawesome + * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) + */ +/* FONT PATH + * -------------------------- */ +@font-face { + font-family: 'FontAwesome'; + src: url('../fonts/fontawesome-webfont.eot?v=4.2.0'); + src: url('../fonts/fontawesome-webfont.eot?#iefix&v=4.2.0') format('embedded-opentype'), url('../fonts/fontawesome-webfont.woff?v=4.2.0') format('woff'), url('../fonts/fontawesome-webfont.ttf?v=4.2.0') format('truetype'), url('../fonts/fontawesome-webfont.svg?v=4.2.0#fontawesomeregular') format('svg'); + font-weight: normal; + font-style: normal; +} +.fa { + display: inline-block; + font: normal normal normal 14px/1 FontAwesome; + font-size: inherit; + text-rendering: auto; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} +/* makes the font 33% larger relative to the icon container */ +.fa-lg { + font-size: 1.33333333em; + line-height: 0.75em; + vertical-align: -15%; +} +.fa-2x { + font-size: 2em; +} +.fa-3x { + font-size: 3em; +} +.fa-4x { + font-size: 4em; +} +.fa-5x { + font-size: 5em; +} +.fa-fw { + width: 1.28571429em; + text-align: center; +} +.fa-ul { + padding-left: 0; + margin-left: 2.14285714em; + list-style-type: none; +} +.fa-ul > li { + position: relative; +} +.fa-li { + position: absolute; + left: -2.14285714em; + width: 2.14285714em; + top: 0.14285714em; + text-align: center; +} +.fa-li.fa-lg { + left: -1.85714286em; +} +.fa-border { + padding: .2em .25em .15em; + border: solid 0.08em #eeeeee; + border-radius: .1em; +} +.pull-right { + float: right; +} +.pull-left { + float: left; +} +.fa.pull-left { + margin-right: .3em; +} +.fa.pull-right { + margin-left: .3em; +} +.fa-spin { + -webkit-animation: fa-spin 2s infinite linear; + animation: fa-spin 2s infinite linear; +} +@-webkit-keyframes fa-spin { + 0% { + -webkit-transform: rotate(0deg); + transform: rotate(0deg); + } + 100% { + -webkit-transform: rotate(359deg); + transform: rotate(359deg); + } +} +@keyframes fa-spin { + 0% { + -webkit-transform: rotate(0deg); + transform: rotate(0deg); + } + 100% { + -webkit-transform: rotate(359deg); + transform: rotate(359deg); + } +} +.fa-rotate-90 { + filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=1); + -webkit-transform: rotate(90deg); + -ms-transform: rotate(90deg); + transform: rotate(90deg); +} +.fa-rotate-180 { + filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2); + -webkit-transform: rotate(180deg); + -ms-transform: rotate(180deg); + transform: rotate(180deg); +} +.fa-rotate-270 { + filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=3); + -webkit-transform: rotate(270deg); + -ms-transform: rotate(270deg); + transform: rotate(270deg); +} +.fa-flip-horizontal { + filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1); + -webkit-transform: scale(-1, 1); + -ms-transform: scale(-1, 1); + transform: scale(-1, 1); +} +.fa-flip-vertical { + filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1); + -webkit-transform: scale(1, -1); + -ms-transform: scale(1, -1); + transform: scale(1, -1); +} +:root .fa-rotate-90, +:root .fa-rotate-180, +:root .fa-rotate-270, +:root .fa-flip-horizontal, +:root .fa-flip-vertical { + filter: none; +} +.fa-stack { + position: relative; + display: inline-block; + width: 2em; + height: 2em; + line-height: 2em; + vertical-align: middle; +} +.fa-stack-1x, +.fa-stack-2x { + position: absolute; + left: 0; + width: 100%; + text-align: center; +} +.fa-stack-1x { + line-height: inherit; +} +.fa-stack-2x { + font-size: 2em; +} +.fa-inverse { + color: #ffffff; +} +/* Font Awesome uses the Unicode Private Use Area (PUA) to ensure screen + readers do not read off random characters that represent icons */ +.fa-glass:before { + content: "\f000"; +} +.fa-music:before { + content: "\f001"; +} +.fa-search:before { + content: "\f002"; +} +.fa-envelope-o:before { + content: "\f003"; +} +.fa-heart:before { + content: "\f004"; +} +.fa-star:before { + content: "\f005"; +} +.fa-star-o:before { + content: "\f006"; +} +.fa-user:before { + content: "\f007"; +} +.fa-film:before { + content: "\f008"; +} +.fa-th-large:before { + content: "\f009"; +} +.fa-th:before { + content: "\f00a"; +} +.fa-th-list:before { + content: "\f00b"; +} +.fa-check:before { + content: "\f00c"; +} +.fa-remove:before, +.fa-close:before, +.fa-times:before { + content: "\f00d"; +} +.fa-search-plus:before { + content: "\f00e"; +} +.fa-search-minus:before { + content: "\f010"; +} +.fa-power-off:before { + content: "\f011"; +} +.fa-signal:before { + content: "\f012"; +} +.fa-gear:before, +.fa-cog:before { + content: "\f013"; +} +.fa-trash-o:before { + content: "\f014"; +} +.fa-home:before { + content: "\f015"; +} +.fa-file-o:before { + content: "\f016"; +} +.fa-clock-o:before { + content: "\f017"; +} +.fa-road:before { + content: "\f018"; +} +.fa-download:before { + content: "\f019"; +} +.fa-arrow-circle-o-down:before { + content: "\f01a"; +} +.fa-arrow-circle-o-up:before { + content: "\f01b"; +} +.fa-inbox:before { + content: "\f01c"; +} +.fa-play-circle-o:before { + content: "\f01d"; +} +.fa-rotate-right:before, +.fa-repeat:before { + content: "\f01e"; +} +.fa-refresh:before { + content: "\f021"; +} +.fa-list-alt:before { + content: "\f022"; +} +.fa-lock:before { + content: "\f023"; +} +.fa-flag:before { + content: "\f024"; +} +.fa-headphones:before { + content: "\f025"; +} +.fa-volume-off:before { + content: "\f026"; +} +.fa-volume-down:before { + content: "\f027"; +} +.fa-volume-up:before { + content: "\f028"; +} +.fa-qrcode:before { + content: "\f029"; +} +.fa-barcode:before { + content: "\f02a"; +} +.fa-tag:before { + content: "\f02b"; +} +.fa-tags:before { + content: "\f02c"; +} +.fa-book:before { + content: "\f02d"; +} +.fa-bookmark:before { + content: "\f02e"; +} +.fa-print:before { + content: "\f02f"; +} +.fa-camera:before { + content: "\f030"; +} +.fa-font:before { + content: "\f031"; +} +.fa-bold:before { + content: "\f032"; +} +.fa-italic:before { + content: "\f033"; +} +.fa-text-height:before { + content: "\f034"; +} +.fa-text-width:before { + content: "\f035"; +} +.fa-align-left:before { + content: "\f036"; +} +.fa-align-center:before { + content: "\f037"; +} +.fa-align-right:before { + content: "\f038"; +} +.fa-align-justify:before { + content: "\f039"; +} +.fa-list:before { + content: "\f03a"; +} +.fa-dedent:before, +.fa-outdent:before { + content: "\f03b"; +} +.fa-indent:before { + content: "\f03c"; +} +.fa-video-camera:before { + content: "\f03d"; +} +.fa-photo:before, +.fa-image:before, +.fa-picture-o:before { + content: "\f03e"; +} +.fa-pencil:before { + content: "\f040"; +} +.fa-map-marker:before { + content: "\f041"; +} +.fa-adjust:before { + content: "\f042"; +} +.fa-tint:before { + content: "\f043"; +} +.fa-edit:before, +.fa-pencil-square-o:before { + content: "\f044"; +} +.fa-share-square-o:before { + content: "\f045"; +} +.fa-check-square-o:before { + content: "\f046"; +} +.fa-arrows:before { + content: "\f047"; +} +.fa-step-backward:before { + content: "\f048"; +} +.fa-fast-backward:before { + content: "\f049"; +} +.fa-backward:before { + content: "\f04a"; +} +.fa-play:before { + content: "\f04b"; +} +.fa-pause:before { + content: "\f04c"; +} +.fa-stop:before { + content: "\f04d"; +} +.fa-forward:before { + content: "\f04e"; +} +.fa-fast-forward:before { + content: "\f050"; +} +.fa-step-forward:before { + content: "\f051"; +} +.fa-eject:before { + content: "\f052"; +} +.fa-chevron-left:before { + content: "\f053"; +} +.fa-chevron-right:before { + content: "\f054"; +} +.fa-plus-circle:before { + content: "\f055"; +} +.fa-minus-circle:before { + content: "\f056"; +} +.fa-times-circle:before { + content: "\f057"; +} +.fa-check-circle:before { + content: "\f058"; +} +.fa-question-circle:before { + content: "\f059"; +} +.fa-info-circle:before { + content: "\f05a"; +} +.fa-crosshairs:before { + content: "\f05b"; +} +.fa-times-circle-o:before { + content: "\f05c"; +} +.fa-check-circle-o:before { + content: "\f05d"; +} +.fa-ban:before { + content: "\f05e"; +} +.fa-arrow-left:before { + content: "\f060"; +} +.fa-arrow-right:before { + content: "\f061"; +} +.fa-arrow-up:before { + content: "\f062"; +} +.fa-arrow-down:before { + content: "\f063"; +} +.fa-mail-forward:before, +.fa-share:before { + content: "\f064"; +} +.fa-expand:before { + content: "\f065"; +} +.fa-compress:before { + content: "\f066"; +} +.fa-plus:before { + content: "\f067"; +} +.fa-minus:before { + content: "\f068"; +} +.fa-asterisk:before { + content: "\f069"; +} +.fa-exclamation-circle:before { + content: "\f06a"; +} +.fa-gift:before { + content: "\f06b"; +} +.fa-leaf:before { + content: "\f06c"; +} +.fa-fire:before { + content: "\f06d"; +} +.fa-eye:before { + content: "\f06e"; +} +.fa-eye-slash:before { + content: "\f070"; +} +.fa-warning:before, +.fa-exclamation-triangle:before { + content: "\f071"; +} +.fa-plane:before { + content: "\f072"; +} +.fa-calendar:before { + content: "\f073"; +} +.fa-random:before { + content: "\f074"; +} +.fa-comment:before { + content: "\f075"; +} +.fa-magnet:before { + content: "\f076"; +} +.fa-chevron-up:before { + content: "\f077"; +} +.fa-chevron-down:before { + content: "\f078"; +} +.fa-retweet:before { + content: "\f079"; +} +.fa-shopping-cart:before { + content: "\f07a"; +} +.fa-folder:before { + content: "\f07b"; +} +.fa-folder-open:before { + content: "\f07c"; +} +.fa-arrows-v:before { + content: "\f07d"; +} +.fa-arrows-h:before { + content: "\f07e"; +} +.fa-bar-chart-o:before, +.fa-bar-chart:before { + content: "\f080"; +} +.fa-twitter-square:before { + content: "\f081"; +} +.fa-facebook-square:before { + content: "\f082"; +} +.fa-camera-retro:before { + content: "\f083"; +} +.fa-key:before { + content: "\f084"; +} +.fa-gears:before, +.fa-cogs:before { + content: "\f085"; +} +.fa-comments:before { + content: "\f086"; +} +.fa-thumbs-o-up:before { + content: "\f087"; +} +.fa-thumbs-o-down:before { + content: "\f088"; +} +.fa-star-half:before { + content: "\f089"; +} +.fa-heart-o:before { + content: "\f08a"; +} +.fa-sign-out:before { + content: "\f08b"; +} +.fa-linkedin-square:before { + content: "\f08c"; +} +.fa-thumb-tack:before { + content: "\f08d"; +} +.fa-external-link:before { + content: "\f08e"; +} +.fa-sign-in:before { + content: "\f090"; +} +.fa-trophy:before { + content: "\f091"; +} +.fa-github-square:before { + content: "\f092"; +} +.fa-upload:before { + content: "\f093"; +} +.fa-lemon-o:before { + content: "\f094"; +} +.fa-phone:before { + content: "\f095"; +} +.fa-square-o:before { + content: "\f096"; +} +.fa-bookmark-o:before { + content: "\f097"; +} +.fa-phone-square:before { + content: "\f098"; +} +.fa-twitter:before { + content: "\f099"; +} +.fa-facebook:before { + content: "\f09a"; +} +.fa-github:before { + content: "\f09b"; +} +.fa-unlock:before { + content: "\f09c"; +} +.fa-credit-card:before { + content: "\f09d"; +} +.fa-rss:before { + content: "\f09e"; +} +.fa-hdd-o:before { + content: "\f0a0"; +} +.fa-bullhorn:before { + content: "\f0a1"; +} +.fa-bell:before { + content: "\f0f3"; +} +.fa-certificate:before { + content: "\f0a3"; +} +.fa-hand-o-right:before { + content: "\f0a4"; +} +.fa-hand-o-left:before { + content: "\f0a5"; +} +.fa-hand-o-up:before { + content: "\f0a6"; +} +.fa-hand-o-down:before { + content: "\f0a7"; +} +.fa-arrow-circle-left:before { + content: "\f0a8"; +} +.fa-arrow-circle-right:before { + content: "\f0a9"; +} +.fa-arrow-circle-up:before { + content: "\f0aa"; +} +.fa-arrow-circle-down:before { + content: "\f0ab"; +} +.fa-globe:before { + content: "\f0ac"; +} +.fa-wrench:before { + content: "\f0ad"; +} +.fa-tasks:before { + content: "\f0ae"; +} +.fa-filter:before { + content: "\f0b0"; +} +.fa-briefcase:before { + content: "\f0b1"; +} +.fa-arrows-alt:before { + content: "\f0b2"; +} +.fa-group:before, +.fa-users:before { + content: "\f0c0"; +} +.fa-chain:before, +.fa-link:before { + content: "\f0c1"; +} +.fa-cloud:before { + content: "\f0c2"; +} +.fa-flask:before { + content: "\f0c3"; +} +.fa-cut:before, +.fa-scissors:before { + content: "\f0c4"; +} +.fa-copy:before, +.fa-files-o:before { + content: "\f0c5"; +} +.fa-paperclip:before { + content: "\f0c6"; +} +.fa-save:before, +.fa-floppy-o:before { + content: "\f0c7"; +} +.fa-square:before { + content: "\f0c8"; +} +.fa-navicon:before, +.fa-reorder:before, +.fa-bars:before { + content: "\f0c9"; +} +.fa-list-ul:before { + content: "\f0ca"; +} +.fa-list-ol:before { + content: "\f0cb"; +} +.fa-strikethrough:before { + content: "\f0cc"; +} +.fa-underline:before { + content: "\f0cd"; +} +.fa-table:before { + content: "\f0ce"; +} +.fa-magic:before { + content: "\f0d0"; +} +.fa-truck:before { + content: "\f0d1"; +} +.fa-pinterest:before { + content: "\f0d2"; +} +.fa-pinterest-square:before { + content: "\f0d3"; +} +.fa-google-plus-square:before { + content: "\f0d4"; +} +.fa-google-plus:before { + content: "\f0d5"; +} +.fa-money:before { + content: "\f0d6"; +} +.fa-caret-down:before { + content: "\f0d7"; +} +.fa-caret-up:before { + content: "\f0d8"; +} +.fa-caret-left:before { + content: "\f0d9"; +} +.fa-caret-right:before { + content: "\f0da"; +} +.fa-columns:before { + content: "\f0db"; +} +.fa-unsorted:before, +.fa-sort:before { + content: "\f0dc"; +} +.fa-sort-down:before, +.fa-sort-desc:before { + content: "\f0dd"; +} +.fa-sort-up:before, +.fa-sort-asc:before { + content: "\f0de"; +} +.fa-envelope:before { + content: "\f0e0"; +} +.fa-linkedin:before { + content: "\f0e1"; +} +.fa-rotate-left:before, +.fa-undo:before { + content: "\f0e2"; +} +.fa-legal:before, +.fa-gavel:before { + content: "\f0e3"; +} +.fa-dashboard:before, +.fa-tachometer:before { + content: "\f0e4"; +} +.fa-comment-o:before { + content: "\f0e5"; +} +.fa-comments-o:before { + content: "\f0e6"; +} +.fa-flash:before, +.fa-bolt:before { + content: "\f0e7"; +} +.fa-sitemap:before { + content: "\f0e8"; +} +.fa-umbrella:before { + content: "\f0e9"; +} +.fa-paste:before, +.fa-clipboard:before { + content: "\f0ea"; +} +.fa-lightbulb-o:before { + content: "\f0eb"; +} +.fa-exchange:before { + content: "\f0ec"; +} +.fa-cloud-download:before { + content: "\f0ed"; +} +.fa-cloud-upload:before { + content: "\f0ee"; +} +.fa-user-md:before { + content: "\f0f0"; +} +.fa-stethoscope:before { + content: "\f0f1"; +} +.fa-suitcase:before { + content: "\f0f2"; +} +.fa-bell-o:before { + content: "\f0a2"; +} +.fa-coffee:before { + content: "\f0f4"; +} +.fa-cutlery:before { + content: "\f0f5"; +} +.fa-file-text-o:before { + content: "\f0f6"; +} +.fa-building-o:before { + content: "\f0f7"; +} +.fa-hospital-o:before { + content: "\f0f8"; +} +.fa-ambulance:before { + content: "\f0f9"; +} +.fa-medkit:before { + content: "\f0fa"; +} +.fa-fighter-jet:before { + content: "\f0fb"; +} +.fa-beer:before { + content: "\f0fc"; +} +.fa-h-square:before { + content: "\f0fd"; +} +.fa-plus-square:before { + content: "\f0fe"; +} +.fa-angle-double-left:before { + content: "\f100"; +} +.fa-angle-double-right:before { + content: "\f101"; +} +.fa-angle-double-up:before { + content: "\f102"; +} +.fa-angle-double-down:before { + content: "\f103"; +} +.fa-angle-left:before { + content: "\f104"; +} +.fa-angle-right:before { + content: "\f105"; +} +.fa-angle-up:before { + content: "\f106"; +} +.fa-angle-down:before { + content: "\f107"; +} +.fa-desktop:before { + content: "\f108"; +} +.fa-laptop:before { + content: "\f109"; +} +.fa-tablet:before { + content: "\f10a"; +} +.fa-mobile-phone:before, +.fa-mobile:before { + content: "\f10b"; +} +.fa-circle-o:before { + content: "\f10c"; +} +.fa-quote-left:before { + content: "\f10d"; +} +.fa-quote-right:before { + content: "\f10e"; +} +.fa-spinner:before { + content: "\f110"; +} +.fa-circle:before { + content: "\f111"; +} +.fa-mail-reply:before, +.fa-reply:before { + content: "\f112"; +} +.fa-github-alt:before { + content: "\f113"; +} +.fa-folder-o:before { + content: "\f114"; +} +.fa-folder-open-o:before { + content: "\f115"; +} +.fa-smile-o:before { + content: "\f118"; +} +.fa-frown-o:before { + content: "\f119"; +} +.fa-meh-o:before { + content: "\f11a"; +} +.fa-gamepad:before { + content: "\f11b"; +} +.fa-keyboard-o:before { + content: "\f11c"; +} +.fa-flag-o:before { + content: "\f11d"; +} +.fa-flag-checkered:before { + content: "\f11e"; +} +.fa-terminal:before { + content: "\f120"; +} +.fa-code:before { + content: "\f121"; +} +.fa-mail-reply-all:before, +.fa-reply-all:before { + content: "\f122"; +} +.fa-star-half-empty:before, +.fa-star-half-full:before, +.fa-star-half-o:before { + content: "\f123"; +} +.fa-location-arrow:before { + content: "\f124"; +} +.fa-crop:before { + content: "\f125"; +} +.fa-code-fork:before { + content: "\f126"; +} +.fa-unlink:before, +.fa-chain-broken:before { + content: "\f127"; +} +.fa-question:before { + content: "\f128"; +} +.fa-info:before { + content: "\f129"; +} +.fa-exclamation:before { + content: "\f12a"; +} +.fa-superscript:before { + content: "\f12b"; +} +.fa-subscript:before { + content: "\f12c"; +} +.fa-eraser:before { + content: "\f12d"; +} +.fa-puzzle-piece:before { + content: "\f12e"; +} +.fa-microphone:before { + content: "\f130"; +} +.fa-microphone-slash:before { + content: "\f131"; +} +.fa-shield:before { + content: "\f132"; +} +.fa-calendar-o:before { + content: "\f133"; +} +.fa-fire-extinguisher:before { + content: "\f134"; +} +.fa-rocket:before { + content: "\f135"; +} +.fa-maxcdn:before { + content: "\f136"; +} +.fa-chevron-circle-left:before { + content: "\f137"; +} +.fa-chevron-circle-right:before { + content: "\f138"; +} +.fa-chevron-circle-up:before { + content: "\f139"; +} +.fa-chevron-circle-down:before { + content: "\f13a"; +} +.fa-html5:before { + content: "\f13b"; +} +.fa-css3:before { + content: "\f13c"; +} +.fa-anchor:before { + content: "\f13d"; +} +.fa-unlock-alt:before { + content: "\f13e"; +} +.fa-bullseye:before { + content: "\f140"; +} +.fa-ellipsis-h:before { + content: "\f141"; +} +.fa-ellipsis-v:before { + content: "\f142"; +} +.fa-rss-square:before { + content: "\f143"; +} +.fa-play-circle:before { + content: "\f144"; +} +.fa-ticket:before { + content: "\f145"; +} +.fa-minus-square:before { + content: "\f146"; +} +.fa-minus-square-o:before { + content: "\f147"; +} +.fa-level-up:before { + content: "\f148"; +} +.fa-level-down:before { + content: "\f149"; +} +.fa-check-square:before { + content: "\f14a"; +} +.fa-pencil-square:before { + content: "\f14b"; +} +.fa-external-link-square:before { + content: "\f14c"; +} +.fa-share-square:before { + content: "\f14d"; +} +.fa-compass:before { + content: "\f14e"; +} +.fa-toggle-down:before, +.fa-caret-square-o-down:before { + content: "\f150"; +} +.fa-toggle-up:before, +.fa-caret-square-o-up:before { + content: "\f151"; +} +.fa-toggle-right:before, +.fa-caret-square-o-right:before { + content: "\f152"; +} +.fa-euro:before, +.fa-eur:before { + content: "\f153"; +} +.fa-gbp:before { + content: "\f154"; +} +.fa-dollar:before, +.fa-usd:before { + content: "\f155"; +} +.fa-rupee:before, +.fa-inr:before { + content: "\f156"; +} +.fa-cny:before, +.fa-rmb:before, +.fa-yen:before, +.fa-jpy:before { + content: "\f157"; +} +.fa-ruble:before, +.fa-rouble:before, +.fa-rub:before { + content: "\f158"; +} +.fa-won:before, +.fa-krw:before { + content: "\f159"; +} +.fa-bitcoin:before, +.fa-btc:before { + content: "\f15a"; +} +.fa-file:before { + content: "\f15b"; +} +.fa-file-text:before { + content: "\f15c"; +} +.fa-sort-alpha-asc:before { + content: "\f15d"; +} +.fa-sort-alpha-desc:before { + content: "\f15e"; +} +.fa-sort-amount-asc:before { + content: "\f160"; +} +.fa-sort-amount-desc:before { + content: "\f161"; +} +.fa-sort-numeric-asc:before { + content: "\f162"; +} +.fa-sort-numeric-desc:before { + content: "\f163"; +} +.fa-thumbs-up:before { + content: "\f164"; +} +.fa-thumbs-down:before { + content: "\f165"; +} +.fa-youtube-square:before { + content: "\f166"; +} +.fa-youtube:before { + content: "\f167"; +} +.fa-xing:before { + content: "\f168"; +} +.fa-xing-square:before { + content: "\f169"; +} +.fa-youtube-play:before { + content: "\f16a"; +} +.fa-dropbox:before { + content: "\f16b"; +} +.fa-stack-overflow:before { + content: "\f16c"; +} +.fa-instagram:before { + content: "\f16d"; +} +.fa-flickr:before { + content: "\f16e"; +} +.fa-adn:before { + content: "\f170"; +} +.fa-bitbucket:before { + content: "\f171"; +} +.fa-bitbucket-square:before { + content: "\f172"; +} +.fa-tumblr:before { + content: "\f173"; +} +.fa-tumblr-square:before { + content: "\f174"; +} +.fa-long-arrow-down:before { + content: "\f175"; +} +.fa-long-arrow-up:before { + content: "\f176"; +} +.fa-long-arrow-left:before { + content: "\f177"; +} +.fa-long-arrow-right:before { + content: "\f178"; +} +.fa-apple:before { + content: "\f179"; +} +.fa-windows:before { + content: "\f17a"; +} +.fa-android:before { + content: "\f17b"; +} +.fa-linux:before { + content: "\f17c"; +} +.fa-dribbble:before { + content: "\f17d"; +} +.fa-skype:before { + content: "\f17e"; +} +.fa-foursquare:before { + content: "\f180"; +} +.fa-trello:before { + content: "\f181"; +} +.fa-female:before { + content: "\f182"; +} +.fa-male:before { + content: "\f183"; +} +.fa-gittip:before { + content: "\f184"; +} +.fa-sun-o:before { + content: "\f185"; +} +.fa-moon-o:before { + content: "\f186"; +} +.fa-archive:before { + content: "\f187"; +} +.fa-bug:before { + content: "\f188"; +} +.fa-vk:before { + content: "\f189"; +} +.fa-weibo:before { + content: "\f18a"; +} +.fa-renren:before { + content: "\f18b"; +} +.fa-pagelines:before { + content: "\f18c"; +} +.fa-stack-exchange:before { + content: "\f18d"; +} +.fa-arrow-circle-o-right:before { + content: "\f18e"; +} +.fa-arrow-circle-o-left:before { + content: "\f190"; +} +.fa-toggle-left:before, +.fa-caret-square-o-left:before { + content: "\f191"; +} +.fa-dot-circle-o:before { + content: "\f192"; +} +.fa-wheelchair:before { + content: "\f193"; +} +.fa-vimeo-square:before { + content: "\f194"; +} +.fa-turkish-lira:before, +.fa-try:before { + content: "\f195"; +} +.fa-plus-square-o:before { + content: "\f196"; +} +.fa-space-shuttle:before { + content: "\f197"; +} +.fa-slack:before { + content: "\f198"; +} +.fa-envelope-square:before { + content: "\f199"; +} +.fa-wordpress:before { + content: "\f19a"; +} +.fa-openid:before { + content: "\f19b"; +} +.fa-institution:before, +.fa-bank:before, +.fa-university:before { + content: "\f19c"; +} +.fa-mortar-board:before, +.fa-graduation-cap:before { + content: "\f19d"; +} +.fa-yahoo:before { + content: "\f19e"; +} +.fa-google:before { + content: "\f1a0"; +} +.fa-reddit:before { + content: "\f1a1"; +} +.fa-reddit-square:before { + content: "\f1a2"; +} +.fa-stumbleupon-circle:before { + content: "\f1a3"; +} +.fa-stumbleupon:before { + content: "\f1a4"; +} +.fa-delicious:before { + content: "\f1a5"; +} +.fa-digg:before { + content: "\f1a6"; +} +.fa-pied-piper:before { + content: "\f1a7"; +} +.fa-pied-piper-alt:before { + content: "\f1a8"; +} +.fa-drupal:before { + content: "\f1a9"; +} +.fa-joomla:before { + content: "\f1aa"; +} +.fa-language:before { + content: "\f1ab"; +} +.fa-fax:before { + content: "\f1ac"; +} +.fa-building:before { + content: "\f1ad"; +} +.fa-child:before { + content: "\f1ae"; +} +.fa-paw:before { + content: "\f1b0"; +} +.fa-spoon:before { + content: "\f1b1"; +} +.fa-cube:before { + content: "\f1b2"; +} +.fa-cubes:before { + content: "\f1b3"; +} +.fa-behance:before { + content: "\f1b4"; +} +.fa-behance-square:before { + content: "\f1b5"; +} +.fa-steam:before { + content: "\f1b6"; +} +.fa-steam-square:before { + content: "\f1b7"; +} +.fa-recycle:before { + content: "\f1b8"; +} +.fa-automobile:before, +.fa-car:before { + content: "\f1b9"; +} +.fa-cab:before, +.fa-taxi:before { + content: "\f1ba"; +} +.fa-tree:before { + content: "\f1bb"; +} +.fa-spotify:before { + content: "\f1bc"; +} +.fa-deviantart:before { + content: "\f1bd"; +} +.fa-soundcloud:before { + content: "\f1be"; +} +.fa-database:before { + content: "\f1c0"; +} +.fa-file-pdf-o:before { + content: "\f1c1"; +} +.fa-file-word-o:before { + content: "\f1c2"; +} +.fa-file-excel-o:before { + content: "\f1c3"; +} +.fa-file-powerpoint-o:before { + content: "\f1c4"; +} +.fa-file-photo-o:before, +.fa-file-picture-o:before, +.fa-file-image-o:before { + content: "\f1c5"; +} +.fa-file-zip-o:before, +.fa-file-archive-o:before { + content: "\f1c6"; +} +.fa-file-sound-o:before, +.fa-file-audio-o:before { + content: "\f1c7"; +} +.fa-file-movie-o:before, +.fa-file-video-o:before { + content: "\f1c8"; +} +.fa-file-code-o:before { + content: "\f1c9"; +} +.fa-vine:before { + content: "\f1ca"; +} +.fa-codepen:before { + content: "\f1cb"; +} +.fa-jsfiddle:before { + content: "\f1cc"; +} +.fa-life-bouy:before, +.fa-life-buoy:before, +.fa-life-saver:before, +.fa-support:before, +.fa-life-ring:before { + content: "\f1cd"; +} +.fa-circle-o-notch:before { + content: "\f1ce"; +} +.fa-ra:before, +.fa-rebel:before { + content: "\f1d0"; +} +.fa-ge:before, +.fa-empire:before { + content: "\f1d1"; +} +.fa-git-square:before { + content: "\f1d2"; +} +.fa-git:before { + content: "\f1d3"; +} +.fa-hacker-news:before { + content: "\f1d4"; +} +.fa-tencent-weibo:before { + content: "\f1d5"; +} +.fa-qq:before { + content: "\f1d6"; +} +.fa-wechat:before, +.fa-weixin:before { + content: "\f1d7"; +} +.fa-send:before, +.fa-paper-plane:before { + content: "\f1d8"; +} +.fa-send-o:before, +.fa-paper-plane-o:before { + content: "\f1d9"; +} +.fa-history:before { + content: "\f1da"; +} +.fa-circle-thin:before { + content: "\f1db"; +} +.fa-header:before { + content: "\f1dc"; +} +.fa-paragraph:before { + content: "\f1dd"; +} +.fa-sliders:before { + content: "\f1de"; +} +.fa-share-alt:before { + content: "\f1e0"; +} +.fa-share-alt-square:before { + content: "\f1e1"; +} +.fa-bomb:before { + content: "\f1e2"; +} +.fa-soccer-ball-o:before, +.fa-futbol-o:before { + content: "\f1e3"; +} +.fa-tty:before { + content: "\f1e4"; +} +.fa-binoculars:before { + content: "\f1e5"; +} +.fa-plug:before { + content: "\f1e6"; +} +.fa-slideshare:before { + content: "\f1e7"; +} +.fa-twitch:before { + content: "\f1e8"; +} +.fa-yelp:before { + content: "\f1e9"; +} +.fa-newspaper-o:before { + content: "\f1ea"; +} +.fa-wifi:before { + content: "\f1eb"; +} +.fa-calculator:before { + content: "\f1ec"; +} +.fa-paypal:before { + content: "\f1ed"; +} +.fa-google-wallet:before { + content: "\f1ee"; +} +.fa-cc-visa:before { + content: "\f1f0"; +} +.fa-cc-mastercard:before { + content: "\f1f1"; +} +.fa-cc-discover:before { + content: "\f1f2"; +} +.fa-cc-amex:before { + content: "\f1f3"; +} +.fa-cc-paypal:before { + content: "\f1f4"; +} +.fa-cc-stripe:before { + content: "\f1f5"; +} +.fa-bell-slash:before { + content: "\f1f6"; +} +.fa-bell-slash-o:before { + content: "\f1f7"; +} +.fa-trash:before { + content: "\f1f8"; +} +.fa-copyright:before { + content: "\f1f9"; +} +.fa-at:before { + content: "\f1fa"; +} +.fa-eyedropper:before { + content: "\f1fb"; +} +.fa-paint-brush:before { + content: "\f1fc"; +} +.fa-birthday-cake:before { + content: "\f1fd"; +} +.fa-area-chart:before { + content: "\f1fe"; +} +.fa-pie-chart:before { + content: "\f200"; +} +.fa-line-chart:before { + content: "\f201"; +} +.fa-lastfm:before { + content: "\f202"; +} +.fa-lastfm-square:before { + content: "\f203"; +} +.fa-toggle-off:before { + content: "\f204"; +} +.fa-toggle-on:before { + content: "\f205"; +} +.fa-bicycle:before { + content: "\f206"; +} +.fa-bus:before { + content: "\f207"; +} +.fa-ioxhost:before { + content: "\f208"; +} +.fa-angellist:before { + content: "\f209"; +} +.fa-cc:before { + content: "\f20a"; +} +.fa-shekel:before, +.fa-sheqel:before, +.fa-ils:before { + content: "\f20b"; +} +.fa-meanpath:before { + content: "\f20c"; +} diff --git a/css/font-awesome.min.css b/css/font-awesome.min.css new file mode 100644 index 0000000..ec53d4d --- /dev/null +++ b/css/font-awesome.min.css @@ -0,0 +1,4 @@ +/*! + * Font Awesome 4.2.0 by @davegandy - http://fontawesome.io - @fontawesome + * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) + */@font-face{font-family:'FontAwesome';src:url('../fonts/fontawesome-webfont.eot?v=4.2.0');src:url('../fonts/fontawesome-webfont.eot?#iefix&v=4.2.0') format('embedded-opentype'),url('../fonts/fontawesome-webfont.woff?v=4.2.0') format('woff'),url('../fonts/fontawesome-webfont.ttf?v=4.2.0') format('truetype'),url('../fonts/fontawesome-webfont.svg?v=4.2.0#fontawesomeregular') format('svg');font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{left:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=1);-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=3);-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1);-webkit-transform:scale(-1, 1);-ms-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1);-webkit-transform:scale(1, -1);-ms-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:"\f000"}.fa-music:before{content:"\f001"}.fa-search:before{content:"\f002"}.fa-envelope-o:before{content:"\f003"}.fa-heart:before{content:"\f004"}.fa-star:before{content:"\f005"}.fa-star-o:before{content:"\f006"}.fa-user:before{content:"\f007"}.fa-film:before{content:"\f008"}.fa-th-large:before{content:"\f009"}.fa-th:before{content:"\f00a"}.fa-th-list:before{content:"\f00b"}.fa-check:before{content:"\f00c"}.fa-remove:before,.fa-close:before,.fa-times:before{content:"\f00d"}.fa-search-plus:before{content:"\f00e"}.fa-search-minus:before{content:"\f010"}.fa-power-off:before{content:"\f011"}.fa-signal:before{content:"\f012"}.fa-gear:before,.fa-cog:before{content:"\f013"}.fa-trash-o:before{content:"\f014"}.fa-home:before{content:"\f015"}.fa-file-o:before{content:"\f016"}.fa-clock-o:before{content:"\f017"}.fa-road:before{content:"\f018"}.fa-download:before{content:"\f019"}.fa-arrow-circle-o-down:before{content:"\f01a"}.fa-arrow-circle-o-up:before{content:"\f01b"}.fa-inbox:before{content:"\f01c"}.fa-play-circle-o:before{content:"\f01d"}.fa-rotate-right:before,.fa-repeat:before{content:"\f01e"}.fa-refresh:before{content:"\f021"}.fa-list-alt:before{content:"\f022"}.fa-lock:before{content:"\f023"}.fa-flag:before{content:"\f024"}.fa-headphones:before{content:"\f025"}.fa-volume-off:before{content:"\f026"}.fa-volume-down:before{content:"\f027"}.fa-volume-up:before{content:"\f028"}.fa-qrcode:before{content:"\f029"}.fa-barcode:before{content:"\f02a"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-book:before{content:"\f02d"}.fa-bookmark:before{content:"\f02e"}.fa-print:before{content:"\f02f"}.fa-camera:before{content:"\f030"}.fa-font:before{content:"\f031"}.fa-bold:before{content:"\f032"}.fa-italic:before{content:"\f033"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-align-left:before{content:"\f036"}.fa-align-center:before{content:"\f037"}.fa-align-right:before{content:"\f038"}.fa-align-justify:before{content:"\f039"}.fa-list:before{content:"\f03a"}.fa-dedent:before,.fa-outdent:before{content:"\f03b"}.fa-indent:before{content:"\f03c"}.fa-video-camera:before{content:"\f03d"}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:"\f03e"}.fa-pencil:before{content:"\f040"}.fa-map-marker:before{content:"\f041"}.fa-adjust:before{content:"\f042"}.fa-tint:before{content:"\f043"}.fa-edit:before,.fa-pencil-square-o:before{content:"\f044"}.fa-share-square-o:before{content:"\f045"}.fa-check-square-o:before{content:"\f046"}.fa-arrows:before{content:"\f047"}.fa-step-backward:before{content:"\f048"}.fa-fast-backward:before{content:"\f049"}.fa-backward:before{content:"\f04a"}.fa-play:before{content:"\f04b"}.fa-pause:before{content:"\f04c"}.fa-stop:before{content:"\f04d"}.fa-forward:before{content:"\f04e"}.fa-fast-forward:before{content:"\f050"}.fa-step-forward:before{content:"\f051"}.fa-eject:before{content:"\f052"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-plus-circle:before{content:"\f055"}.fa-minus-circle:before{content:"\f056"}.fa-times-circle:before{content:"\f057"}.fa-check-circle:before{content:"\f058"}.fa-question-circle:before{content:"\f059"}.fa-info-circle:before{content:"\f05a"}.fa-crosshairs:before{content:"\f05b"}.fa-times-circle-o:before{content:"\f05c"}.fa-check-circle-o:before{content:"\f05d"}.fa-ban:before{content:"\f05e"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrow-down:before{content:"\f063"}.fa-mail-forward:before,.fa-share:before{content:"\f064"}.fa-expand:before{content:"\f065"}.fa-compress:before{content:"\f066"}.fa-plus:before{content:"\f067"}.fa-minus:before{content:"\f068"}.fa-asterisk:before{content:"\f069"}.fa-exclamation-circle:before{content:"\f06a"}.fa-gift:before{content:"\f06b"}.fa-leaf:before{content:"\f06c"}.fa-fire:before{content:"\f06d"}.fa-eye:before{content:"\f06e"}.fa-eye-slash:before{content:"\f070"}.fa-warning:before,.fa-exclamation-triangle:before{content:"\f071"}.fa-plane:before{content:"\f072"}.fa-calendar:before{content:"\f073"}.fa-random:before{content:"\f074"}.fa-comment:before{content:"\f075"}.fa-magnet:before{content:"\f076"}.fa-chevron-up:before{content:"\f077"}.fa-chevron-down:before{content:"\f078"}.fa-retweet:before{content:"\f079"}.fa-shopping-cart:before{content:"\f07a"}.fa-folder:before{content:"\f07b"}.fa-folder-open:before{content:"\f07c"}.fa-arrows-v:before{content:"\f07d"}.fa-arrows-h:before{content:"\f07e"}.fa-bar-chart-o:before,.fa-bar-chart:before{content:"\f080"}.fa-twitter-square:before{content:"\f081"}.fa-facebook-square:before{content:"\f082"}.fa-camera-retro:before{content:"\f083"}.fa-key:before{content:"\f084"}.fa-gears:before,.fa-cogs:before{content:"\f085"}.fa-comments:before{content:"\f086"}.fa-thumbs-o-up:before{content:"\f087"}.fa-thumbs-o-down:before{content:"\f088"}.fa-star-half:before{content:"\f089"}.fa-heart-o:before{content:"\f08a"}.fa-sign-out:before{content:"\f08b"}.fa-linkedin-square:before{content:"\f08c"}.fa-thumb-tack:before{content:"\f08d"}.fa-external-link:before{content:"\f08e"}.fa-sign-in:before{content:"\f090"}.fa-trophy:before{content:"\f091"}.fa-github-square:before{content:"\f092"}.fa-upload:before{content:"\f093"}.fa-lemon-o:before{content:"\f094"}.fa-phone:before{content:"\f095"}.fa-square-o:before{content:"\f096"}.fa-bookmark-o:before{content:"\f097"}.fa-phone-square:before{content:"\f098"}.fa-twitter:before{content:"\f099"}.fa-facebook:before{content:"\f09a"}.fa-github:before{content:"\f09b"}.fa-unlock:before{content:"\f09c"}.fa-credit-card:before{content:"\f09d"}.fa-rss:before{content:"\f09e"}.fa-hdd-o:before{content:"\f0a0"}.fa-bullhorn:before{content:"\f0a1"}.fa-bell:before{content:"\f0f3"}.fa-certificate:before{content:"\f0a3"}.fa-hand-o-right:before{content:"\f0a4"}.fa-hand-o-left:before{content:"\f0a5"}.fa-hand-o-up:before{content:"\f0a6"}.fa-hand-o-down:before{content:"\f0a7"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-globe:before{content:"\f0ac"}.fa-wrench:before{content:"\f0ad"}.fa-tasks:before{content:"\f0ae"}.fa-filter:before{content:"\f0b0"}.fa-briefcase:before{content:"\f0b1"}.fa-arrows-alt:before{content:"\f0b2"}.fa-group:before,.fa-users:before{content:"\f0c0"}.fa-chain:before,.fa-link:before{content:"\f0c1"}.fa-cloud:before{content:"\f0c2"}.fa-flask:before{content:"\f0c3"}.fa-cut:before,.fa-scissors:before{content:"\f0c4"}.fa-copy:before,.fa-files-o:before{content:"\f0c5"}.fa-paperclip:before{content:"\f0c6"}.fa-save:before,.fa-floppy-o:before{content:"\f0c7"}.fa-square:before{content:"\f0c8"}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:"\f0c9"}.fa-list-ul:before{content:"\f0ca"}.fa-list-ol:before{content:"\f0cb"}.fa-strikethrough:before{content:"\f0cc"}.fa-underline:before{content:"\f0cd"}.fa-table:before{content:"\f0ce"}.fa-magic:before{content:"\f0d0"}.fa-truck:before{content:"\f0d1"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-square:before{content:"\f0d3"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-plus:before{content:"\f0d5"}.fa-money:before{content:"\f0d6"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-up:before{content:"\f0d8"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-columns:before{content:"\f0db"}.fa-unsorted:before,.fa-sort:before{content:"\f0dc"}.fa-sort-down:before,.fa-sort-desc:before{content:"\f0dd"}.fa-sort-up:before,.fa-sort-asc:before{content:"\f0de"}.fa-envelope:before{content:"\f0e0"}.fa-linkedin:before{content:"\f0e1"}.fa-rotate-left:before,.fa-undo:before{content:"\f0e2"}.fa-legal:before,.fa-gavel:before{content:"\f0e3"}.fa-dashboard:before,.fa-tachometer:before{content:"\f0e4"}.fa-comment-o:before{content:"\f0e5"}.fa-comments-o:before{content:"\f0e6"}.fa-flash:before,.fa-bolt:before{content:"\f0e7"}.fa-sitemap:before{content:"\f0e8"}.fa-umbrella:before{content:"\f0e9"}.fa-paste:before,.fa-clipboard:before{content:"\f0ea"}.fa-lightbulb-o:before{content:"\f0eb"}.fa-exchange:before{content:"\f0ec"}.fa-cloud-download:before{content:"\f0ed"}.fa-cloud-upload:before{content:"\f0ee"}.fa-user-md:before{content:"\f0f0"}.fa-stethoscope:before{content:"\f0f1"}.fa-suitcase:before{content:"\f0f2"}.fa-bell-o:before{content:"\f0a2"}.fa-coffee:before{content:"\f0f4"}.fa-cutlery:before{content:"\f0f5"}.fa-file-text-o:before{content:"\f0f6"}.fa-building-o:before{content:"\f0f7"}.fa-hospital-o:before{content:"\f0f8"}.fa-ambulance:before{content:"\f0f9"}.fa-medkit:before{content:"\f0fa"}.fa-fighter-jet:before{content:"\f0fb"}.fa-beer:before{content:"\f0fc"}.fa-h-square:before{content:"\f0fd"}.fa-plus-square:before{content:"\f0fe"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angle-down:before{content:"\f107"}.fa-desktop:before{content:"\f108"}.fa-laptop:before{content:"\f109"}.fa-tablet:before{content:"\f10a"}.fa-mobile-phone:before,.fa-mobile:before{content:"\f10b"}.fa-circle-o:before{content:"\f10c"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-spinner:before{content:"\f110"}.fa-circle:before{content:"\f111"}.fa-mail-reply:before,.fa-reply:before{content:"\f112"}.fa-github-alt:before{content:"\f113"}.fa-folder-o:before{content:"\f114"}.fa-folder-open-o:before{content:"\f115"}.fa-smile-o:before{content:"\f118"}.fa-frown-o:before{content:"\f119"}.fa-meh-o:before{content:"\f11a"}.fa-gamepad:before{content:"\f11b"}.fa-keyboard-o:before{content:"\f11c"}.fa-flag-o:before{content:"\f11d"}.fa-flag-checkered:before{content:"\f11e"}.fa-terminal:before{content:"\f120"}.fa-code:before{content:"\f121"}.fa-mail-reply-all:before,.fa-reply-all:before{content:"\f122"}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:"\f123"}.fa-location-arrow:before{content:"\f124"}.fa-crop:before{content:"\f125"}.fa-code-fork:before{content:"\f126"}.fa-unlink:before,.fa-chain-broken:before{content:"\f127"}.fa-question:before{content:"\f128"}.fa-info:before{content:"\f129"}.fa-exclamation:before{content:"\f12a"}.fa-superscript:before{content:"\f12b"}.fa-subscript:before{content:"\f12c"}.fa-eraser:before{content:"\f12d"}.fa-puzzle-piece:before{content:"\f12e"}.fa-microphone:before{content:"\f130"}.fa-microphone-slash:before{content:"\f131"}.fa-shield:before{content:"\f132"}.fa-calendar-o:before{content:"\f133"}.fa-fire-extinguisher:before{content:"\f134"}.fa-rocket:before{content:"\f135"}.fa-maxcdn:before{content:"\f136"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-html5:before{content:"\f13b"}.fa-css3:before{content:"\f13c"}.fa-anchor:before{content:"\f13d"}.fa-unlock-alt:before{content:"\f13e"}.fa-bullseye:before{content:"\f140"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-rss-square:before{content:"\f143"}.fa-play-circle:before{content:"\f144"}.fa-ticket:before{content:"\f145"}.fa-minus-square:before{content:"\f146"}.fa-minus-square-o:before{content:"\f147"}.fa-level-up:before{content:"\f148"}.fa-level-down:before{content:"\f149"}.fa-check-square:before{content:"\f14a"}.fa-pencil-square:before{content:"\f14b"}.fa-external-link-square:before{content:"\f14c"}.fa-share-square:before{content:"\f14d"}.fa-compass:before{content:"\f14e"}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:"\f150"}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:"\f151"}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:"\f152"}.fa-euro:before,.fa-eur:before{content:"\f153"}.fa-gbp:before{content:"\f154"}.fa-dollar:before,.fa-usd:before{content:"\f155"}.fa-rupee:before,.fa-inr:before{content:"\f156"}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:"\f157"}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:"\f158"}.fa-won:before,.fa-krw:before{content:"\f159"}.fa-bitcoin:before,.fa-btc:before{content:"\f15a"}.fa-file:before{content:"\f15b"}.fa-file-text:before{content:"\f15c"}.fa-sort-alpha-asc:before{content:"\f15d"}.fa-sort-alpha-desc:before{content:"\f15e"}.fa-sort-amount-asc:before{content:"\f160"}.fa-sort-amount-desc:before{content:"\f161"}.fa-sort-numeric-asc:before{content:"\f162"}.fa-sort-numeric-desc:before{content:"\f163"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbs-down:before{content:"\f165"}.fa-youtube-square:before{content:"\f166"}.fa-youtube:before{content:"\f167"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-youtube-play:before{content:"\f16a"}.fa-dropbox:before{content:"\f16b"}.fa-stack-overflow:before{content:"\f16c"}.fa-instagram:before{content:"\f16d"}.fa-flickr:before{content:"\f16e"}.fa-adn:before{content:"\f170"}.fa-bitbucket:before{content:"\f171"}.fa-bitbucket-square:before{content:"\f172"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-long-arrow-down:before{content:"\f175"}.fa-long-arrow-up:before{content:"\f176"}.fa-long-arrow-left:before{content:"\f177"}.fa-long-arrow-right:before{content:"\f178"}.fa-apple:before{content:"\f179"}.fa-windows:before{content:"\f17a"}.fa-android:before{content:"\f17b"}.fa-linux:before{content:"\f17c"}.fa-dribbble:before{content:"\f17d"}.fa-skype:before{content:"\f17e"}.fa-foursquare:before{content:"\f180"}.fa-trello:before{content:"\f181"}.fa-female:before{content:"\f182"}.fa-male:before{content:"\f183"}.fa-gittip:before{content:"\f184"}.fa-sun-o:before{content:"\f185"}.fa-moon-o:before{content:"\f186"}.fa-archive:before{content:"\f187"}.fa-bug:before{content:"\f188"}.fa-vk:before{content:"\f189"}.fa-weibo:before{content:"\f18a"}.fa-renren:before{content:"\f18b"}.fa-pagelines:before{content:"\f18c"}.fa-stack-exchange:before{content:"\f18d"}.fa-arrow-circle-o-right:before{content:"\f18e"}.fa-arrow-circle-o-left:before{content:"\f190"}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:"\f191"}.fa-dot-circle-o:before{content:"\f192"}.fa-wheelchair:before{content:"\f193"}.fa-vimeo-square:before{content:"\f194"}.fa-turkish-lira:before,.fa-try:before{content:"\f195"}.fa-plus-square-o:before{content:"\f196"}.fa-space-shuttle:before{content:"\f197"}.fa-slack:before{content:"\f198"}.fa-envelope-square:before{content:"\f199"}.fa-wordpress:before{content:"\f19a"}.fa-openid:before{content:"\f19b"}.fa-institution:before,.fa-bank:before,.fa-university:before{content:"\f19c"}.fa-mortar-board:before,.fa-graduation-cap:before{content:"\f19d"}.fa-yahoo:before{content:"\f19e"}.fa-google:before{content:"\f1a0"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-square:before{content:"\f1a2"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-stumbleupon:before{content:"\f1a4"}.fa-delicious:before{content:"\f1a5"}.fa-digg:before{content:"\f1a6"}.fa-pied-piper:before{content:"\f1a7"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-drupal:before{content:"\f1a9"}.fa-joomla:before{content:"\f1aa"}.fa-language:before{content:"\f1ab"}.fa-fax:before{content:"\f1ac"}.fa-building:before{content:"\f1ad"}.fa-child:before{content:"\f1ae"}.fa-paw:before{content:"\f1b0"}.fa-spoon:before{content:"\f1b1"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-recycle:before{content:"\f1b8"}.fa-automobile:before,.fa-car:before{content:"\f1b9"}.fa-cab:before,.fa-taxi:before{content:"\f1ba"}.fa-tree:before{content:"\f1bb"}.fa-spotify:before{content:"\f1bc"}.fa-deviantart:before{content:"\f1bd"}.fa-soundcloud:before{content:"\f1be"}.fa-database:before{content:"\f1c0"}.fa-file-pdf-o:before{content:"\f1c1"}.fa-file-word-o:before{content:"\f1c2"}.fa-file-excel-o:before{content:"\f1c3"}.fa-file-powerpoint-o:before{content:"\f1c4"}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:"\f1c5"}.fa-file-zip-o:before,.fa-file-archive-o:before{content:"\f1c6"}.fa-file-sound-o:before,.fa-file-audio-o:before{content:"\f1c7"}.fa-file-movie-o:before,.fa-file-video-o:before{content:"\f1c8"}.fa-file-code-o:before{content:"\f1c9"}.fa-vine:before{content:"\f1ca"}.fa-codepen:before{content:"\f1cb"}.fa-jsfiddle:before{content:"\f1cc"}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:"\f1cd"}.fa-circle-o-notch:before{content:"\f1ce"}.fa-ra:before,.fa-rebel:before{content:"\f1d0"}.fa-ge:before,.fa-empire:before{content:"\f1d1"}.fa-git-square:before{content:"\f1d2"}.fa-git:before{content:"\f1d3"}.fa-hacker-news:before{content:"\f1d4"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-qq:before{content:"\f1d6"}.fa-wechat:before,.fa-weixin:before{content:"\f1d7"}.fa-send:before,.fa-paper-plane:before{content:"\f1d8"}.fa-send-o:before,.fa-paper-plane-o:before{content:"\f1d9"}.fa-history:before{content:"\f1da"}.fa-circle-thin:before{content:"\f1db"}.fa-header:before{content:"\f1dc"}.fa-paragraph:before{content:"\f1dd"}.fa-sliders:before{content:"\f1de"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-bomb:before{content:"\f1e2"}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:"\f1e3"}.fa-tty:before{content:"\f1e4"}.fa-binoculars:before{content:"\f1e5"}.fa-plug:before{content:"\f1e6"}.fa-slideshare:before{content:"\f1e7"}.fa-twitch:before{content:"\f1e8"}.fa-yelp:before{content:"\f1e9"}.fa-newspaper-o:before{content:"\f1ea"}.fa-wifi:before{content:"\f1eb"}.fa-calculator:before{content:"\f1ec"}.fa-paypal:before{content:"\f1ed"}.fa-google-wallet:before{content:"\f1ee"}.fa-cc-visa:before{content:"\f1f0"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-bell-slash:before{content:"\f1f6"}.fa-bell-slash-o:before{content:"\f1f7"}.fa-trash:before{content:"\f1f8"}.fa-copyright:before{content:"\f1f9"}.fa-at:before{content:"\f1fa"}.fa-eyedropper:before{content:"\f1fb"}.fa-paint-brush:before{content:"\f1fc"}.fa-birthday-cake:before{content:"\f1fd"}.fa-area-chart:before{content:"\f1fe"}.fa-pie-chart:before{content:"\f200"}.fa-line-chart:before{content:"\f201"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-bicycle:before{content:"\f206"}.fa-bus:before{content:"\f207"}.fa-ioxhost:before{content:"\f208"}.fa-angellist:before{content:"\f209"}.fa-cc:before{content:"\f20a"}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:"\f20b"}.fa-meanpath:before{content:"\f20c"} \ No newline at end of file diff --git a/css/local.css b/css/local.css new file mode 100644 index 0000000..f1a3262 --- /dev/null +++ b/css/local.css @@ -0,0 +1,298 @@ +body { + padding-top: 70px; +} +table.nostretch { + width=100% +} +.nostretch td { + class='block' +} +.nostretch tr td{ + width:1%; + white-space:nowrap; +} + +html { + scroll-padding-top: 70px; +} + +ol.hierarchy { + min-height: 40px; + background-color: #f5f5f5; + border: 1px solid #e3e3e3; + border-radius: 3px; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); +} + +.smallcaps { + font-variant: small-caps; +} +.well .sidebar { + padding: 8px 0 +} +.sidebar a { + padding: 0px,0px,0px,0px +} +.varlist>tbody>tr>td { + padding-left: 3px; + padding-right: 3px; +} +.varlist>tbody>tr>td:first-child, .varlist>thead>tr>td:first-child { + padding-left: 8px; +} +.varlist>tbody>td>td:last-child, .varlist>thead>tr>td:last-child { + padding-right: 8px; +} + +.highlight pre { + overflow-x: auto; + overflow-wrap: normal; + white-space: pre +} + +/* .hl is for when line numbers are included, .highlight is for all + other cases. */ +.hl pre { + counter-reset: line-numbering; + overflow-x: auto; + overflow-wrap: normal; + white-space: pre; + padding: 0; + padding-right: 9.5px; + overflow-y: hidden; + padding-bottom: 9.5px; +} + +.hl pre a::before { + content: counter(line-numbering); + counter-increment: line-numbering; + padding-right: 0.7em; /* space after numbers */ + margin-top: 4.5em; + width: 60px; + text-align: right; + opacity: 0.7; + display: inline-block; + color: #aaa; + background: #eee; + margin-right: 10px; + border-right: 1px solid #ccc; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.hl pre a:first-of-type::before { + padding-top: 9.5px; +} + +.hl pre a:last-of-type::before { + padding-bottom: 9.5px; +} + +.hl pre a:only-of-type::before { + padding: 9.5px; +} + +.hl pre a { + display: inline-block; + height: 4.5em; + margin: -4.5em 0 0; +} +.codesum h3 { + margin-top: 2px; + margin-bottom: 2px; +} + +h1.inline, h2.inline, h3.inline { + display: inline; +} + +.depwarn { + float: right; +} + +.anchor { + position: absolute; + margin: -4.5em; + visibility:hidden; +} + +.alert { + margin-left: 5px; + margin-right: 5px; + margin-top: 5px; +} + +.alert-title { + margin-top: 0; + color: inherit; +} + +div.toc { + font-size: 14.73px; + padding-left: 0px; + padding-right: 0px; +} + +div.toc a { + padding-left: 20px; + padding-right: 20px; + margin-right: 15px; + padding-top: 5px; + padding-bottom: 5px; +} + +div.toc li { + font-size: 0.95em; + padding-left: 15px; +} + +div.toc li.title { + font-size: 1em; +} + +div.toc hr { + margin-top: 12px; + margin-bottom: 10px; +} + +.in-well { + padding: 0px 0px; + margin-bottom: 0px; + float:right; +} + +table tr.submod>td { + border-top: none; + font-size: 13.5px; +} + +.graph-help { + font-size: 10px; +} + +.depgraph { + width: 100%; + max-width: 1140px; +} + +#sidebar a { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.highlighttable { + width: auto; + table-layout: fixed; +} + +ul.checklist { + list-style-type: none; +} + +ul.checklist input[type="checkbox"] { + margin-left: -20.8px; + margin-right: 4.55px; +} + +.gitter-chat-embed { + z-index: 100000; +} + +table.graph { + text-align: center; +} + + +.graph td.root { + border:2px solid black; + padding:10px; +} + +.graph td.triangle-right:after { + content: ""; + display: block; + border-top: 7px solid transparent; + border-bottom: 7px solid transparent; + border-left: 7px solid black; +} + +.graph td.triangle-left:after { + content: ""; + display: block; + border-top: 7px solid transparent; + border-bottom: 7px solid transparent; + border-right: 7px solid black; +} + +.graph td.node { + color: white; + padding:10px; + border-style: solid; + border-width: 3px 0px 3px 0px; + border-color: white; +} + +.graph td.node a{ + color: white; +} + +.graph td.dashedText, +.graph td.solidText { + padding: 0px 10px 0px 10px; + min-width: 40px; + color: black; + border-color: black; +} + +.graph td.dashedText { + border-bottom-style: dashed; +} + +.graph td.solidText { + border-bottom-style: solid; +} + +.graph td.dashedBottom, +.graph td.dashedTop, +.graph td.solidTop, +.graph td.solidBottom { + min-width: 40px; + color: transparent; + border-color: black; +} + +.graph td.dashedBottom { + border-bottom-style: dashed; +} + +.graph td.dashedTop { + border-top-style: dashed; +} + +.graph td.solidBottom { + border-bottom-style: solid; +} + +.graph td.solidTop { + border-top-style: solid; +} + +/* Ensure tables in Pages don't collapse horizontally */ +td, th { + padding-right: 10px; +} + +.nav>li>a { + padding-left: 10px; + padding-right: 10px; +} + +.nav > .nav { + margin-left: 16px; +} diff --git a/css/pygments.css b/css/pygments.css new file mode 100644 index 0000000..c4b2fd9 --- /dev/null +++ b/css/pygments.css @@ -0,0 +1,75 @@ +pre { line-height: 125%; } +td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } +span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } +td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } +span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } +.codehilite .hll { background-color: #ffffcc } +.codehilite { background: #f8f8f8; } +.codehilite .c { color: #3D7B7B; font-style: italic } /* Comment */ +.codehilite .err { border: 1px solid #FF0000 } /* Error */ +.codehilite .k { color: #008000; font-weight: bold } /* Keyword */ +.codehilite .o { color: #666666 } /* Operator */ +.codehilite .ch { color: #3D7B7B; font-style: italic } /* Comment.Hashbang */ +.codehilite .cm { color: #3D7B7B; font-style: italic } /* Comment.Multiline */ +.codehilite .cp { color: #9C6500 } /* Comment.Preproc */ +.codehilite .cpf { color: #3D7B7B; font-style: italic } /* Comment.PreprocFile */ +.codehilite .c1 { color: #3D7B7B; font-style: italic } /* Comment.Single */ +.codehilite .cs { color: #3D7B7B; font-style: italic } /* Comment.Special */ +.codehilite .gd { color: #A00000 } /* Generic.Deleted */ +.codehilite .ge { font-style: italic } /* Generic.Emph */ +.codehilite .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */ +.codehilite .gr { color: #E40000 } /* Generic.Error */ +.codehilite .gh { color: #000080; font-weight: bold } /* Generic.Heading */ +.codehilite .gi { color: #008400 } /* Generic.Inserted */ +.codehilite .go { color: #717171 } /* Generic.Output */ +.codehilite .gp { color: #000080; font-weight: bold } /* Generic.Prompt */ +.codehilite .gs { font-weight: bold } /* Generic.Strong */ +.codehilite .gu { color: #800080; font-weight: bold } /* Generic.Subheading */ +.codehilite .gt { color: #0044DD } /* Generic.Traceback */ +.codehilite .kc { color: #008000; font-weight: bold } /* Keyword.Constant */ +.codehilite .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */ +.codehilite .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */ +.codehilite .kp { color: #008000 } /* Keyword.Pseudo */ +.codehilite .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */ +.codehilite .kt { color: #B00040 } /* Keyword.Type */ +.codehilite .m { color: #666666 } /* Literal.Number */ +.codehilite .s { color: #BA2121 } /* Literal.String */ +.codehilite .na { color: #687822 } /* Name.Attribute */ +.codehilite .nb { color: #008000 } /* Name.Builtin */ +.codehilite .nc { color: #0000FF; font-weight: bold } /* Name.Class */ +.codehilite .no { color: #880000 } /* Name.Constant */ +.codehilite .nd { color: #AA22FF } /* Name.Decorator */ +.codehilite .ni { color: #717171; font-weight: bold } /* Name.Entity */ +.codehilite .ne { color: #CB3F38; font-weight: bold } /* Name.Exception */ +.codehilite .nf { color: #0000FF } /* Name.Function */ +.codehilite .nl { color: #767600 } /* Name.Label */ +.codehilite .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */ +.codehilite .nt { color: #008000; font-weight: bold } /* Name.Tag */ +.codehilite .nv { color: #19177C } /* Name.Variable */ +.codehilite .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */ +.codehilite .w { color: #bbbbbb } /* Text.Whitespace */ +.codehilite .mb { color: #666666 } /* Literal.Number.Bin */ +.codehilite .mf { color: #666666 } /* Literal.Number.Float */ +.codehilite .mh { color: #666666 } /* Literal.Number.Hex */ +.codehilite .mi { color: #666666 } /* Literal.Number.Integer */ +.codehilite .mo { color: #666666 } /* Literal.Number.Oct */ +.codehilite .sa { color: #BA2121 } /* Literal.String.Affix */ +.codehilite .sb { color: #BA2121 } /* Literal.String.Backtick */ +.codehilite .sc { color: #BA2121 } /* Literal.String.Char */ +.codehilite .dl { color: #BA2121 } /* Literal.String.Delimiter */ +.codehilite .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */ +.codehilite .s2 { color: #BA2121 } /* Literal.String.Double */ +.codehilite .se { color: #AA5D1F; font-weight: bold } /* Literal.String.Escape */ +.codehilite .sh { color: #BA2121 } /* Literal.String.Heredoc */ +.codehilite .si { color: #A45A77; font-weight: bold } /* Literal.String.Interpol */ +.codehilite .sx { color: #008000 } /* Literal.String.Other */ +.codehilite .sr { color: #A45A77 } /* Literal.String.Regex */ +.codehilite .s1 { color: #BA2121 } /* Literal.String.Single */ +.codehilite .ss { color: #19177C } /* Literal.String.Symbol */ +.codehilite .bp { color: #008000 } /* Name.Builtin.Pseudo */ +.codehilite .fm { color: #0000FF } /* Name.Function.Magic */ +.codehilite .vc { color: #19177C } /* Name.Variable.Class */ +.codehilite .vg { color: #19177C } /* Name.Variable.Global */ +.codehilite .vi { color: #19177C } /* Name.Variable.Instance */ +.codehilite .vm { color: #19177C } /* Name.Variable.Magic */ +.codehilite .il { color: #666666 } /* Literal.Number.Integer.Long */ diff --git a/favicon.png b/favicon.png new file mode 100644 index 0000000..4d6ad16 Binary files /dev/null and b/favicon.png differ diff --git a/fonts/FontAwesome.otf b/fonts/FontAwesome.otf new file mode 100644 index 0000000..81c9ad9 Binary files /dev/null and b/fonts/FontAwesome.otf differ diff --git a/fonts/fontawesome-webfont.eot b/fonts/fontawesome-webfont.eot new file mode 100644 index 0000000..84677bc Binary files /dev/null and b/fonts/fontawesome-webfont.eot differ diff --git a/fonts/fontawesome-webfont.svg b/fonts/fontawesome-webfont.svg new file mode 100644 index 0000000..d907b25 --- /dev/null +++ b/fonts/fontawesome-webfont.svg @@ -0,0 +1,520 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/fonts/fontawesome-webfont.ttf b/fonts/fontawesome-webfont.ttf new file mode 100644 index 0000000..96a3639 Binary files /dev/null and b/fonts/fontawesome-webfont.ttf differ diff --git a/fonts/fontawesome-webfont.woff b/fonts/fontawesome-webfont.woff new file mode 100644 index 0000000..628b6a5 Binary files /dev/null and b/fonts/fontawesome-webfont.woff differ diff --git a/fonts/glyphicons-halflings-regular.eot b/fonts/glyphicons-halflings-regular.eot new file mode 100644 index 0000000..4a4ca86 Binary files /dev/null and b/fonts/glyphicons-halflings-regular.eot differ diff --git a/fonts/glyphicons-halflings-regular.svg b/fonts/glyphicons-halflings-regular.svg new file mode 100644 index 0000000..25691af --- /dev/null +++ b/fonts/glyphicons-halflings-regular.svg @@ -0,0 +1,229 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/fonts/glyphicons-halflings-regular.ttf b/fonts/glyphicons-halflings-regular.ttf new file mode 100644 index 0000000..67fa00b Binary files /dev/null and b/fonts/glyphicons-halflings-regular.ttf differ diff --git a/fonts/glyphicons-halflings-regular.woff b/fonts/glyphicons-halflings-regular.woff new file mode 100644 index 0000000..8c54182 Binary files /dev/null and b/fonts/glyphicons-halflings-regular.woff differ diff --git a/index.html b/index.html new file mode 100644 index 0000000..813218c --- /dev/null +++ b/index.html @@ -0,0 +1,292 @@ + + + + + + + + + + + radbelt + + + + + + + + + + + + + + +
+ +
+ +
+ +
+

radbelt

+

Find us on…

+

+ GitHub +

+
+ +
+
+

radbelt

+

Radbelt: Work in progress to refactor the AE-8/AP-8 Van Allen belt model.

+

Status

+

Language +GitHub release +CI Status +codecov +last-commit

+

Compiling

+

A Fortran Package Manager manifest file is included, so that the library and test cases can be compiled with FPM. For example:

+
fpm build --profile release
+fpm test --profile release
+
+ +

To use radbelt within your fpm project, add the following to your fpm.toml file:

+
[dependencies]
+radbelt = { git="https://github.com/jacobwilliams/radbelt.git" }
+
+ +

Documentation

+

The latest API documentation can be found here. This was generated from the source code using FORD.

+

See also

+ +

Original Readme

+

National Space Science Data Center Data set PT-11B Mar 1996

+
NSSDC-Id     PT-11B (combines PT-11A, MT-18A, MT-18B, MT-2AA, MT-2AB)
+
+NAME:        Models of trapped particle fluxes AE-8 (electrons) and
+         AP-8 (protons) in inner and outer radiation belts
+
+SOURCE:      Dieter Bilitza, GSFC/NSSDC code 633, Greenbelt,
+             MD 20771, tel. (301) 286-0190
+             dbilitza@pop600.gsfc.nasa.gov
+
+CONTENT:     12 files                         *.*   blocks
+            FORTRAN source code:
+         driver program with interface              RADBELT.FOR   48
+             subroutines, functions              TRMFUN.FOR   30
+
+        model tables binary and ASCII:
+             AE-8, epoch 1964, solar minimum         AE8MIN.BIN  104
+         AE-8, epoch 1970, solar maximum             AE8MAX.BIN  107
+         AP-8, epoch 1964, solar minimum         AP8MIN.BIN   53
+         AP-8, epoch 1970, solar maximum         AP8MAX.BIN   52
+             ASCII version of AE8MIN.BIN                 AE8MIN.ASC  163
+             ASCII version of AE8MAX.BIN                 AE8MAX.ASC  168
+             ASCII version of AP8MIN.BIN                 AP8MIN.BIN   83
+             ASCII version of AP8MAX.BIN                 AP8MAX.BIN   81
+
+         user manual with examples          RADBELT.LOG   48
+             This file                                AAAREADME.DOC    9
+
+ +

BRIEF DESCRIPTION:

+

These empirical models describe the differential or +integral, omnidirectional fluxes of electrons (AE-8) and protons +(AP-8) in the inner and outer radiation belts (electrons: L=1.1 +to 11, protons: L=1.1 to 7) for two epochs representing solar +maximum (1970) and minimum (1964) conditions. The energy spectrum +ranges from 0.1 to 400 MeV for the protons and from 0.04 to 7 MeV +for the electrons. AE-8 and AP-8 are the most recent ones in a +series of models established by J. Vette and his colleges at NSSDC +starting in the early sixties. The models are based on almost all +available satellite data. It is IMPORTANT that the models maps for +solar maximum are used with a magnetic field model for epoch=1970 +and for solar minimum for epoch=1964.

+

For each epoch and particle the model consists of a three- +dimensional table of (logarithm of) particle fluxes in energy, L-value, +and B/B0 (magnetic field strength normalized to the equator). The program +MODEL finds the particle fluxes for given energy, L-value and B/B0 by +interpolating in energy (subroutine TRARA1) and in L * B/B0 space (TRARA2). +The program RADBELT produces tables of integral or differential fluxes +for different energies varying with L or B/B0.

+

The coefficient files are provided in VAX/VMS binary (.bin) and +ASCII (.asc) format. For all systems other than VMS the use of the ASCII +files is recommended. If using the ASCII coefficient one needs to slightly +modify the RADBELT.FOR program as described in a comment statement in +RADBELT (this comments are found after the OPEN statement for the coefficient +file).

+

In March 1995 the earlier used compressed model maps AP8MIC and AP8MAC +were replaced with the full maps AP8MIN/MAX with the help of D. Heynderickx +(BIRA, Brussel, Belgium) and A. Beliaev (INP/MSU, Moscow, Russia). Heynderickx +and Beliaev (1995) had found and corrected a small error in the AP8MIN map; +two lines had been exchanged.

+

AVAILABILITY:

+

(1) FORTRAN source code from this directory. +(2) Model parameters can be computed and plotted online at http://nssdc.gsfc.nasa.gov/space/model/ .

+

REFERENCES:

+

G.W. Singley, and J.I. Vette, The AE-4 Model of the Outer Radiation + Zone Electron Environment, NSSDC/WDC-A-R&S 72-06, 1972.

+

M.J. Teague, and J.I. Vette, A Model of the Trapped Electron + Population for Solar Minimum (AE-5), NSSDC/WDC-A-R&S 74-03, 1974.

+

M.J. Teague, K.W. Chan, and J.I. Vette, AE-6: A Model Environment + of Trapped Electrons for Solar Maximum, NSSDC/WDC-A-R&S 76-04, 1976

+

D.W. Sawyer, and J.I. Vette, AP-8 Trapped Proton Environment for + Solar Maximum and Minimum, NSSDC/WDC-A-R&S 76-06, 1976.

+

J.I. Vette, K.W. Chan, and M.J. Teague, Problems in Modeling the + Earth's Trapped Radiation Environment, AFGL-TR-78-0130, 1978.

+

K.W. Chan, M.J. Teague, N.J. Schofield, and J.I. Vette, Modeling of + Electron Time Variation in the Radiation Belts, p. 121-149, in: + Quantitative Modeling of Magnetospheric Processes, W.P. Olson + (ed.), geophysical monograph 21, American Geophysical Union, 1979.

+

M.T. Teague, N.J. Schofield, K.W. Chan, and J.I. Vette, A Study of + Inner Zone Electron Data and their Comparison with Trapped + Radiation Models, NSSDC/WDC-A-R&S 79-06, 1979.

+

J.I. Vette, The AE-8 Trapped Electron Model Environment, + NSSDC/WDC-A-R&S 91-24, 1991.

+

J.I. Vette, The NASA/National Space Science Data Center Trapped + Radiation Environment Model Program (1964-1991), NSSDC/WDC-A-R&S + 91-29, 1991.

+

(most of these references are available from NSSDC)

+

D. Heynderickx and A. Beliaev, J. Spacecraft and Rockets 32, 190-192, 1995.

+

National Space Science Data Center Data set PT-11B Mar 1996

+
+
+
+

Developer Info

+

Jacob Williams

+

+
+ +
+
+
+
+
+
+ + + +
+
+

Derived Types

+ +
+
+ +
+
+
+
+
+ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/js/MathJax-config/.gitignore b/js/MathJax-config/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/js/svg-pan-zoom.min.js b/js/svg-pan-zoom.min.js new file mode 100644 index 0000000..328f5e7 --- /dev/null +++ b/js/svg-pan-zoom.min.js @@ -0,0 +1,3 @@ +// svg-pan-zoom v3.2.3 +// https://github.com/ariutta/svg-pan-zoom +!function t(e,o,n){function i(r,a){if(!o[r]){if(!e[r]){var l="function"==typeof require&&require;if(!a&&l)return l(r,!0);if(s)return s(r,!0);var u=new Error("Cannot find module '"+r+"'");throw u.code="MODULE_NOT_FOUND",u}var h=o[r]={exports:{}};e[r][0].call(h.exports,function(t){var o=e[r][1][t];return i(o?o:t)},h,h.exports,t,e,o,n)}return o[r].exports}for(var s="function"==typeof require&&require,r=0;r=0;n--)this.eventListeners.hasOwnProperty(o[n])&&delete this.eventListeners[o[n]]}for(var i in this.eventListeners)this.svg.addEventListener(i,this.eventListeners[i],!1);this.options.mouseWheelZoomEnabled&&(this.options.mouseWheelZoomEnabled=!1,this.enableMouseWheelZoom())},a.prototype.enableMouseWheelZoom=function(){if(!this.options.mouseWheelZoomEnabled){var t=this;this.wheelListener=function(e){return t.handleMouseWheel(e)},o.on(this.svg,this.wheelListener,!1),this.options.mouseWheelZoomEnabled=!0}},a.prototype.disableMouseWheelZoom=function(){this.options.mouseWheelZoomEnabled&&(o.off(this.svg,this.wheelListener,!1),this.options.mouseWheelZoomEnabled=!1)},a.prototype.handleMouseWheel=function(t){if(this.options.zoomEnabled&&"none"===this.state){this.options.preventMouseEventsDefault&&(t.preventDefault?t.preventDefault():t.returnValue=!1);var e=t.deltaY||1,o=Date.now()-this.lastMouseWheelEventTime,n=3+Math.max(0,30-o);this.lastMouseWheelEventTime=Date.now(),"deltaMode"in t&&0===t.deltaMode&&t.wheelDelta&&(e=0===t.deltaY?0:Math.abs(t.wheelDelta)/t.deltaY),e=e>-.3&&.3>e?e:(e>0?1:-1)*Math.log(Math.abs(e)+10)/n;var i=this.svg.getScreenCTM().inverse(),r=s.getEventPoint(t,this.svg).matrixTransform(i),a=Math.pow(1+this.options.zoomScaleSensitivity,-1*e);this.zoomAtPoint(a,r)}},a.prototype.zoomAtPoint=function(t,e,o){var n=this.viewport.getOriginalState();o?(t=Math.max(this.options.minZoom*n.zoom,Math.min(this.options.maxZoom*n.zoom,t)),t/=this.getZoom()):this.getZoom()*tthis.options.maxZoom*n.zoom&&(t=this.options.maxZoom*n.zoom/this.getZoom());var i=this.viewport.getCTM(),s=e.matrixTransform(i.inverse()),r=this.svg.createSVGMatrix().translate(s.x,s.y).scale(t).translate(-s.x,-s.y),a=i.multiply(r);a.a!==i.a&&this.viewport.setCTM(a)},a.prototype.zoom=function(t,e){this.zoomAtPoint(t,s.getSvgCenterPoint(this.svg,this.width,this.height),e)},a.prototype.publicZoom=function(t,e){e&&(t=this.computeFromRelativeZoom(t)),this.zoom(t,e)},a.prototype.publicZoomAtPoint=function(t,e,o){if(o&&(t=this.computeFromRelativeZoom(t)),!("SVGPoint"!==i.getType(e)&&"x"in e&&"y"in e))throw new Error("Given point is invalid");e=s.createSVGPoint(this.svg,e.x,e.y),this.zoomAtPoint(t,e,o)},a.prototype.getZoom=function(){return this.viewport.getZoom()},a.prototype.getRelativeZoom=function(){return this.viewport.getRelativeZoom()},a.prototype.computeFromRelativeZoom=function(t){return t*this.viewport.getOriginalState().zoom},a.prototype.resetZoom=function(){var t=this.viewport.getOriginalState();this.zoom(t.zoom,!0)},a.prototype.resetPan=function(){this.pan(this.viewport.getOriginalState())},a.prototype.reset=function(){this.resetZoom(),this.resetPan()},a.prototype.handleDblClick=function(t){if(this.options.preventMouseEventsDefault&&(t.preventDefault?t.preventDefault():t.returnValue=!1),this.options.controlIconsEnabled){var e=t.target.getAttribute("class")||"";if(e.indexOf("svg-pan-zoom-control")>-1)return!1}var o;o=t.shiftKey?1/(2*(1+this.options.zoomScaleSensitivity)):2*(1+this.options.zoomScaleSensitivity);var n=s.getEventPoint(t,this.svg).matrixTransform(this.svg.getScreenCTM().inverse());this.zoomAtPoint(o,n)},a.prototype.handleMouseDown=function(t,e){this.options.preventMouseEventsDefault&&(t.preventDefault?t.preventDefault():t.returnValue=!1),i.mouseAndTouchNormalize(t,this.svg),this.options.dblClickZoomEnabled&&i.isDblClick(t,e)?this.handleDblClick(t):(this.state="pan",this.firstEventCTM=this.viewport.getCTM(),this.stateOrigin=s.getEventPoint(t,this.svg).matrixTransform(this.firstEventCTM.inverse()))},a.prototype.handleMouseMove=function(t){if(this.options.preventMouseEventsDefault&&(t.preventDefault?t.preventDefault():t.returnValue=!1),"pan"===this.state&&this.options.panEnabled){var e=s.getEventPoint(t,this.svg).matrixTransform(this.firstEventCTM.inverse()),o=this.firstEventCTM.translate(e.x-this.stateOrigin.x,e.y-this.stateOrigin.y);this.viewport.setCTM(o)}},a.prototype.handleMouseUp=function(t){this.options.preventMouseEventsDefault&&(t.preventDefault?t.preventDefault():t.returnValue=!1),"pan"===this.state&&(this.state="none")},a.prototype.fit=function(){var t=this.viewport.getViewBox(),e=Math.min(this.width/t.width,this.height/t.height);this.zoom(e,!0)},a.prototype.contain=function(){var t=this.viewport.getViewBox(),e=Math.max(this.width/t.width,this.height/t.height);this.zoom(e,!0)},a.prototype.center=function(){var t=this.viewport.getViewBox(),e=.5*(this.width-(t.width+2*t.x)*this.getZoom()),o=.5*(this.height-(t.height+2*t.y)*this.getZoom());this.getPublicInstance().pan({x:e,y:o})},a.prototype.updateBBox=function(){this.viewport.recacheViewBox()},a.prototype.pan=function(t){var e=this.viewport.getCTM();e.e=t.x,e.f=t.y,this.viewport.setCTM(e)},a.prototype.panBy=function(t){var e=this.viewport.getCTM();e.e+=t.x,e.f+=t.y,this.viewport.setCTM(e)},a.prototype.getPan=function(){var t=this.viewport.getState();return{x:t.x,y:t.y}},a.prototype.resize=function(){var t=s.getBoundingClientRectNormalized(this.svg);this.width=t.width,this.height=t.height,this.options.controlIconsEnabled&&(this.getPublicInstance().disableControlIcons(),this.getPublicInstance().enableControlIcons())},a.prototype.destroy=function(){var t=this;this.beforeZoom=null,this.onZoom=null,this.beforePan=null,this.onPan=null,null!=this.options.customEventsHandler&&this.options.customEventsHandler.destroy({svgElement:this.svg,instance:this.getPublicInstance()});for(var e in this.eventListeners)this.svg.removeEventListener(e,this.eventListeners[e],!1);this.disableMouseWheelZoom(),this.getPublicInstance().disableControlIcons(),this.reset(),u=u.filter(function(e){return e.svg!==t.svg}),delete this.options,delete this.publicInstance,delete this.pi,this.getPublicInstance=function(){return null}},a.prototype.getPublicInstance=function(){var t=this;return this.publicInstance||(this.publicInstance=this.pi={enablePan:function(){return t.options.panEnabled=!0,t.pi},disablePan:function(){return t.options.panEnabled=!1,t.pi},isPanEnabled:function(){return!!t.options.panEnabled},pan:function(e){return t.pan(e),t.pi},panBy:function(e){return t.panBy(e),t.pi},getPan:function(){return t.getPan()},setBeforePan:function(e){return t.options.beforePan=null===e?null:i.proxy(e,t.publicInstance),t.pi},setOnPan:function(e){return t.options.onPan=null===e?null:i.proxy(e,t.publicInstance),t.pi},enableZoom:function(){return t.options.zoomEnabled=!0,t.pi},disableZoom:function(){return t.options.zoomEnabled=!1,t.pi},isZoomEnabled:function(){return!!t.options.zoomEnabled},enableControlIcons:function(){return t.options.controlIconsEnabled||(t.options.controlIconsEnabled=!0,n.enable(t)),t.pi},disableControlIcons:function(){return t.options.controlIconsEnabled&&(t.options.controlIconsEnabled=!1,n.disable(t)),t.pi},isControlIconsEnabled:function(){return!!t.options.controlIconsEnabled},enableDblClickZoom:function(){return t.options.dblClickZoomEnabled=!0,t.pi},disableDblClickZoom:function(){return t.options.dblClickZoomEnabled=!1,t.pi},isDblClickZoomEnabled:function(){return!!t.options.dblClickZoomEnabled},enableMouseWheelZoom:function(){return t.enableMouseWheelZoom(),t.pi},disableMouseWheelZoom:function(){return t.disableMouseWheelZoom(),t.pi},isMouseWheelZoomEnabled:function(){return!!t.options.mouseWheelZoomEnabled},setZoomScaleSensitivity:function(e){return t.options.zoomScaleSensitivity=e,t.pi},setMinZoom:function(e){return t.options.minZoom=e,t.pi},setMaxZoom:function(e){return t.options.maxZoom=e,t.pi},setBeforeZoom:function(e){return t.options.beforeZoom=null===e?null:i.proxy(e,t.publicInstance),t.pi},setOnZoom:function(e){return t.options.onZoom=null===e?null:i.proxy(e,t.publicInstance),t.pi},zoom:function(e){return t.publicZoom(e,!0),t.pi},zoomBy:function(e){return t.publicZoom(e,!1),t.pi},zoomAtPoint:function(e,o){return t.publicZoomAtPoint(e,o,!0),t.pi},zoomAtPointBy:function(e,o){return t.publicZoomAtPoint(e,o,!1),t.pi},zoomIn:function(){return this.zoomBy(1+t.options.zoomScaleSensitivity),t.pi},zoomOut:function(){return this.zoomBy(1/(1+t.options.zoomScaleSensitivity)),t.pi},getZoom:function(){return t.getRelativeZoom()},resetZoom:function(){return t.resetZoom(),t.pi},resetPan:function(){return t.resetPan(),t.pi},reset:function(){return t.reset(),t.pi},fit:function(){return t.fit(),t.pi},contain:function(){return t.contain(),t.pi},center:function(){return t.center(),t.pi},updateBBox:function(){return t.updateBBox(),t.pi},resize:function(){return t.resize(),t.pi},getSizes:function(){return{width:t.width,height:t.height,realZoom:t.getZoom(),viewBox:t.viewport.getViewBox()}},destroy:function(){return t.destroy(),t.pi}}),this.publicInstance};var u=[],h=function(t,e){var o=i.getSvg(t);if(null===o)return null;for(var n=u.length-1;n>=0;n--)if(u[n].svg===o)return u[n].instance.getPublicInstance();return u.push({svg:o,instance:new a(o,e)}),u[u.length-1].instance.getPublicInstance()};e.exports=h},{"./control-icons":2,"./shadow-viewport":3,"./svg-utilities":5,"./uniwheel":6,"./utilities":7}],5:[function(t,e){var o=t("./utilities"),n="unknown";document.documentMode&&(n="ie"),e.exports={svgNS:"http://www.w3.org/2000/svg",xmlNS:"http://www.w3.org/XML/1998/namespace",xmlnsNS:"http://www.w3.org/2000/xmlns/",xlinkNS:"http://www.w3.org/1999/xlink",evNS:"http://www.w3.org/2001/xml-events",getBoundingClientRectNormalized:function(t){if(t.clientWidth&&t.clientHeight)return{width:t.clientWidth,height:t.clientHeight};if(t.getBoundingClientRect())return t.getBoundingClientRect();throw new Error("Cannot get BoundingClientRect for SVG.")},getOrCreateViewport:function(t,e){var n=null;if(n=o.isElement(e)?e:t.querySelector(e),!n){var i=Array.prototype.slice.call(t.childNodes||t.children).filter(function(t){return"defs"!==t.nodeName&&"#text"!==t.nodeName});1===i.length&&"g"===i[0].nodeName&&null===i[0].getAttribute("transform")&&(n=i[0])}if(!n){var s="viewport-"+(new Date).toISOString().replace(/\D/g,"");n=document.createElementNS(this.svgNS,"g"),n.setAttribute("id",s);var r=t.childNodes||t.children;if(r&&r.length>0)for(var a=r.length;a>0;a--)"defs"!==r[r.length-a].nodeName&&n.appendChild(r[r.length-a]);t.appendChild(n)}var l=[];return n.getAttribute("class")&&(l=n.getAttribute("class").split(" ")),~l.indexOf("svg-pan-zoom_viewport")||(l.push("svg-pan-zoom_viewport"),n.setAttribute("class",l.join(" "))),n},setupSvgAttributes:function(t){if(t.setAttribute("xmlns",this.svgNS),t.setAttributeNS(this.xmlnsNS,"xmlns:xlink",this.xlinkNS),t.setAttributeNS(this.xmlnsNS,"xmlns:ev",this.evNS),null!==t.parentNode){var e=t.getAttribute("style")||"";-1===e.toLowerCase().indexOf("overflow")&&t.setAttribute("style","overflow: hidden; "+e)}},internetExplorerRedisplayInterval:300,refreshDefsGlobal:o.throttle(function(){for(var t=document.querySelectorAll("defs"),e=t.length,o=0;e>o;o++){var n=t[o];n.parentNode.insertBefore(n,n)}},this.internetExplorerRedisplayInterval),setCTM:function(t,e,o){var i=this,s="matrix("+e.a+","+e.b+","+e.c+","+e.d+","+e.e+","+e.f+")";t.setAttributeNS(null,"transform",s),"ie"===n&&o&&(o.parentNode.insertBefore(o,o),window.setTimeout(function(){i.refreshDefsGlobal()},i.internetExplorerRedisplayInterval))},getEventPoint:function(t,e){var n=e.createSVGPoint();return o.mouseAndTouchNormalize(t,e),n.x=t.clientX,n.y=t.clientY,n},getSvgCenterPoint:function(t,e,o){return this.createSVGPoint(t,e/2,o/2)},createSVGPoint:function(t,e,o){var n=t.createSVGPoint();return n.x=e,n.y=o,n}}},{"./utilities":7}],6:[function(t,e){e.exports=function(){function t(t,e,o){var n=function(t){!t&&(t=window.event);var o={originalEvent:t,target:t.target||t.srcElement,type:"wheel",deltaMode:"MozMousePixelScroll"==t.type?0:1,deltaX:0,delatZ:0,preventDefault:function(){t.preventDefault?t.preventDefault():t.returnValue=!1}};return"mousewheel"==u?(o.deltaY=-1/40*t.wheelDelta,t.wheelDeltaX&&(o.deltaX=-1/40*t.wheelDeltaX)):o.deltaY=t.detail,e(o)};return c.push({element:t,fn:n,capture:o}),n}function e(t,e){for(var o=0;oo&&10>n}return!1},now:Date.now||function(){return(new Date).getTime()},throttle:function(t,e,o){var n,i,s,r=this,a=null,l=0;o||(o={});var u=function(){l=o.leading===!1?0:r.now(),a=null,s=t.apply(n,i),a||(n=i=null)};return function(){var h=r.now();l||o.leading!==!1||(l=h);var c=e-(h-l);return n=this,i=arguments,0>=c||c>e?(clearTimeout(a),a=null,l=h,s=t.apply(n,i),a||(n=i=null)):a||o.trailing===!1||(a=setTimeout(u,c)),s}},createRequestAnimationFrame:function(t){var e=null;return"auto"!==t&&60>t&&t>1&&(e=Math.floor(1e3/t)),null===e?window.requestAnimationFrame||o(33):o(e)}}},{}]},{},[1]); \ No newline at end of file diff --git a/lists/files.html b/lists/files.html new file mode 100644 index 0000000..f381dbe --- /dev/null +++ b/lists/files.html @@ -0,0 +1,256 @@ + + + + + + + + + + + + + All Files – radbelt + + + + + + + + + + + + + + + +
+ +
+ +
+
+
+

Source Files

+ + + + + + + + + + + + + + + + + + + +
FileDescription
core.f90
radbelt_kinds_module.F90
shellig.f90
trmfun.f90
+
+ + + + + +file~~graph~~FileGraph + + + +sourcefile~core.f90 + + +core.f90 + + + + + +sourcefile~radbelt_kinds_module.f90 + + +radbelt_kinds_module.F90 + + + + + +sourcefile~radbelt_kinds_module.f90->sourcefile~core.f90 + + + + + +sourcefile~shellig.f90 + + +shellig.f90 + + + + + +sourcefile~radbelt_kinds_module.f90->sourcefile~shellig.f90 + + + + + +sourcefile~trmfun.f90 + + +trmfun.f90 + + + + + +sourcefile~radbelt_kinds_module.f90->sourcefile~trmfun.f90 + + + + + +sourcefile~shellig.f90->sourcefile~core.f90 + + + + + +sourcefile~trmfun.f90->sourcefile~core.f90 + + + + + +
+ Help +
+ +
+
+
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lists/modules.html b/lists/modules.html new file mode 100644 index 0000000..b55f6c2 --- /dev/null +++ b/lists/modules.html @@ -0,0 +1,296 @@ + + + + + + + + + + + + + All Modules – radbelt + + + + + + + + + + + + + + + +
+ +
+ +
+
+
+

Modules

+ + + + + + + + + + + + + + + + + + + + + + + +
ModuleSource FileDescription
corecore.f90

Main module.

Read more…
radbelt_kinds_moduleradbelt_kinds_module.F90

Numeric kind definitions for radbelt.

shellig_moduleshellig.f90

IGRF model

Read more…
trmfun_moduletrmfun.f90

Trapped radiation model.

Read more…
+
+ + + + + +module~~graph~~ModuleGraph + + + +module~core + + +core + + + + + +module~radbelt_kinds_module + + +radbelt_kinds_module + + + + + +module~core->module~radbelt_kinds_module + + + + + +module~shellig_module + + +shellig_module + + + + + +module~core->module~shellig_module + + + + + +module~trmfun_module + + +trmfun_module + + + + + +module~core->module~trmfun_module + + + + + +iso_fortran_env + +iso_fortran_env + + + +module~radbelt_kinds_module->iso_fortran_env + + + + + +module~shellig_module->module~radbelt_kinds_module + + + + + +module~trmfun_module->module~radbelt_kinds_module + + + + + +
+ Help +
+ +
+
+
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lists/procedures.html b/lists/procedures.html new file mode 100644 index 0000000..1ef3741 --- /dev/null +++ b/lists/procedures.html @@ -0,0 +1,533 @@ + + + + + + + + + + + + + All Procedures – radbelt + + + + + + + + + + + + + + + +
+ +
+ +
+
+
+

Procedures

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ProcedureLocationProcedure TypeDescription
aep8trmfun_moduleSubroutine

Main wrapper for the radiation model. +Reads the coefficient file and calls the low-level routine.

extrashcshellig_moduleSubroutine

Extrapolates linearly a spherical harmonic model with a + rate-of-change model.

Read more…
feldcofshellig_moduleSubroutine

Determines coefficients and dipol moment from IGRF models

Read more…
feldgshellig_moduleSubroutine

Calculates earth magnetic field from spherical harmonics model

Read more…
findb0shellig_moduleSubroutine
get_fluxcoreFunction

Main routine.

getshcshellig_moduleSubroutine

Reads spherical harmonic coefficients from the specified + file into an array.

Read more…
igrfshellig_moduleSubroutine

Wrapper for IGRF functions.

intershcshellig_moduleSubroutine

Interpolates linearly, in time, between two spherical + harmonic models.

Read more…
shellgshellig_moduleSubroutine

calculates l-value for specified geodaetic coordinates, altitude + and gemagnetic field model.

Read more…
stoershellig_moduleSubroutine

subroutine used for field line tracing in shellg +calls entry point feldi in geomagnetic field subroutine feldg

trara1trmfun_moduleSubroutine

trara1 finds particle fluxes for given energies, magnetic field +strength and l-value. function trara2 is used to interpolate in +b-l-space.

trara2trmfun_moduleFunction

trara2 interpolates linearly in l-b/b0-map to obtain + the logarithm of integral flux at given l and b/b0.

Read more…
+
+ + + + + +call~~graph~~CallGraph + + + +proc~aep8 + + +trmfun_module::trm_type%aep8 + + + + + +proc~trara1 + + +trmfun_module::trm_type%trara1 + + + + + +proc~aep8->proc~trara1 + + + + + +proc~extrashc + + +shellig_module::shellig_type%extrashc + + + + + +proc~feldcof + + +shellig_module::shellig_type%feldcof + + + + + +proc~feldcof->proc~extrashc + + + + + +proc~getshc + + +shellig_module::shellig_type%getshc + + + + + +proc~feldcof->proc~getshc + + + + + +proc~intershc + + +shellig_module::shellig_type%intershc + + + + + +proc~feldcof->proc~intershc + + + + + +proc~feldg + + +shellig_module::shellig_type%feldg + + + + + +feldc + +feldc + + + +proc~feldg->feldc + + + + + +feldi + +feldi + + + +proc~feldg->feldi + + + + + +proc~findb0 + + +shellig_module::shellig_type%findb0 + + + + + +proc~stoer + + +shellig_module::shellig_type%stoer + + + + + +proc~findb0->proc~stoer + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~aep8 + + + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~get_flux->proc~igrf + + + + + +proc~igrf->proc~feldcof + + + + + +proc~igrf->proc~feldg + + + + + +proc~igrf->proc~findb0 + + + + + +proc~shellg + + +shellig_module::shellig_type%shellg + + + + + +proc~igrf->proc~shellg + + + + + +proc~shellg->proc~stoer + + + + + +shellc + +shellc + + + +proc~shellg->shellc + + + + + +proc~stoer->feldi + + + + + +proc~trara2 + + +trmfun_module::trm_type%trara2 + + + + + +proc~trara1->proc~trara2 + + + + + +
+ Help +
+ +
+
+
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lists/types.html b/lists/types.html new file mode 100644 index 0000000..0f2e507 --- /dev/null +++ b/lists/types.html @@ -0,0 +1,206 @@ + + + + + + + + + + + + + All Types – radbelt + + + + + + + + + + + + + + + +
+ +
+ +
+
+
+

Derived Types

+ + + + + + + + + + + + + + + + +
TypeLocationExtendsDescription
shellig_typeshellig_moduleNone
trm_typetrmfun_moduleNone

main class for the aep8 model

+
+ + + + + +type~~graph~~TypeGraph + + + +type~shellig_type + + +shellig_type + + + + + +type~trm_type + + +trm_type + + + + + +
+ Help +
+ +
+
+
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/module/core.html b/module/core.html new file mode 100644 index 0000000..4b02ce3 --- /dev/null +++ b/module/core.html @@ -0,0 +1,508 @@ + + + + + + + + + + + + + core – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

core + Module + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+
+ + +
+ +
+

Main module.

+

See also

+
    +
  • https://ccmc.gsfc.nasa.gov/pub/modelweb/geomagnetic/igrf/fortran_code/bilcal.for
  • +
  • https://ccmc.gsfc.nasa.gov/pub/modelweb/radiation_belt/radbelt/fortran_code/radbelt.for
  • +
+
+

Uses

+
+
    +
  • + +
  • +
  • +
    + + + + + +module~~core~~UsesGraph + + + +module~core + +core + + + +module~radbelt_kinds_module + + +radbelt_kinds_module + + + + + +module~core->module~radbelt_kinds_module + + + + + +module~shellig_module + + +shellig_module + + + + + +module~core->module~shellig_module + + + + + +module~trmfun_module + + +trmfun_module + + + + + +module~core->module~trmfun_module + + + + + +iso_fortran_env + +iso_fortran_env + + + +module~radbelt_kinds_module->iso_fortran_env + + + + + +module~shellig_module->module~radbelt_kinds_module + + + + + +module~trmfun_module->module~radbelt_kinds_module + + + + + +
    + Help +
    + +
  • +
+
+
+ + +
+ + + + + + + +
+

Functions

+
+

public function get_flux(lon, lat, height, year, e, imname) result(flux) +

+
+ +

Main routine.

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + real(kind=wp), + intent(in) + + ::lon + +
+ + real(kind=wp), + intent(in) + + ::lat + +
+ + real(kind=wp), + intent(in) + + ::height + +
+ + real(kind=wp), + intent(in) + + ::year + +
+ + real(kind=wp), + intent(in) + + ::e + +
+ + integer, + intent(in) + + ::imname + +
+ +

+ Return Value + real(kind=wp) +

+ + +
+
+ +
+
+ + + + +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/module/radbelt_kinds_module.html b/module/radbelt_kinds_module.html new file mode 100644 index 0000000..0bf7e2a --- /dev/null +++ b/module/radbelt_kinds_module.html @@ -0,0 +1,527 @@ + + + + + + + + + + + + + radbelt_kinds_module – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

radbelt_kinds_module + Module + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+
+ + +
+ +
+

Numeric kind definitions for radbelt.

+
+

Uses

+
+
    +
  • + +
  • +
  • +
    + + + + + +module~~radbelt_kinds_module~~UsesGraph + + + +module~radbelt_kinds_module + +radbelt_kinds_module + + + +iso_fortran_env + +iso_fortran_env + + + +module~radbelt_kinds_module->iso_fortran_env + + + + + +
    + Help +
    + +
  • +
+
+
+ +
+

Used by

+
+
    +
  • +
    + + + + + +module~~radbelt_kinds_module~~UsedByGraph + + + +module~radbelt_kinds_module + +radbelt_kinds_module + + + +module~core + + +core + + + + + +module~core->module~radbelt_kinds_module + + + + + +module~shellig_module + + +shellig_module + + + + + +module~core->module~shellig_module + + + + + +module~trmfun_module + + +trmfun_module + + + + + +module~core->module~trmfun_module + + + + + +module~shellig_module->module~radbelt_kinds_module + + + + + +module~trmfun_module->module~radbelt_kinds_module + + + + + +
    + Help +
    + +
  • +
+
+
+ +
+ + +
+

Variables

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeVisibility AttributesNameInitial
+ + integer, + public, +parameter + ::wp =real64 +

Real working precision if not specified [8 bytes]

+
+ + integer, + public, +parameter + ::ip =int32 +

Integer working precision if not specified [4 bytes]

+
+ +
+
+ + + + + + + + + +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/module/shellig_module.html b/module/shellig_module.html new file mode 100644 index 0000000..689e25d --- /dev/null +++ b/module/shellig_module.html @@ -0,0 +1,2089 @@ + + + + + + + + + + + + + shellig_module – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

shellig_module + Module + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+
+ + +
+ +
+

IGRF model

+

History

+
    +
  • SHELLIG.FOR, Version 2.0, January 1992
  • +
  • 11/01/91-DKB- SHELLG: lowest starting point for B0 search is 2
  • +
  • 1/27/92-DKB- Adopted to IGRF-91 coefficients model
  • +
  • 2/05/92-DKB- Reduce variable-names: INTER(P)SHC,EXTRA(P)SHC,INITI(ALI)ZE
  • +
  • 8/08/95-DKB- Updated to IGRF-45-95; new coeff. DGRF90, IGRF95, IGRF95S
  • +
  • 5/31/00-DKB- Updated to IGRF-45-00; new coeff.: IGRF00, IGRF00s
  • +
  • 3/24/05-DKB- Updated to IGRF-45-10; new coeff.: IGRF05, IGRF05s
  • +
+
+

Uses

+
+
    +
  • + +
  • +
  • +
    + + + + + +module~~shellig_module~~UsesGraph + + + +module~shellig_module + +shellig_module + + + +module~radbelt_kinds_module + + +radbelt_kinds_module + + + + + +module~shellig_module->module~radbelt_kinds_module + + + + + +iso_fortran_env + +iso_fortran_env + + + +module~radbelt_kinds_module->iso_fortran_env + + + + + +
    + Help +
    + +
  • +
+
+
+ +
+

Used by

+
+
    +
  • +
    + + + + + +module~~shellig_module~~UsedByGraph + + + +module~shellig_module + +shellig_module + + + +module~core + + +core + + + + + +module~core->module~shellig_module + + + + + +
    + Help +
    + +
  • +
+
+
+ +
+ + +
+

Variables

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeVisibility AttributesNameInitial
+ + integer, + private, +parameter + ::filename_len =14 +

length of the model data file names

+
+ + real(kind=wp), + private, +parameter + ::Era =6371.2_wp +

earth radius for normalization of cartesian coordinates (6371.2 km)

+
+ + real(kind=wp), + private, +parameter + ::erequ =6378.16_wp + +
+ + real(kind=wp), + private, +parameter + ::erpol =6356.775_wp + +
+ + real(kind=wp), + private, +parameter + ::Aquad =erequ*erequ +

square of major half axis for +earth ellipsoid as recommended by international +astronomical union

+
+ + real(kind=wp), + private, +parameter + ::Bquad =erpol*erpol +

square of minor half axis for +earth ellipsoid as recommended by international +astronomical union

+
+ + real(kind=wp), + private, +parameter + ::Umr =atan(1.0_wp)*4.0_wp/180.0_wp +

atan(1.0)4./180. umr=

+
+ + real(kind=wp), + private, +parameter, dimension(3,3) + ::u =reshape([+0.3511737_wp, -0.9148385_wp, -0.1993679_wp, +0.9335804_wp, +0.3583680_wp, +0.0000000_wp, +0.0714471_wp, -0.1861260_wp, +0.9799247_wp], [3, 3]) + +
+ +
+
+ + + + +
+

Derived Types

+
+
+ +

+ type, public ::  + shellig_type + +

+
+
+ + +

Components

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeVisibility AttributesNameInitial
+ + real(kind=wp), + private, + dimension(3) + ::sp =0.0_wp + +
+ + real(kind=wp), + private, + dimension(3) + ::xi =0.0_wp + +
+ + real(kind=wp), + private, + dimension(144) + ::h =0.0_wp +

Field model coefficients adjusted for shellg

+
+ + integer, + private + + ::iyea =0 +

the int year corresponding to the file name that has been read

+
+ + character(len=filename_len), + private + + ::name ='' +

file name

+
+ + integer, + private + + ::nmax =0 +

maximum order of spherical harmonics

+
+ + real(kind=wp), + private + + ::Time =0.0_wp +

year (decimal: 1973.5) for which magnetic field is to be calculated

+
+ + real(kind=wp), + private, + dimension(144) + ::g =0.0_wp +

g(m) -- normalized field coefficients (see feldcof) m=nmax*(nmax+2)

+
+ + real(kind=wp), + private + + ::step =0.20_wp +

step size for field line tracing

+
+ + real(kind=wp), + private + + ::steq =0.03_wp +

step size for integration

+
+ + real(kind=wp), + private, + dimension(120) + ::gh2 =0.0_wp + +
+ + + + +

Type-Bound Procedures

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
procedure, public :: + igrf
procedure, public :: + feldcof
procedure, public :: + feldg
procedure, public :: + shellg
procedure, public :: + findb0
procedure, private :: + extrashc
procedure, private :: + intershc
procedure, private :: + getshc
procedure, private :: + stoer
+
+
+ +
+
+ + +
+

Subroutines

+
+

private subroutine igrf(me, lon, lat, height, year, xl, bbx) +

+
+ +

Wrapper for IGRF functions.

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::lon +

geodetic longitude in degrees (east)

+
+ + real(kind=wp), + intent(in) + + ::lat +

geodetic latitude in degrees (north)

+
+ + real(kind=wp), + intent(in) + + ::height +

altitude in km above sea level

+
+ + real(kind=wp), + intent(in) + + ::year +

decimal year for which geomagnetic field is to +be calculated (e.g.:1995.5 for day 185 of 1995)

+
+ + real(kind=wp), + intent(out) + + ::xl +

l-value

+
+ + real(kind=wp), + intent(out) + + ::bbx + +
+ + +
+
+ +
+

private subroutine findb0(me, stps, bdel, value, bequ, rr0) +

+
+ + + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::stps + +
+ + real(kind=wp), + intent(inout) + + ::bdel + +
+ + logical, + intent(out) + + ::value + +
+ + real(kind=wp), + intent(out) + + ::bequ + +
+ + real(kind=wp), + intent(out) + + ::rr0 + +
+ + +
+
+ +
+

private subroutine shellg(me, glat, glon, alt, dimo, fl, icode, b0) +

+
+ +

calculates l-value for specified geodaetic coordinates, altitude + and gemagnetic field model.

Read more… + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::glat +

GEODETIC LATITUDE IN DEGREES (NORTH)

+
+ + real(kind=wp), + intent(in) + + ::glon +

GEODETIC LONGITUDE IN DEGREES (EAST)

+
+ + real(kind=wp), + intent(in) + + ::alt +

ALTITUDE IN KM ABOVE SEA LEVEL

+
+ + real(kind=wp), + intent(in) + + ::dimo +

DIPOL MOMENT IN GAUSS (NORMALIZED TO EARTH RADIUS)

+
+ + real(kind=wp), + intent(out) + + ::fl +

l-value

+
+ + integer, + intent(out) + + ::icode +Read more… +
+ + real(kind=wp), + intent(out) + + ::b0 +

magnetic field strength in gauss

+
+ + +
+
+ +
+

private subroutine stoer(me, p, bq, r) +

+
+ +

subroutine used for field line tracing in shellg +calls entry point feldi in geomagnetic field subroutine feldg

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(inout), + dimension(7) + ::p + +
+ + real(kind=wp), + intent(out) + + ::bq + +
+ + real(kind=wp), + intent(out) + + ::r + +
+ + +
+
+ +
+

private subroutine feldg(me, glat, glon, alt, bnorth, beast, bdown, Babs) +

+
+ +

Calculates earth magnetic field from spherical harmonics model

Read more… + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::glat +

geodetic latitude in degrees (north)

+
+ + real(kind=wp), + intent(in) + + ::glon +

geodetic longitude in degrees (east)

+
+ + real(kind=wp), + intent(in) + + ::alt +

altitude in km above sea level

+
+ + real(kind=wp), + intent(out) + + ::bnorth +

components of the field with respect +to the local geodetic coordinate system, with axis +pointing in the tangential plane to the north, east +and downward.

+
+ + real(kind=wp), + intent(out) + + ::beast +

components of the field with respect +to the local geodetic coordinate system, with axis +pointing in the tangential plane to the north, east +and downward.

+
+ + real(kind=wp), + intent(out) + + ::bdown +

components of the field with respect +to the local geodetic coordinate system, with axis +pointing in the tangential plane to the north, east +and downward.

+
+ + real(kind=wp), + intent(out) + + ::Babs +

magnetic field strength in gauss

+
+ + +
+
+ +
+

private subroutine feldcof(me, year, dimo) +

+
+ +

Determines coefficients and dipol moment from IGRF models

Read more… + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::year +

decimal year for which geomagnetic field is to +be calculated (e.g.:1995.5 for day 185 of 1995)

+
+ + real(kind=wp), + intent(out) + + ::dimo +

geomagnetic dipol moment in gauss (normalized +to earth's radius) at the time (year)

+
+ + +
+
+ +
+

private subroutine getshc(me, Fspec, Nmax, Erad, Gh, Ier) +

+
+ +

Reads spherical harmonic coefficients from the specified + file into an array.

Read more… + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + character(len=*), + intent(in) + + ::Fspec +

File specification

+
+ + integer, + intent(out) + + ::Nmax +

Maximum degree and order of model

+
+ + real(kind=wp), + intent(out) + + ::Erad +

Earth's radius associated with the spherical +harmonic coefficients, in the same units as +elevation

+
+ + real(kind=wp), + intent(out), + dimension(*) + ::Gh +

Schmidt quasi-normal internal spherical +harmonic coefficients

+
+ + integer, + intent(out) + + ::Ier +

Error number:

Read more… +
+ + +
+
+ +
+

private subroutine intershc(me, date, dte1, nmax1, gh1, dte2, nmax2, gh2, nmax, gh) +

+
+ +

Interpolates linearly, in time, between two spherical + harmonic models.

Read more… + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::date +

Date of resulting model (in decimal year)

+
+ + real(kind=wp), + intent(in) + + ::dte1 +

Date of earlier model

+
+ + integer, + intent(in) + + ::nmax1 +

Maximum degree and order of earlier model

+
+ + real(kind=wp), + intent(in) + + ::gh1(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of earlier model

+
+ + real(kind=wp), + intent(in) + + ::dte2 +

Date of later model

+
+ + integer, + intent(in) + + ::nmax2 +

Maximum degree and order of later model

+
+ + real(kind=wp), + intent(in) + + ::gh2(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of later model

+
+ + integer, + intent(out) + + ::nmax +

Maximum degree and order of resulting model

+
+ + real(kind=wp), + intent(out) + + ::gh(*) +

Coefficients of resulting model

+
+ + +
+
+ +
+

private subroutine extrashc(me, date, dte1, nmax1, gh1, nmax2, gh2, nmax, gh) +

+
+ +

Extrapolates linearly a spherical harmonic model with a + rate-of-change model.

Read more… + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::date +

Date of resulting model (in decimal year)

+
+ + real(kind=wp), + intent(in) + + ::dte1 +

Date of base model

+
+ + integer, + intent(in) + + ::nmax1 +

Maximum degree and order of base model

+
+ + real(kind=wp), + intent(in) + + ::gh1(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of base model

+
+ + integer, + intent(in) + + ::nmax2 +

Maximum degree and order of rate-of-change model

+
+ + real(kind=wp), + intent(in) + + ::gh2(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of rate-of-change model

+
+ + integer, + intent(out) + + ::nmax +

Maximum degree and order of resulting model

+
+ + real(kind=wp), + intent(out) + + ::gh(*) +

Coefficients of resulting model

+
+ + +
+
+ +
+
+ + + +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/module/trmfun_module.html b/module/trmfun_module.html new file mode 100644 index 0000000..4a3e20f --- /dev/null +++ b/module/trmfun_module.html @@ -0,0 +1,1046 @@ + + + + + + + + + + + + + trmfun_module – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

trmfun_module + Module + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+
+ + +
+ +
+

Trapped radiation model.

+

History

+
    +
  • Based on: trmfun.for 1987
  • +
+
+

Uses

+
+
    +
  • + +
  • +
  • +
    + + + + + +module~~trmfun_module~~UsesGraph + + + +module~trmfun_module + +trmfun_module + + + +module~radbelt_kinds_module + + +radbelt_kinds_module + + + + + +module~trmfun_module->module~radbelt_kinds_module + + + + + +iso_fortran_env + +iso_fortran_env + + + +module~radbelt_kinds_module->iso_fortran_env + + + + + +
    + Help +
    + +
  • +
+
+
+ +
+

Used by

+
+
    +
  • +
    + + + + + +module~~trmfun_module~~UsedByGraph + + + +module~trmfun_module + +trmfun_module + + + +module~core + + +core + + + + + +module~core->module~trmfun_module + + + + + +
    + Help +
    + +
  • +
+
+
+ +
+ + +
+

Variables

+ + + + + + + + + + + + + + + + + + + + + +
TypeVisibility AttributesNameInitial
+ + character(len=10), + private, +parameter, dimension(4) + ::mname =['ae8min.asc', 'ae8max.asc', 'ap8min.asc', 'ap8max.asc'] +

data files available

+
+ +
+
+ + + + +
+

Derived Types

+
+
+ +

+ type, public ::  + trm_type + +

+
+
+

main class for the aep8 model

+ +

Components

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeVisibility AttributesNameInitial
+ + character(len=:), + private, + allocatable + ::file_loaded +

the file that has been loaded

+
+ + integer, + private, + dimension(8) + ::ihead =0 + +
+ + integer, + private, + dimension(:), allocatable + ::map + +
+ + real(kind=wp), + private + + ::fistep =0.0_wp +

the stepsize for the parameterization of the logarithm of flux. +formerly stored in common block tra2

+
+ + real(kind=wp), + private + + ::f1 =1.001_wp + +
+ + real(kind=wp), + private + + ::f2 =1.002_wp + +
+ + + + +

Type-Bound Procedures

+ + + + + + + + + + + + + + + +
procedure, public :: + aep8../../

main routine

procedure, public :: + trara2../../

low-level routine

procedure, public :: + trara1
+
+
+ +
+
+ +
+

Functions

+
+

private function trara2(me, map, il, ib) +

+
+ +

trara2 interpolates linearly in l-b/b0-map to obtain + the logarithm of integral flux at given l and b/b0.

Read more… + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(trm_type), + intent(inout) + + ::me + +
+ + integer, + intent(in) + + ::map(*) +

is sub-map (for specific energy) of +trapped radiation model map

+
+ + integer, + intent(in) + + ::il +

scaled l-value

+
+ + integer, + intent(in) + + ::ib +

scaled b/b0-1

+
+ +

+ Return Value + real(kind=wp) +

+

scaled logarithm of particle flux

+ +
+
+ +
+
+ +
+

Subroutines

+
+

private subroutine aep8(me, e, l, bb0, imname, flux) +

+
+ +

Main wrapper for the radiation model. +Reads the coefficient file and calls the low-level routine.

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(trm_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::e + +
+ + real(kind=wp), + intent(in) + + ::l + +
+ + real(kind=wp), + intent(in) + + ::bb0 + +
+ + integer, + intent(in) + + ::imname +

which model to load (index in mname array)

+
+ + real(kind=wp), + intent(out) + + ::flux + +
+ + +
+
+ +
+

private subroutine trara1(me, descr, map, fl, bb0, e, f, n) +

+
+ +

trara1 finds particle fluxes for given energies, magnetic field +strength and l-value. function trara2 is used to interpolate in +b-l-space.

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(trm_type), + intent(inout) + + ::me + +
+ + integer, + intent(in) + + ::descr(8) +

header of specified trapped radition model

+
+ + integer, + intent(in) + + ::map(*) +

map of trapped radition model +(descr and map are explained at the begin +of the main program model)

+
+ + real(kind=wp), + intent(in) + + ::fl +

l-value

+
+ + real(kind=wp), + intent(in) + + ::bb0 +

=b/b0 magnetic field strength normalized +to field strength at magnetic equator

+
+ + real(kind=wp), + intent(in) + + ::e(n) +

array of energies in mev

+
+ + real(kind=wp), + intent(out) + + ::f(n) +

decadic logarithm of integral fluxes in +particles/(cmcmsec)

+
+ + integer, + intent(in) + + ::n +

number of energies

+
+ + +
+
+ +
+
+ + + +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/modules.json b/modules.json new file mode 100644 index 0000000..6bd4f8e --- /dev/null +++ b/modules.json @@ -0,0 +1 @@ +{"ford-metadata": {"version": "7.0.5"}, "modules": [{"name": "radbelt_kinds_module", "external_url": "./module/radbelt_kinds_module.html", "obj": "module", "pub_procs": {}, "pub_absints": {}, "pub_types": {}, "pub_vars": {"wp": {"name": "wp", "external_url": "./module/radbelt_kinds_module.html#variable-wp", "obj": "variable", "vartype": "integer", "permission": "public"}, "ip": {"name": "ip", "external_url": "./module/radbelt_kinds_module.html#variable-ip", "obj": "variable", "vartype": "integer", "permission": "public"}}, "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [{"name": "wp", "external_url": "./module/radbelt_kinds_module.html#variable-wp", "obj": "variable", "vartype": "integer", "permission": "public"}, {"name": "ip", "external_url": "./module/radbelt_kinds_module.html#variable-ip", "obj": "variable", "vartype": "integer", "permission": "public"}], "permission": "private"}, {"name": "trmfun_module", "external_url": "./module/trmfun_module.html", "obj": "module", "pub_procs": {}, "pub_absints": {}, "pub_types": {"trm_type": {"name": "trm_type", "external_url": "./type/trm_type.html", "obj": "type", "extends": null, "variables": [{"name": "file_loaded", "external_url": "./type/trm_type.html#variable-file_loaded", "obj": "variable", "vartype": "character", "permission": "private"}, {"name": "ihead", "external_url": "./type/trm_type.html#variable-ihead", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "map", "external_url": "./type/trm_type.html#variable-map", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "fistep", "external_url": "./type/trm_type.html#variable-fistep", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "f1", "external_url": "./type/trm_type.html#variable-f1", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "f2", "external_url": "./type/trm_type.html#variable-f2", "obj": "variable", "vartype": "real", "permission": "private"}], "boundprocs": [{"name": "aep8", "external_url": "./type/trm_type.html#boundprocedure-aep8", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "trara2", "external_url": "./type/trm_type.html#boundprocedure-trara2", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "trara1", "external_url": "./type/trm_type.html#boundprocedure-trara1", "obj": "boundprocedure", "permission": "public", "generic": "False"}], "permission": "public"}}, "pub_vars": {}, "functions": [{"name": "trara2", "external_url": "./proc/trara2.html", "obj": "proc", "proctype": "Function", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}], "subroutines": [{"name": "aep8", "external_url": "./proc/aep8.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "trara1", "external_url": "./proc/trara1.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}], "interfaces": [], "absinterfaces": [], "types": [{"name": "trm_type", "external_url": "./type/trm_type.html", "obj": "type", "extends": null, "variables": [{"name": "file_loaded", "external_url": "./type/trm_type.html#variable-file_loaded", "obj": "variable", "vartype": "character", "permission": "private"}, {"name": "ihead", "external_url": "./type/trm_type.html#variable-ihead", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "map", "external_url": "./type/trm_type.html#variable-map", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "fistep", "external_url": "./type/trm_type.html#variable-fistep", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "f1", "external_url": "./type/trm_type.html#variable-f1", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "f2", "external_url": "./type/trm_type.html#variable-f2", "obj": "variable", "vartype": "real", "permission": "private"}], "boundprocs": [{"name": "aep8", "external_url": "./type/trm_type.html#boundprocedure-aep8", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "trara2", "external_url": "./type/trm_type.html#boundprocedure-trara2", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "trara1", "external_url": "./type/trm_type.html#boundprocedure-trara1", "obj": "boundprocedure", "permission": "public", "generic": "False"}], "permission": "public"}], "variables": [{"name": "mname", "external_url": "./module/trmfun_module.html#variable-mname", "obj": "variable", "vartype": "character", "permission": "private"}], "permission": "private"}, {"name": "shellig_module", "external_url": "./module/shellig_module.html", "obj": "module", "pub_procs": {}, "pub_absints": {}, "pub_types": {"shellig_type": {"name": "shellig_type", "external_url": "./type/shellig_type.html", "obj": "type", "extends": null, "variables": [{"name": "sp", "external_url": "./type/shellig_type.html#variable-sp", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "xi", "external_url": "./type/shellig_type.html#variable-xi", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "h", "external_url": "./type/shellig_type.html#variable-h", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "iyea", "external_url": "./type/shellig_type.html#variable-iyea", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "name", "external_url": "./type/shellig_type.html#variable-name~2", "obj": "variable", "vartype": "character", "permission": "private"}, {"name": "nmax", "external_url": "./type/shellig_type.html#variable-nmax", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "Time", "external_url": "./type/shellig_type.html#variable-time", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "g", "external_url": "./type/shellig_type.html#variable-g", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "step", "external_url": "./type/shellig_type.html#variable-step", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "steq", "external_url": "./type/shellig_type.html#variable-steq", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "gh2", "external_url": "./type/shellig_type.html#variable-gh2", "obj": "variable", "vartype": "real", "permission": "private"}], "boundprocs": [{"name": "igrf", "external_url": "./type/shellig_type.html#boundprocedure-igrf", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "feldcof", "external_url": "./type/shellig_type.html#boundprocedure-feldcof", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "feldg", "external_url": "./type/shellig_type.html#boundprocedure-feldg", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "shellg", "external_url": "./type/shellig_type.html#boundprocedure-shellg", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "findb0", "external_url": "./type/shellig_type.html#boundprocedure-findb0", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "extrashc", "external_url": "./type/shellig_type.html#boundprocedure-extrashc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "intershc", "external_url": "./type/shellig_type.html#boundprocedure-intershc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "getshc", "external_url": "./type/shellig_type.html#boundprocedure-getshc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "stoer", "external_url": "./type/shellig_type.html#boundprocedure-stoer", "obj": "boundprocedure", "permission": "private", "generic": "False"}], "permission": "public"}}, "pub_vars": {}, "functions": [], "subroutines": [{"name": "igrf", "external_url": "./proc/igrf.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "findb0", "external_url": "./proc/findb0.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "shellg", "external_url": "./proc/shellg.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "stoer", "external_url": "./proc/stoer.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "feldg", "external_url": "./proc/feldg.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "feldcof", "external_url": "./proc/feldcof.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "getshc", "external_url": "./proc/getshc.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "intershc", "external_url": "./proc/intershc.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}, {"name": "extrashc", "external_url": "./proc/extrashc.html", "obj": "proc", "proctype": "Subroutine", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "private"}], "interfaces": [], "absinterfaces": [], "types": [{"name": "shellig_type", "external_url": "./type/shellig_type.html", "obj": "type", "extends": null, "variables": [{"name": "sp", "external_url": "./type/shellig_type.html#variable-sp", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "xi", "external_url": "./type/shellig_type.html#variable-xi", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "h", "external_url": "./type/shellig_type.html#variable-h", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "iyea", "external_url": "./type/shellig_type.html#variable-iyea", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "name", "external_url": "./type/shellig_type.html#variable-name~2", "obj": "variable", "vartype": "character", "permission": "private"}, {"name": "nmax", "external_url": "./type/shellig_type.html#variable-nmax", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "Time", "external_url": "./type/shellig_type.html#variable-time", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "g", "external_url": "./type/shellig_type.html#variable-g", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "step", "external_url": "./type/shellig_type.html#variable-step", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "steq", "external_url": "./type/shellig_type.html#variable-steq", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "gh2", "external_url": "./type/shellig_type.html#variable-gh2", "obj": "variable", "vartype": "real", "permission": "private"}], "boundprocs": [{"name": "igrf", "external_url": "./type/shellig_type.html#boundprocedure-igrf", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "feldcof", "external_url": "./type/shellig_type.html#boundprocedure-feldcof", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "feldg", "external_url": "./type/shellig_type.html#boundprocedure-feldg", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "shellg", "external_url": "./type/shellig_type.html#boundprocedure-shellg", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "findb0", "external_url": "./type/shellig_type.html#boundprocedure-findb0", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "extrashc", "external_url": "./type/shellig_type.html#boundprocedure-extrashc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "intershc", "external_url": "./type/shellig_type.html#boundprocedure-intershc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "getshc", "external_url": "./type/shellig_type.html#boundprocedure-getshc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "stoer", "external_url": "./type/shellig_type.html#boundprocedure-stoer", "obj": "boundprocedure", "permission": "private", "generic": "False"}], "permission": "public"}], "variables": [{"name": "filename_len", "external_url": "./module/shellig_module.html#variable-filename_len", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "Era", "external_url": "./module/shellig_module.html#variable-era", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "erequ", "external_url": "./module/shellig_module.html#variable-erequ", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "erpol", "external_url": "./module/shellig_module.html#variable-erpol", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "Aquad", "external_url": "./module/shellig_module.html#variable-aquad", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "Bquad", "external_url": "./module/shellig_module.html#variable-bquad", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "Umr", "external_url": "./module/shellig_module.html#variable-umr", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "u", "external_url": "./module/shellig_module.html#variable-u", "obj": "variable", "vartype": "real", "permission": "private"}], "permission": "private"}, {"name": "core", "external_url": "./module/core.html", "obj": "module", "pub_procs": {"get_flux": {"name": "get_flux", "external_url": "./proc/get_flux.html", "obj": "proc", "proctype": "Function", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "public"}}, "pub_absints": {}, "pub_types": {"trm_type": {"name": "trm_type", "external_url": "./type/trm_type.html", "obj": "type", "extends": null, "variables": [{"name": "file_loaded", "external_url": "./type/trm_type.html#variable-file_loaded", "obj": "variable", "vartype": "character", "permission": "private"}, {"name": "ihead", "external_url": "./type/trm_type.html#variable-ihead", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "map", "external_url": "./type/trm_type.html#variable-map", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "fistep", "external_url": "./type/trm_type.html#variable-fistep", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "f1", "external_url": "./type/trm_type.html#variable-f1", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "f2", "external_url": "./type/trm_type.html#variable-f2", "obj": "variable", "vartype": "real", "permission": "private"}], "boundprocs": [{"name": "aep8", "external_url": "./type/trm_type.html#boundprocedure-aep8", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "trara2", "external_url": "./type/trm_type.html#boundprocedure-trara2", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "trara1", "external_url": "./type/trm_type.html#boundprocedure-trara1", "obj": "boundprocedure", "permission": "public", "generic": "False"}], "permission": "public"}, "shellig_type": {"name": "shellig_type", "external_url": "./type/shellig_type.html", "obj": "type", "extends": null, "variables": [{"name": "sp", "external_url": "./type/shellig_type.html#variable-sp", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "xi", "external_url": "./type/shellig_type.html#variable-xi", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "h", "external_url": "./type/shellig_type.html#variable-h", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "iyea", "external_url": "./type/shellig_type.html#variable-iyea", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "name", "external_url": "./type/shellig_type.html#variable-name~2", "obj": "variable", "vartype": "character", "permission": "private"}, {"name": "nmax", "external_url": "./type/shellig_type.html#variable-nmax", "obj": "variable", "vartype": "integer", "permission": "private"}, {"name": "Time", "external_url": "./type/shellig_type.html#variable-time", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "g", "external_url": "./type/shellig_type.html#variable-g", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "step", "external_url": "./type/shellig_type.html#variable-step", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "steq", "external_url": "./type/shellig_type.html#variable-steq", "obj": "variable", "vartype": "real", "permission": "private"}, {"name": "gh2", "external_url": "./type/shellig_type.html#variable-gh2", "obj": "variable", "vartype": "real", "permission": "private"}], "boundprocs": [{"name": "igrf", "external_url": "./type/shellig_type.html#boundprocedure-igrf", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "feldcof", "external_url": "./type/shellig_type.html#boundprocedure-feldcof", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "feldg", "external_url": "./type/shellig_type.html#boundprocedure-feldg", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "shellg", "external_url": "./type/shellig_type.html#boundprocedure-shellg", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "findb0", "external_url": "./type/shellig_type.html#boundprocedure-findb0", "obj": "boundprocedure", "permission": "public", "generic": "False"}, {"name": "extrashc", "external_url": "./type/shellig_type.html#boundprocedure-extrashc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "intershc", "external_url": "./type/shellig_type.html#boundprocedure-intershc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "getshc", "external_url": "./type/shellig_type.html#boundprocedure-getshc", "obj": "boundprocedure", "permission": "private", "generic": "False"}, {"name": "stoer", "external_url": "./type/shellig_type.html#boundprocedure-stoer", "obj": "boundprocedure", "permission": "private", "generic": "False"}], "permission": "public"}}, "pub_vars": {"wp": {"name": "wp", "external_url": "./module/radbelt_kinds_module.html#variable-wp", "obj": "variable", "vartype": "integer", "permission": "public"}, "ip": {"name": "ip", "external_url": "./module/radbelt_kinds_module.html#variable-ip", "obj": "variable", "vartype": "integer", "permission": "public"}}, "functions": [{"name": "get_flux", "external_url": "./proc/get_flux.html", "obj": "proc", "proctype": "Function", "functions": [], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "public"}], "subroutines": [], "interfaces": [], "absinterfaces": [], "types": [], "variables": [], "permission": "public"}]} \ No newline at end of file diff --git a/proc/aep8.html b/proc/aep8.html new file mode 100644 index 0000000..06b9a37 --- /dev/null +++ b/proc/aep8.html @@ -0,0 +1,618 @@ + + + + + + + + + + + + + aep8 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

aep8 + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine aep8(me, e, l, bb0, imname, flux) +

+ + +

Main wrapper for the radiation model. +Reads the coefficient file and calls the low-level routine.

+ +

Type Bound

+

trm_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(trm_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::e + +
+ + real(kind=wp), + intent(in) + + ::l + +
+ + real(kind=wp), + intent(in) + + ::bb0 + +
+ + integer, + intent(in) + + ::imname +

which model to load (index in mname array)

+
+ + real(kind=wp), + intent(out) + + ::flux + +
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~aep8~~CallsGraph + + + +proc~aep8 + +trmfun_module::trm_type%aep8 + + + +proc~trara1 + + +trmfun_module::trm_type%trara1 + + + + + +proc~aep8->proc~trara1 + + + + + +proc~trara2 + + +trmfun_module::trm_type%trara2 + + + + + +proc~trara1->proc~trara2 + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~aep8~~CalledByGraph + + + +proc~aep8 + +trmfun_module::trm_type%aep8 + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~aep8 + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
   subroutine aep8(me,e,l,bb0,imname,flux)
+
+      class(trm_type),intent(inout) :: me
+
+      real(wp),intent(in) :: e
+      real(wp),intent(in) :: l
+      real(wp),intent(in) :: bb0
+      integer,intent(in) :: imname !! which model to load (index in `mname` array)
+      real(wp),intent(out) :: flux
+
+      real(wp) :: ee(1), f(1) !! temp variables
+      integer :: i , ierr, iuaeap , nmap
+      character(len=len(mname)) :: name
+      logical :: load_file
+
+      name = mname(Imname) ! the file to load
+
+      ! check to see if this file has already been loaded
+      ! [the class can store one file at a time]
+      load_file = .true.
+      if (allocated(me%file_loaded)) then
+         if (name == me%file_loaded) load_file = .false.
+      end if
+
+      if (load_file) then
+         open (newunit = iuaeap,file=name,status='OLD',iostat=ierr,form='FORMATTED')
+         if ( ierr/=0 ) then
+            error stop 'error reading '//trim(name)
+         end if
+         read (iuaeap,'(1X,12I6)') me%ihead
+         nmap = me%ihead(8)
+         allocate(me%map(nmap))
+         read (iuaeap,'(1X,12I6)') (me%map(i),i=1,nmap)
+         close (iuaeap)
+         me%file_loaded = trim(name)
+      end if
+
+      ee(1) = e
+      call me%trara1(me%ihead,me%map,L,Bb0,ee,f,1)
+      flux = f(1)
+      IF ( Flux>0.0_wp ) Flux = 10.0_wp**Flux
+
+   end subroutine aep8
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/extrashc.html b/proc/extrashc.html new file mode 100644 index 0000000..2397ee9 --- /dev/null +++ b/proc/extrashc.html @@ -0,0 +1,569 @@ + + + + + + + + + + + + + extrashc – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

extrashc + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine extrashc(me, date, dte1, nmax1, gh1, nmax2, gh2, nmax, gh) +

+ + +

Extrapolates linearly a spherical harmonic model with a + rate-of-change model.

+

The coefficients (GH) of the resulting model, at date + DATE, are computed by linearly extrapolating the coef- + ficients of the base model (GH1), at date DTE1, using + those of the rate-of-change model (GH2), at date DTE2. If + one model is smaller than the other, the extrapolation is + performed with the missing coefficients assumed to be 0.

+

Author

+
    +
  • Version 1.01, A. Zunde + USGS, MS 964, Box 25046 Federal Center, Denver, CO 80225
  • +
+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::date +

Date of resulting model (in decimal year)

+
+ + real(kind=wp), + intent(in) + + ::dte1 +

Date of base model

+
+ + integer, + intent(in) + + ::nmax1 +

Maximum degree and order of base model

+
+ + real(kind=wp), + intent(in) + + ::gh1(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of base model

+
+ + integer, + intent(in) + + ::nmax2 +

Maximum degree and order of rate-of-change model

+
+ + real(kind=wp), + intent(in) + + ::gh2(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of rate-of-change model

+
+ + integer, + intent(out) + + ::nmax +

Maximum degree and order of resulting model

+
+ + real(kind=wp), + intent(out) + + ::gh(*) +

Coefficients of resulting model

+
+ +
+
+
+

Called by

+
+
+
+ + + + + +proc~~extrashc~~CalledByGraph + + + +proc~extrashc + +shellig_module::shellig_type%extrashc + + + +proc~feldcof + + +shellig_module::shellig_type%feldcof + + + + + +proc~feldcof->proc~extrashc + + + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~feldcof + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
subroutine extrashc(me,date,dte1,nmax1,gh1,nmax2,gh2,nmax,gh)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: date   !! Date of resulting model (in decimal year)
+   real(wp),intent(in) :: dte1   !! Date of base model
+   integer,intent(in)  :: nmax1  !! Maximum degree and order of base model
+   real(wp),intent(in) :: gh1(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of base model
+   integer,intent(in)  :: nmax2  !! Maximum degree and order of rate-of-change model
+   real(wp),intent(in) :: gh2(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of rate-of-change model
+   real(wp),intent(out) :: gh(*) !! Coefficients of resulting model
+   integer,intent(out) :: nmax   !! Maximum degree and order of resulting model
+
+   real(wp) :: factor
+   integer :: i , k , l
+
+   factor = (date-dte1)
+
+   if ( nmax1==nmax2 ) then
+      k = nmax1*(nmax1+2)
+      nmax = nmax1
+   elseif ( nmax1>nmax2 ) then
+      k = nmax2*(nmax2+2)
+      l = nmax1*(nmax1+2)
+      do i = k + 1 , l
+         gh(i) = gh1(i)
+      enddo
+      nmax = nmax1
+   else
+      k = nmax1*(nmax1+2)
+      l = nmax2*(nmax2+2)
+      do i = k + 1 , l
+         gh(i) = factor*gh2(i)
+      enddo
+      nmax = nmax2
+   endif
+
+   do i = 1 , k
+      gh(i) = gh1(i) + factor*gh2(i)
+   enddo
+
+end subroutine extrashc
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/feldcof.html b/proc/feldcof.html new file mode 100644 index 0000000..a91237e --- /dev/null +++ b/proc/feldcof.html @@ -0,0 +1,659 @@ + + + + + + + + + + + + + feldcof – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

feldcof + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine feldcof(me, year, dimo) +

+ + +

Determines coefficients and dipol moment from IGRF models

+

Author

+
    +
  • D. BILITZA, NSSDC, GSFC, CODE 633, GREENBELT, MD 20771, + (301) 286-9536 NOV 1987.
  • +
+

History

+
    +
  • corrected for 2000 update - dkb- 5/31/2000
  • +
  • updated to IGRF-2000 version -dkb- 5/31/2000
  • +
  • updated to IGRF-2005 version -dkb- 3/24/2000
  • +
+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::year +

decimal year for which geomagnetic field is to +be calculated (e.g.:1995.5 for day 185 of 1995)

+
+ + real(kind=wp), + intent(out) + + ::dimo +

geomagnetic dipol moment in gauss (normalized +to earth's radius) at the time (year)

+
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~feldcof~~CallsGraph + + + +proc~feldcof + +shellig_module::shellig_type%feldcof + + + +proc~extrashc + + +shellig_module::shellig_type%extrashc + + + + + +proc~feldcof->proc~extrashc + + + + + +proc~getshc + + +shellig_module::shellig_type%getshc + + + + + +proc~feldcof->proc~getshc + + + + + +proc~intershc + + +shellig_module::shellig_type%intershc + + + + + +proc~feldcof->proc~intershc + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~feldcof~~CalledByGraph + + + +proc~feldcof + +shellig_module::shellig_type%feldcof + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~feldcof + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
   subroutine feldcof(me,year,dimo)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: year !! decimal year for which geomagnetic field is to
+                               !! be calculated (e.g.:1995.5 for day 185 of 1995)
+   real(wp),intent(out) :: dimo !! geomagnetic dipol moment in gauss (normalized
+                                !! to earth's radius) at the time (year)
+
+   real(wp) :: dte1 , dte2 , erad , gha(144) , sqrt2
+   integer :: i , ier , j , l , m , n , nmax1 , nmax2, iyea
+   character(len=filename_len) :: fil2
+   real(wp) :: x , f0 , f !! these were double precision in original
+                          !! code while everything else was single precision
+
+   ! changed to conform with IGRF 45-95, also FILMOD, DTEMOD arrays +1
+   character(len=filename_len),dimension(17),parameter :: filmod = [&
+         'dgrf1945.dat ' , 'dgrf1950.dat ' , 'dgrf1955.dat ' , 'dgrf1960.dat ' , &
+         'dgrf1965.dat ' , 'dgrf1970.dat ' , 'dgrf1975.dat ' , 'dgrf1980.dat ' , &
+         'dgrf1985.dat ' , 'dgrf1990.dat ' , 'dgrf1995.dat ' , 'dgrf2000.dat ' , &
+         'dgrf2005.dat ' , 'dgrf2010.dat ' , 'dgrf2015.dat ' , 'igrf2020.dat ' , &
+         'igrf2020s.dat']
+   real(wp),dimension(17),parameter :: dtemod = [1945.0_wp , 1950.0_wp , 1955.0_wp , &
+                                                 1960.0_wp , 1965.0_wp , 1970.0_wp , &
+                                                 1975.0_wp , 1980.0_wp , 1985.0_wp , &
+                                                 1990.0_wp , 1995.0_wp , 2000.0_wp , &
+                                                 2005.0_wp , 2010.0_wp , 2015.0_wp , &
+                                                 2020.0_wp , 2025.0_wp]
+   integer,parameter :: numye = size(dtemod)-1 ! number of 5-year priods represented by IGRF
+   integer,parameter :: is = 0 !! * is=0 for schmidt normalization
+                               !! * is=1 gauss normalization
+
+   logical :: read_file
+
+   !-- determine igrf-years for input-year
+   me%time = year
+   iyea = int(year/5.0_wp)*5
+   read_file = iyea /= me%iyea  ! if we have to read the file
+   me%iyea = iyea
+   l = (me%iyea-1945)/5 + 1
+   if ( l<1 ) l = 1
+   if ( l>numye ) l = numye
+   dte1 = dtemod(l)
+   me%name = filmod(l)
+   dte2 = dtemod(l+1)
+   fil2 = filmod(l+1)
+   if (read_file) then
+      ! get igrf coefficients for the boundary years
+      ! [if they have not ready been loaded]
+      call me%getshc(me%name,nmax1,erad,me%g,ier)
+      if ( ier/=0 ) error stop 'error reading file: '//trim(me%name)
+      call me%getshc(fil2,nmax2,erad,me%gh2,ier)
+      if ( ier/=0 ) error stop 'error reading file: '//trim(fil2)
+   end if
+   !-- determine igrf coefficients for year
+   if ( l<=numye-1 ) then
+      call me%intershc(year,dte1,nmax1,me%g,dte2,nmax2,me%gh2,me%nmax,gha)
+   else
+      call me%extrashc(year,dte1,nmax1,me%g,nmax2,me%gh2,me%nmax,gha)
+   endif
+   !-- determine magnetic dipol moment and coeffiecients g
+   f0 = 0.0_wp
+   do j = 1 , 3
+      f = gha(j)*1.0e-5_wp
+      f0 = f0 + f*f
+   enddo
+   dimo = sqrt(f0)
+
+   me%g(1) = 0.0_wp
+   i = 2
+   f0 = 1.0e-5_wp
+   if ( is==0 ) f0 = -f0
+   sqrt2 = sqrt(2.0_wp)
+
+   do n = 1 , me%nmax
+      x = n
+      f0 = f0*x*x/(4.0_wp*x-2.0_wp)
+      if ( is==0 ) f0 = f0*(2.0_wp*x-1.0_wp)/x
+      f = f0*0.5_wp
+      if ( is==0 ) f = f*sqrt2
+      me%g(i) = gha(i-1)*f0
+      i = i + 1
+      do m = 1 , n
+         f = f*(x+m)/(x-m+1.0_wp)
+         if ( is==0 ) f = f*sqrt((x-m+1.0_wp)/(x+m))
+         me%g(i) = gha(i-1)*f
+         me%g(i+1) = gha(i)*f
+         i = i + 2
+      enddo
+   enddo
+
+end subroutine feldcof
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/feldg.html b/proc/feldg.html new file mode 100644 index 0000000..2a8af65 --- /dev/null +++ b/proc/feldg.html @@ -0,0 +1,736 @@ + + + + + + + + + + + + + feldg – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

feldg + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine feldg(me, glat, glon, alt, bnorth, beast, bdown, Babs) +

+ + +

Calculates earth magnetic field from spherical harmonics model

+

Reference

+

ref: g. kluge, european space operations centre, internal note 61, + 1970.

+

History

+
    +
  • changes (d. bilitza, nov 87):
  • +
  • field coefficients in binary data files instead of block data
  • +
  • calculates dipol moment
  • +
+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::glat +

geodetic latitude in degrees (north)

+
+ + real(kind=wp), + intent(in) + + ::glon +

geodetic longitude in degrees (east)

+
+ + real(kind=wp), + intent(in) + + ::alt +

altitude in km above sea level

+
+ + real(kind=wp), + intent(out) + + ::bnorth +

components of the field with respect +to the local geodetic coordinate system, with axis +pointing in the tangential plane to the north, east +and downward.

+
+ + real(kind=wp), + intent(out) + + ::beast +

components of the field with respect +to the local geodetic coordinate system, with axis +pointing in the tangential plane to the north, east +and downward.

+
+ + real(kind=wp), + intent(out) + + ::bdown +

components of the field with respect +to the local geodetic coordinate system, with axis +pointing in the tangential plane to the north, east +and downward.

+
+ + real(kind=wp), + intent(out) + + ::Babs +

magnetic field strength in gauss

+
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~feldg~~CallsGraph + + + +proc~feldg + +shellig_module::shellig_type%feldg + + + +feldc + +feldc + + + +proc~feldg->feldc + + + + + +feldi + +feldi + + + +proc~feldg->feldi + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~feldg~~CalledByGraph + + + +proc~feldg + +shellig_module::shellig_type%feldg + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~feldg + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
subroutine feldg(me,glat,glon,alt,bnorth,beast,bdown,babs)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: glat  !! geodetic latitude in degrees (north)
+   real(wp),intent(in) :: glon  !! geodetic longitude in degrees (east)
+   real(wp),intent(in) :: alt   !! altitude in km above sea level
+   real(wp),intent(out) :: bnorth, beast, bdown !! components of the field with respect
+                                                !! to the local geodetic coordinate system, with axis
+                                                !! pointing in the tangential plane to the north, east
+                                                !! and downward.
+   real(wp),intent(out) :: Babs !! magnetic field strength in gauss
+
+   real(wp) :: b(3) , brho , bxxx , &
+               byyy , bzzz , cp , ct , d , f , rho , &
+               rlat , rlon , rq , s , sp , st , t , v(3) , x , xxx , &
+               y , yyy , z , zzz
+   integer :: i , ih , ihmax , il , imax , is , k , last , m
+
+   !-- is records entry point
+   !
+   !*****entry point  feldg  to be used with geodetic co-ordinates
+         is=1
+         rlat=glat*umr
+         ct=sin(rlat)
+         st=cos(rlat)
+         d=sqrt(aquad-(aquad-bquad)*ct*ct)
+         rlon=glon*umr
+         cp=cos(rlon)
+         sp=sin(rlon)
+         zzz=(alt+bquad/d)*ct/era
+         rho=(alt+aquad/d)*st/era
+         xxx=rho*cp
+         yyy=rho*sp
+         goto 10
+
+   !*****entry point  feldc  to be used with cartesian co-ordinates
+   !        v(3)  cartesian coordinates in earth radii (6371.2 km)
+   !            x-axis pointing to equator at 0 longitude
+   !            y-axis pointing to equator at 90 long.
+   !            z-axis pointing to north pole
+         entry feldc(me,v,b)
+         is=2
+         xxx=v(1)
+         yyy=v(2)
+         zzz=v(3)
+
+   10    rq=1.0_wp/(xxx*xxx+yyy*yyy+zzz*zzz)
+         me%xi(1)=xxx*rq
+         me%xi(2)=yyy*rq
+         me%xi(3)=zzz*rq
+         goto 20
+
+   !*****entry point  feldi  used for l computation
+         entry feldi(me)
+         is=3
+   20    ihmax=me%nmax*me%nmax+1
+         last=ihmax+me%nmax+me%nmax
+         imax=me%nmax+me%nmax-1
+         do i=ihmax,last
+             me%h(i)=me%g(i)
+         end do
+         do k=1,3,2
+            i=imax
+            ih=ihmax
+            do
+               il=ih-i
+               f=2.0_wp/real(i-k+2, wp)
+               x=me%xi(1)*f
+               y=me%xi(2)*f
+               z=me%xi(3)*(f+f)
+               i=i-2
+               if ((i-1)>=0) then
+                  if ((i-1)>0) then
+                     do m=3,i,2
+                        me%h(il+m+1)=me%g(il+m+1)+z*me%h(ih+m+1)+x*(me%h(ih+m+3)-&
+                                     me%h(ih+m-1))-y*(me%h(ih+m+2)+me%h(ih+m-2))
+                        me%h(il+m)=me%g(il+m)+z*me%h(ih+m)+x*(me%h(ih+m+2)-&
+                                   me%h(ih+m-2))+y*(me%h(ih+m+3)+me%h(ih+m-1))
+                     end do
+                  end if
+                  me%h(il+2)=me%g(il+2)+z*me%h(ih+2)+x*me%h(ih+4)-y*(me%h(ih+3)+me%h(ih))
+                  me%h(il+1)=me%g(il+1)+z*me%h(ih+1)+y*me%h(ih+4)+x*(me%h(ih+3)-me%h(ih))
+               end if
+               me%h(il)=me%g(il)+z*me%h(ih)+2.0_wp*(x*me%h(ih+1)+y*me%h(ih+2))
+               ih=il
+               if (i<k) exit
+            end do
+         end do
+
+         if (is==3) return
+
+         s=0.5_wp*me%h(1)+2.0_wp*(me%h(2)*me%xi(3)+me%h(3)*me%xi(1)+me%h(4)*me%xi(2))
+         t=(rq+rq)*sqrt(rq)
+         bxxx=t*(me%h(3)-s*xxx)
+         byyy=t*(me%h(4)-s*yyy)
+         bzzz=t*(me%h(2)-s*zzz)
+         if (is==2) then
+            b(1)=bxxx
+            b(2)=byyy
+            b(3)=bzzz
+         else
+            babs=sqrt(bxxx*bxxx+byyy*byyy+bzzz*bzzz)
+            beast=byyy*cp-bxxx*sp
+            brho=byyy*sp+bxxx*cp
+            bnorth=bzzz*st-brho*ct
+            bdown=-bzzz*ct-brho*st
+         end if
+
+   end subroutine feldg
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/findb0.html b/proc/findb0.html new file mode 100644 index 0000000..09d8601 --- /dev/null +++ b/proc/findb0.html @@ -0,0 +1,674 @@ + + + + + + + + + + + + + findb0 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

findb0 + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine findb0(me, stps, bdel, value, bequ, rr0) +

+ + + +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::stps + +
+ + real(kind=wp), + intent(inout) + + ::bdel + +
+ + logical, + intent(out) + + ::value + +
+ + real(kind=wp), + intent(out) + + ::bequ + +
+ + real(kind=wp), + intent(out) + + ::rr0 + +
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~findb0~~CallsGraph + + + +proc~findb0 + +shellig_module::shellig_type%findb0 + + + +proc~stoer + + +shellig_module::shellig_type%stoer + + + + + +proc~findb0->proc~stoer + + + + + +feldi + +feldi + + + +proc~stoer->feldi + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~findb0~~CalledByGraph + + + +proc~findb0 + +shellig_module::shellig_type%findb0 + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~findb0 + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
    subroutine findb0(me,stps,bdel,value,bequ,rr0)
+
+      class(shellig_type),intent(inout) :: me
+      real(wp),intent(in) :: stps
+      real(wp),intent(inout) :: bdel
+      real(wp),intent(out) :: bequ
+      logical,intent(out) :: value
+      real(wp),intent(out) :: rr0
+
+      real(wp) :: b , bdelta , bmin , bold , bq1 , &
+                  bq2 , bq3 , p(8,4) , r1 , r2 , r3 , &
+                  rold , step , step12 , zz
+      integer :: i , irun , j , n
+
+      step=stps
+      irun=0
+
+      main : do
+        irun=irun+1
+        if (irun>5) then
+            value=.false.
+            exit main
+        endif
+        !*********************first three points
+        p(1,2)=me%sp(1)
+        p(2,2)=me%sp(2)
+        p(3,2)=me%sp(3)
+        step=-sign(step,p(3,2))
+        call me%stoer(p(1,2),bq2,r2)
+        p(1,3)=p(1,2)+0.5_wp*step*p(4,2)
+        p(2,3)=p(2,2)+0.5_wp*step*p(5,2)
+        p(3,3)=p(3,2)+0.5_wp*step
+        call me%stoer(p(1,3),bq3,r3)
+        p(1,1)=p(1,2)-step*(2.0_wp*p(4,2)-p(4,3))
+        p(2,1)=p(2,2)-step*(2.0_wp*p(5,2)-p(5,3))
+        p(3,1)=p(3,2)-step
+        call me%stoer(p(1,1),bq1,r1)
+        p(1,3)=p(1,2)+step*(20.0_wp*p(4,3)-3.*p(4,2)+p(4,1))/18.0_wp
+        p(2,3)=p(2,2)+step*(20.0_wp*p(5,3)-3.*p(5,2)+p(5,1))/18.0_wp
+        p(3,3)=p(3,2)+step
+        call me%stoer(p(1,3),bq3,r3)
+        !******************invert sense if required
+        if (bq3>bq1) then
+            step=-step
+            r3=r1
+            bq3=bq1
+            do i=1,5
+                zz=p(i,1)
+                p(i,1)=p(i,3)
+                p(i,3)=zz
+            end do
+        end if
+        !******************initialization
+        step12=step/12.0_wp
+        value=.true.
+        bmin=1.0e4_wp
+        bold=1.0e4_wp
+        !******************corrector (field line tracing)
+        n=0
+        corrector : do
+            p(1,3)=p(1,2)+step12*(5.0_wp*p(4,3)+8.0_wp*p(4,2)-p(4,1))
+            n=n+1
+            p(2,3)=p(2,2)+step12*(5.0_wp*p(5,3)+8.0_wp*p(5,2)-p(5,1))
+            !******************predictor (field line tracing)
+            p(1,4)=p(1,3)+step12*(23.0_wp*p(4,3)-16.0_wp*p(4,2)+5.0_wp*p(4,1))
+            p(2,4)=p(2,3)+step12*(23.0_wp*p(5,3)-16.0_wp*p(5,2)+5.0_wp*p(5,1))
+            p(3,4)=p(3,3)+step
+            call me%stoer(p(1,4),bq3,r3)
+            do j=1,3
+                do i=1,8
+                    p(i,j)=p(i,j+1)
+                end do
+            end do
+            b=sqrt(bq3)
+            if (b<bmin) bmin=b
+            if (b>bold) exit corrector
+            bold=b
+            rold=1.0_wp/r3
+            me%sp(1)=p(1,4)
+            me%sp(2)=p(2,4)
+            me%sp(3)=p(3,4)
+        end do corrector
+        if (bold/=bmin) value=.false.
+        bdelta=(b-bold)/bold
+        if (bdelta<=bdel) exit main
+        step=step/10.0_wp
+    end do main
+
+    rr0=rold
+    bequ=bold
+    bdel=bdelta
+
+  end subroutine findb0
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/get_flux.html b/proc/get_flux.html new file mode 100644 index 0000000..2594579 --- /dev/null +++ b/proc/get_flux.html @@ -0,0 +1,677 @@ + + + + + + + + + + + + + get_flux – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

get_flux + Function + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

public function get_flux(lon, lat, height, year, e, imname) result(flux) +

+ + +

Main routine.

+ + +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + real(kind=wp), + intent(in) + + ::lon + +
+ + real(kind=wp), + intent(in) + + ::lat + +
+ + real(kind=wp), + intent(in) + + ::height + +
+ + real(kind=wp), + intent(in) + + ::year + +
+ + real(kind=wp), + intent(in) + + ::e + +
+ + integer, + intent(in) + + ::imname + +
+ +

Return Value + + + real(kind=wp) + +

+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~get_flux~~CallsGraph + + + +proc~get_flux + +core::get_flux + + + +proc~aep8 + + +trmfun_module::trm_type%aep8 + + + + + +proc~get_flux->proc~aep8 + + + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~get_flux->proc~igrf + + + + + +proc~trara1 + + +trmfun_module::trm_type%trara1 + + + + + +proc~aep8->proc~trara1 + + + + + +proc~feldcof + + +shellig_module::shellig_type%feldcof + + + + + +proc~igrf->proc~feldcof + + + + + +proc~feldg + + +shellig_module::shellig_type%feldg + + + + + +proc~igrf->proc~feldg + + + + + +proc~findb0 + + +shellig_module::shellig_type%findb0 + + + + + +proc~igrf->proc~findb0 + + + + + +proc~shellg + + +shellig_module::shellig_type%shellg + + + + + +proc~igrf->proc~shellg + + + + + +proc~extrashc + + +shellig_module::shellig_type%extrashc + + + + + +proc~feldcof->proc~extrashc + + + + + +proc~getshc + + +shellig_module::shellig_type%getshc + + + + + +proc~feldcof->proc~getshc + + + + + +proc~intershc + + +shellig_module::shellig_type%intershc + + + + + +proc~feldcof->proc~intershc + + + + + +feldc + +feldc + + + +proc~feldg->feldc + + + + + +feldi + +feldi + + + +proc~feldg->feldi + + + + + +proc~stoer + + +shellig_module::shellig_type%stoer + + + + + +proc~findb0->proc~stoer + + + + + +proc~shellg->proc~stoer + + + + + +shellc + +shellc + + + +proc~shellg->shellc + + + + + +proc~trara2 + + +trmfun_module::trm_type%trara2 + + + + + +proc~trara1->proc~trara2 + + + + + +proc~stoer->feldi + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
   function get_flux(Lon,Lat,Height,Year,E,Imname) result(flux)
+
+      real(wp),intent(in) :: lon
+      real(wp),intent(in) :: lat
+      real(wp),intent(in) :: height
+      real(wp),intent(in) :: year
+      real(wp),intent(in) :: e
+      integer,intent(in) :: imname
+      real(wp) :: flux
+
+      real(wp) :: xl, bbx
+      type(trm_type) :: trm
+      type(shellig_type) :: igrf
+
+      call igrf%igrf(lon,lat,height,year,xl,bbx)
+      call trm%aep8(e,xl,bbx,imname,flux)
+
+   end function get_flux
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/getshc.html b/proc/getshc.html new file mode 100644 index 0000000..c08e8a5 --- /dev/null +++ b/proc/getshc.html @@ -0,0 +1,562 @@ + + + + + + + + + + + + + getshc – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

getshc + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine getshc(me, Fspec, Nmax, Erad, Gh, Ier) +

+ + +

Reads spherical harmonic coefficients from the specified + file into an array.

+

Author

+
    +
  • Version 1.01, A. Zunde, USGS, MS 964, + Box 25046 Federal Center, Denver, CO 80225
  • +
+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + character(len=*), + intent(in) + + ::Fspec +

File specification

+
+ + integer, + intent(out) + + ::Nmax +

Maximum degree and order of model

+
+ + real(kind=wp), + intent(out) + + ::Erad +

Earth's radius associated with the spherical +harmonic coefficients, in the same units as +elevation

+
+ + real(kind=wp), + intent(out), + dimension(*) + ::Gh +

Schmidt quasi-normal internal spherical +harmonic coefficients

+
+ + integer, + intent(out) + + ::Ier +

Error number:

+
    +
  • 0, no error
  • +
  • -2, records out of order
  • +
  • FORTRAN run-time error number
  • +
+
+ +
+
+
+

Called by

+
+
+
+ + + + + +proc~~getshc~~CalledByGraph + + + +proc~getshc + +shellig_module::shellig_type%getshc + + + +proc~feldcof + + +shellig_module::shellig_type%feldcof + + + + + +proc~feldcof->proc~getshc + + + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~feldcof + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
subroutine getshc(me,Fspec,Nmax,Erad,Gh,Ier)
+
+   class(shellig_type),intent(inout) :: me
+   character(len=*),intent(in) :: Fspec !! File specification
+   integer,intent(out) :: Nmax !! Maximum degree and order of model
+   real(wp),intent(out) :: Erad !! Earth's radius associated with the spherical
+                                !! harmonic coefficients, in the same units as
+                                !! elevation
+   real(wp),dimension(*),intent(out) :: Gh !! Schmidt quasi-normal internal spherical
+                                           !! harmonic coefficients
+   integer,intent(out) :: Ier !! Error number:
+                              !!
+                              !!  * 0, no error
+                              !!  * -2, records out of order
+                              !!  * FORTRAN run-time error number
+
+   integer :: iu !! logical unit number
+   real(wp) :: g , h
+   integer :: i , m , mm , n , nn
+
+   read_file : block
+      ! ---------------------------------------------------------------
+      !  Open coefficient file. Read past first header record.
+      !  Read degree and order of model and Earth's radius.
+      ! ---------------------------------------------------------------
+      OPEN (newunit=Iu,FILE=Fspec,STATUS='OLD',IOSTAT=Ier)
+      if (Ier/=0) then
+         write(*,*) 'Error opening file: '//trim(fspec)
+         exit read_file
+      end if
+      READ (Iu,*,IOSTAT=Ier)
+      if (Ier/=0) exit read_file
+      READ (Iu,*,IOSTAT=Ier) Nmax , Erad
+      if (Ier/=0) exit read_file
+
+      ! ---------------------------------------------------------------
+      !  Read the coefficient file, arranged as follows:
+      !
+      !          N     M     G     H
+      !          ----------------------
+      !            /   1     0    GH(1)  -
+      !           /  1     1    GH(2) GH(3)
+      !          /  2     0    GH(4)  -
+      !         /  2     1    GH(5) GH(6)
+      !      NMAX*(NMAX+3)/2   /  2     2    GH(7) GH(8)
+      !         records    \  3     0    GH(9)  -
+      !         \      .     .     .     .
+      !          \  .     .     .     .
+      !      NMAX*(NMAX+2)     \  .     .     .     .
+      !      elements in GH      \  NMAX  NMAX   .     .
+      !
+      !  N and M are, respectively, the degree and order of the
+      !  coefficient.
+      ! ---------------------------------------------------------------
+      i = 0
+      main: DO nn = 1 , Nmax
+         DO mm = 0 , nn
+            READ (Iu,*,IOSTAT=Ier) n , m , g , h
+            if (Ier/=0) exit main
+            IF ( nn/=n .OR. mm/=m ) THEN
+               Ier = -2
+               EXIT main
+            ENDIF
+            i = i + 1
+            Gh(i) = g
+            IF ( m/=0 ) THEN
+               i = i + 1
+               Gh(i) = h
+            ENDIF
+         ENDDO
+      ENDDO main
+
+   end block read_file
+
+   CLOSE (Iu)
+
+END subroutine getshc
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/igrf.html b/proc/igrf.html new file mode 100644 index 0000000..453d3c2 --- /dev/null +++ b/proc/igrf.html @@ -0,0 +1,759 @@ + + + + + + + + + + + + + igrf – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

igrf + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine igrf(me, lon, lat, height, year, xl, bbx) +

+ + +

Wrapper for IGRF functions.

+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::lon +

geodetic longitude in degrees (east)

+
+ + real(kind=wp), + intent(in) + + ::lat +

geodetic latitude in degrees (north)

+
+ + real(kind=wp), + intent(in) + + ::height +

altitude in km above sea level

+
+ + real(kind=wp), + intent(in) + + ::year +

decimal year for which geomagnetic field is to +be calculated (e.g.:1995.5 for day 185 of 1995)

+
+ + real(kind=wp), + intent(out) + + ::xl +

l-value

+
+ + real(kind=wp), + intent(out) + + ::bbx + +
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~igrf~~CallsGraph + + + +proc~igrf + +shellig_module::shellig_type%igrf + + + +proc~feldcof + + +shellig_module::shellig_type%feldcof + + + + + +proc~igrf->proc~feldcof + + + + + +proc~feldg + + +shellig_module::shellig_type%feldg + + + + + +proc~igrf->proc~feldg + + + + + +proc~findb0 + + +shellig_module::shellig_type%findb0 + + + + + +proc~igrf->proc~findb0 + + + + + +proc~shellg + + +shellig_module::shellig_type%shellg + + + + + +proc~igrf->proc~shellg + + + + + +proc~extrashc + + +shellig_module::shellig_type%extrashc + + + + + +proc~feldcof->proc~extrashc + + + + + +proc~getshc + + +shellig_module::shellig_type%getshc + + + + + +proc~feldcof->proc~getshc + + + + + +proc~intershc + + +shellig_module::shellig_type%intershc + + + + + +proc~feldcof->proc~intershc + + + + + +feldc + +feldc + + + +proc~feldg->feldc + + + + + +feldi + +feldi + + + +proc~feldg->feldi + + + + + +proc~stoer + + +shellig_module::shellig_type%stoer + + + + + +proc~findb0->proc~stoer + + + + + +proc~shellg->proc~stoer + + + + + +shellc + +shellc + + + +proc~shellg->shellc + + + + + +proc~stoer->feldi + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~igrf~~CalledByGraph + + + +proc~igrf + +shellig_module::shellig_type%igrf + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
   subroutine igrf(me,lon,lat,height,year,xl,bbx)
+
+      class(shellig_type),intent(inout) :: me
+      real(wp),intent(in) :: lon !! geodetic longitude in degrees (east)
+      real(wp),intent(in) :: lat !! geodetic latitude in degrees (north)
+      real(wp),intent(in) :: height !! altitude in km above sea level
+      real(wp),intent(in) :: year !! decimal year for which geomagnetic field is to
+                                  !! be calculated (e.g.:1995.5 for day 185 of 1995)
+      real(wp),intent(out) :: xl !! l-value
+      real(wp),intent(out) :: bbx
+
+      real(wp) :: bab1 , babs , bdel , bdown , beast , &
+                  beq , bequ , bnorth , dimo , rr0
+      integer :: icode
+      logical :: val
+
+      real(wp),parameter :: stps = 0.05_wp
+
+      call me%feldcof(year,dimo)
+      call me%feldg(lat,lon,height,bnorth,beast,bdown,babs)
+      call me%shellg(lat,lon,height,dimo,xl,icode,bab1)
+
+      bequ = dimo/(xl*xl*xl)
+      if ( icode==1 ) then
+         bdel = 1.0e-3_wp
+         call me%findb0(stps,bdel,val,beq,rr0)
+         if ( val ) bequ = beq
+      endif
+      bbx = babs/bequ
+
+   end subroutine igrf
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/intershc.html b/proc/intershc.html new file mode 100644 index 0000000..cbfbeed --- /dev/null +++ b/proc/intershc.html @@ -0,0 +1,585 @@ + + + + + + + + + + + + + intershc – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

intershc + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine intershc(me, date, dte1, nmax1, gh1, dte2, nmax2, gh2, nmax, gh) +

+ + +

Interpolates linearly, in time, between two spherical + harmonic models.

+

The coefficients (GH) of the resulting model, at date + DATE, are computed by linearly interpolating between the + coefficients of the earlier model (GH1), at date DTE1, + and those of the later model (GH2), at date DTE2. If one + model is smaller than the other, the interpolation is + performed with the missing coefficients assumed to be 0.

+

Author

+
    +
  • Version 1.01, A. Zunde + USGS, MS 964, Box 25046 Federal Center, Denver, CO 80225
  • +
+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::date +

Date of resulting model (in decimal year)

+
+ + real(kind=wp), + intent(in) + + ::dte1 +

Date of earlier model

+
+ + integer, + intent(in) + + ::nmax1 +

Maximum degree and order of earlier model

+
+ + real(kind=wp), + intent(in) + + ::gh1(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of earlier model

+
+ + real(kind=wp), + intent(in) + + ::dte2 +

Date of later model

+
+ + integer, + intent(in) + + ::nmax2 +

Maximum degree and order of later model

+
+ + real(kind=wp), + intent(in) + + ::gh2(*) +

Schmidt quasi-normal internal spherical harmonic coefficients of later model

+
+ + integer, + intent(out) + + ::nmax +

Maximum degree and order of resulting model

+
+ + real(kind=wp), + intent(out) + + ::gh(*) +

Coefficients of resulting model

+
+ +
+
+
+

Called by

+
+
+
+ + + + + +proc~~intershc~~CalledByGraph + + + +proc~intershc + +shellig_module::shellig_type%intershc + + + +proc~feldcof + + +shellig_module::shellig_type%feldcof + + + + + +proc~feldcof->proc~intershc + + + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~feldcof + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
subroutine intershc(me,date,dte1,nmax1,gh1,dte2,nmax2,gh2,nmax,gh)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: date !! Date of resulting model (in decimal year)
+   real(wp),intent(in) :: dte1 !! Date of earlier model
+   integer,intent(in) :: nmax1 !! Maximum degree and order of earlier model
+   real(wp),intent(in) :: gh1(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of earlier model
+   real(wp),intent(in) :: dte2 !! Date of later model
+   integer,intent(in) :: nmax2 !! Maximum degree and order of later model
+   real(wp),intent(in) :: gh2(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of later model
+   real(wp),intent(out) :: gh(*) !! Coefficients of resulting model
+   integer,intent(out) :: nmax !! Maximum degree and order of resulting model
+
+   real(wp) :: factor
+   integer :: i , k , l
+
+   factor = (date-dte1)/(dte2-dte1)
+
+   if ( nmax1==nmax2 ) then
+      k = nmax1*(nmax1+2)
+      nmax = nmax1
+   elseif ( nmax1>nmax2 ) then
+      k = nmax2*(nmax2+2)
+      l = nmax1*(nmax1+2)
+      do i = k + 1 , l
+         gh(i) = gh1(i) + factor*(-gh1(i))
+      enddo
+      nmax = nmax1
+   else
+      k = nmax1*(nmax1+2)
+      l = nmax2*(nmax2+2)
+      do i = k + 1 , l
+         gh(i) = factor*gh2(i)
+      enddo
+      nmax = nmax2
+   endif
+
+   do i = 1 , k
+      gh(i) = gh1(i) + factor*(gh2(i)-gh1(i))
+   enddo
+
+end subroutine intershc
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/shellg.html b/proc/shellg.html new file mode 100644 index 0000000..34131da --- /dev/null +++ b/proc/shellg.html @@ -0,0 +1,873 @@ + + + + + + + + + + + + + shellg – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

shellg + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine shellg(me, glat, glon, alt, dimo, fl, icode, b0) +

+ + +

calculates l-value for specified geodaetic coordinates, altitude + and gemagnetic field model.

+

Reference

+
    +
  • G. KLUGE, EUROPEAN SPACE OPERATIONS CENTER, INTERNAL NOTE + NO. 67, 1970.
  • +
  • G. KLUGE, COMPUTER PHYSICS COMMUNICATIONS 3, 31-35, 1972
  • +
+

History

+
    +
  • CHANGES (D. BILITZA, NOV 87):
  • +
  • USING CORRECT DIPOL MOMENT I.E.,DIFFERENT COMMON/MODEL/
  • +
  • USING IGRF EARTH MAGNETIC FIELD MODELS FROM 1945 TO 1990
  • +
+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(in) + + ::glat +

GEODETIC LATITUDE IN DEGREES (NORTH)

+
+ + real(kind=wp), + intent(in) + + ::glon +

GEODETIC LONGITUDE IN DEGREES (EAST)

+
+ + real(kind=wp), + intent(in) + + ::alt +

ALTITUDE IN KM ABOVE SEA LEVEL

+
+ + real(kind=wp), + intent(in) + + ::dimo +

DIPOL MOMENT IN GAUSS (NORMALIZED TO EARTH RADIUS)

+
+ + real(kind=wp), + intent(out) + + ::fl +

l-value

+
+ + integer, + intent(out) + + ::icode +
    +
  • =1 normal completion
  • +
  • =2 unphysical conjugate point (fl meaningless)
  • +
  • =3 shell parameter greater than limit up to + which accurate calculation is required; + approximation is used.
  • +
+
+ + real(kind=wp), + intent(out) + + ::b0 +

magnetic field strength in gauss

+
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~shellg~~CallsGraph + + + +proc~shellg + +shellig_module::shellig_type%shellg + + + +proc~stoer + + +shellig_module::shellig_type%stoer + + + + + +proc~shellg->proc~stoer + + + + + +shellc + +shellc + + + +proc~shellg->shellc + + + + + +feldi + +feldi + + + +proc~stoer->feldi + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~shellg~~CalledByGraph + + + +proc~shellg + +shellig_module::shellig_type%shellg + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~shellg + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
  subroutine shellg(me,glat,glon,alt,dimo,fl,icode,b0)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: glat !! GEODETIC LATITUDE IN DEGREES (NORTH)
+   real(wp),intent(in) :: glon !! GEODETIC LONGITUDE IN DEGREES (EAST)
+   real(wp),intent(in) :: alt  !! ALTITUDE IN KM ABOVE SEA LEVEL
+   real(wp),intent(in) :: dimo !! DIPOL MOMENT IN GAUSS (NORMALIZED TO EARTH RADIUS)
+   real(wp),intent(out) :: fl  !! l-value
+   integer,intent(out) :: icode  !! * =1 normal completion
+                                 !! * =2 unphysical conjugate point (fl meaningless)
+                                 !! * =3 shell parameter greater than limit up to
+                                 !!   which accurate calculation is required;
+                                 !!   approximation is used.
+   real(wp),intent(out) :: b0 !! magnetic field strength in gauss
+
+   real(wp) :: arg1 , arg2 , bequ , bq1 , bq2 , bq3 , c0 , c1 , c2 , c3 , &
+               ct , d , d0 , d1 , d2, dimob0 , e0 , e1 , e2 , ff , fi , gg , &
+               hli , oradik , oterm , p(8,100) , r , r1 , r2 , r3 , r3h , radik , &
+               rlat , rlon , rq , st , step12 , step2 , &
+               stp , t , term , v(3) , xx , z , zq , zz
+   integer :: i , iequ , n
+
+   real(wp),parameter :: rmin = 0.05_wp !! boundaries for identification of `icode=2 and 3`
+   real(wp),parameter :: rmax = 1.01_wp !! boundaries for identification of `icode=2 and 3`
+
+   bequ = 1.0e10_wp
+
+   !*****ENTRY POINT SHELLG TO BE USED WITH GEODETIC CO-ORDINATES
+   rlat = Glat*Umr
+   ct = sin(rlat)
+   st = cos(rlat)
+   d = sqrt(Aquad-(Aquad-Bquad)*ct*ct)
+   me%Xi(1) = (Alt+Aquad/d)*st/Era
+   me%Xi(3) = (Alt+Bquad/d)*ct/Era
+   rlon = Glon*Umr
+   me%Xi(2) = me%Xi(1)*sin(rlon)
+   me%Xi(1) = me%Xi(1)*cos(rlon)
+   CALL spag_block_1()
+   RETURN
+
+!*****ENTRY POINT SHELLC TO BE USED WITH CARTESIAN CO-ORDINATES   ! JW : does not appear to be used anywhere.
+!    V(3)  CARTESIAN COORDINATES IN EARTH RADII (6371.2 KM)
+!      X-AXIS POINTING TO EQUATOR AT 0 LONGITUDE
+!      Y-AXIS POINTING TO EQUATOR AT 90 LONG.
+!      Z-AXIS POINTING TO NORTH POLE
+   ENTRY shellc(me,V,Fl,B0)
+   me%Xi(1) = V(1)
+   me%Xi(2) = V(2)
+   me%Xi(3) = V(3)
+   CALL spag_block_1()
+
+CONTAINS
+
+   subroutine spag_block_1
+
+      integer,parameter :: max_loop_index = 100  ! 3333   <--- JW : original code had 3333 ... was this a bug ????
+
+      !*****CONVERT TO DIPOL-ORIENTED CO-ORDINATES
+      rq = 1.0_wp/(me%Xi(1)*me%Xi(1)+me%Xi(2)*me%Xi(2)+me%Xi(3)*me%Xi(3))
+      r3h = sqrt(rq*sqrt(rq))
+      p(1,2) = (me%Xi(1)*u(1,1)+me%Xi(2)*u(2,1)+me%Xi(3)*u(3,1))*r3h
+      p(2,2) = (me%Xi(1)*u(1,2)+me%Xi(2)*u(2,2))*r3h
+      p(3,2) = (me%Xi(1)*u(1,3)+me%Xi(2)*u(2,3)+me%Xi(3)*u(3,3))*rq
+      !     *****FIRST THREE POINTS OF FIELD LINE
+      me%step = -sign(me%step,p(3,2))
+      call me%stoer(p(1,2),bq2,r2)
+      B0 = sqrt(bq2)
+      p(1,3) = p(1,2) + 0.5_wp*me%step*p(4,2)
+      p(2,3) = p(2,2) + 0.5_wp*me%step*p(5,2)
+      p(3,3) = p(3,2) + 0.5_wp*me%step
+      call me%stoer(p(1,3),bq3,r3)
+      p(1,1) = p(1,2) - me%step*(2.0_wp*p(4,2)-p(4,3))
+      p(2,1) = p(2,2) - me%step*(2.0_wp*p(5,2)-p(5,3))
+      p(3,1) = p(3,2) - me%step
+      call me%stoer(p(1,1),bq1,r1)
+      p(1,3) = p(1,2) + me%step*(20.0_wp*p(4,3)-3.*p(4,2)+p(4,1))/18.0_wp
+      p(2,3) = p(2,2) + me%step*(20.0_wp*p(5,3)-3.*p(5,2)+p(5,1))/18.0_wp
+      p(3,3) = p(3,2) + me%step
+      call me%stoer(p(1,3),bq3,r3)
+      !*****INVERT SENSE IF REQUIRED
+      IF ( bq3>bq1 ) THEN
+         me%step = -me%step
+         r3 = r1
+         bq3 = bq1
+         DO i = 1 , 7
+            zz = p(i,1)
+            p(i,1) = p(i,3)
+            p(i,3) = zz
+         ENDDO
+      ENDIF
+      !*****SEARCH FOR LOWEST MAGNETIC FIELD STRENGTH
+      IF ( bq1<bequ ) THEN
+         bequ = bq1
+         iequ = 1
+      ENDIF
+      IF ( bq2<bequ ) THEN
+         bequ = bq2
+         iequ = 2
+      ENDIF
+      IF ( bq3<bequ ) THEN
+         bequ = bq3
+         iequ = 3
+      ENDIF
+      !*****INITIALIZATION OF INTEGRATION LOOPS
+      step12 = me%step/12.0_wp
+      step2 = me%step + me%step
+      me%steq = sign(me%steq,me%step)
+      fi = 0.0_wp
+      Icode = 1
+      oradik = 0.0_wp
+      oterm = 0.0_wp
+      stp = r2*me%steq
+      z = p(3,2) + stp
+      stp = stp/0.75_wp
+      p(8,1) = step2*(p(1,1)*p(4,1)+p(2,1)*p(5,1))
+      p(8,2) = step2*(p(1,2)*p(4,2)+p(2,2)*p(5,2))
+      !*****MAIN LOOP (FIELD LINE TRACING)
+      main: DO n = 3 , max_loop_index
+         !*****CORRECTOR (FIELD LINE TRACING)
+         p(1,n) = p(1,n-1) + step12*(5.0_wp*p(4,n)+8.0_wp*p(4,n-1)-p(4,n-2))
+         p(2,n) = p(2,n-1) + step12*(5.0_wp*p(5,n)+8.0_wp*p(5,n-1)-p(5,n-2))
+         !*****PREPARE EXPANSION COEFFICIENTS FOR INTERPOLATION
+         !*****OF SLOWLY VARYING QUANTITIES
+         p(8,n) = step2*(p(1,n)*p(4,n)+p(2,n)*p(5,n))
+         c0 = p(1,n-1)**2 + p(2,n-1)**2
+         c1 = p(8,n-1)
+         c2 = (p(8,n)-p(8,n-2))*0.25_wp
+         c3 = (p(8,n)+p(8,n-2)-c1-c1)/6.0_wp
+         d0 = p(6,n-1)
+         d1 = (p(6,n)-p(6,n-2))*0.5_wp
+         d2 = (p(6,n)+p(6,n-2)-d0-d0)*0.5_wp
+         e0 = p(7,n-1)
+         e1 = (p(7,n)-p(7,n-2))*0.5_wp
+         e2 = (p(7,n)+p(7,n-2)-e0-e0)*0.5_wp
+         inner: DO
+            !*****INNER LOOP (FOR QUADRATURE)
+            t = (z-p(3,n-1))/me%step
+            IF ( t>1.0_wp ) THEN
+               !*****PREDICTOR (FIELD LINE TRACING)
+               p(1,n+1) = p(1,n) + step12*(23.0_wp*p(4,n)-16.0_wp*p(4,n-1)+5.0_wp*p(4,n-2))
+               p(2,n+1) = p(2,n) + step12*(23.0_wp*p(5,n)-16.0_wp*p(5,n-1)+5.0_wp*p(5,n-2))
+               p(3,n+1) = p(3,n) + me%step
+               call me%stoer(p(1,n+1),bq3,r3)
+               !*****SEARCH FOR LOWEST MAGNETIC FIELD STRENGTH
+               IF ( bq3<bequ ) THEN
+                  iequ = n + 1
+                  bequ = bq3
+               ENDIF
+               EXIT inner
+            ELSE
+               hli = 0.5_wp*(((c3*t+c2)*t+c1)*t+c0)
+               zq = z*z
+               r = hli + sqrt(hli*hli+zq)
+               IF ( r<=rmin ) THEN
+                  !*****APPROXIMATION FOR HIGH VALUES OF L.
+                  Icode = 3
+                  t = -p(3,n-1)/me%step
+                  Fl = 1.0_wp/(abs(((c3*t+c2)*t+c1)*t+c0)+1.0e-15_wp)
+                  RETURN
+               ENDIF
+               rq = r*r
+               ff = sqrt(1.0_wp+3.0_wp*zq/rq)
+               radik = B0 - ((d2*t+d1)*t+d0)*r*rq*ff
+               IF ( r>rmax ) THEN
+                  Icode = 2
+                  radik = radik - 12.0_wp*(r-rmax)**2
+               ENDIF
+               IF ( radik+radik<=oradik ) EXIT main
+               term = sqrt(radik)*ff*((e2*t+e1)*t+e0)/(rq+zq)
+               fi = fi + stp*(oterm+term)
+               oradik = radik
+               oterm = term
+               stp = r*me%steq
+               z = z + stp
+            ENDIF
+         ENDDO inner
+      ENDDO main
+      IF ( iequ<2 ) iequ = 2
+      me%Sp(1) = p(1,iequ-1)
+      me%Sp(2) = p(2,iequ-1)
+      me%Sp(3) = p(3,iequ-1)
+      IF ( oradik>=1.0e-15_wp ) fi = fi + stp/0.75_wp*oterm*oradik/(oradik-radik)
+      !
+      !-- The minimal allowable value of FI was changed from 1E-15 to 1E-12,
+      !-- because 1E-38 is the minimal allowable arg. for ALOG in our envir.
+      !-- D. Bilitza, Nov 87.
+      !
+      fi = 0.5_wp*abs(fi)/sqrt(B0) + 1.0e-12_wp
+      !*****COMPUTE L FROM B AND I.  SAME AS CARMEL IN INVAR.
+      !
+      !-- Correct dipole moment is used here. D. Bilitza, Nov 87.
+      !
+      dimob0 = Dimo/B0
+      arg1 = log(fi)
+      arg2 = log(dimob0)
+!       arg = FI*FI*FI/DIMOB0
+!       if(abs(arg)>88.0_wp) arg=88.0_wp
+      xx = 3*arg1 - arg2
+      IF ( xx>23.0_wp ) THEN
+         gg = xx - 3.0460681_wp
+      ELSEIF ( xx>11.7_wp ) THEN
+         gg = (((((2.8212095E-8_wp*xx-3.8049276E-6_wp)*xx+&
+                   2.170224E-4_wp)*xx-6.7310339E-3_wp)*xx+&
+                   1.2038224E-1_wp)*xx-1.8461796E-1_wp)*xx + 2.0007187_wp
+      ELSEIF ( xx>+3.0_wp ) THEN
+         gg = ((((((((6.3271665E-10_wp*xx-3.958306E-8_wp)*xx+&
+                      9.9766148E-07_wp)*xx-1.2531932E-5_wp)*xx+&
+                      7.9451313E-5_wp)*xx-3.2077032E-4_wp)*xx+&
+                      2.1680398E-3_wp)*xx+1.2817956E-2_wp)*xx+&
+                      4.3510529E-1_wp)*xx + 6.222355E-1_wp
+      ELSEIF ( xx>-3.0_wp ) THEN
+         gg = ((((((((2.6047023E-10_wp*xx+2.3028767E-9_wp)*xx-&
+                      2.1997983E-8_wp)*xx-5.3977642E-7_wp)*xx-&
+                      3.3408822E-6_wp)*xx+3.8379917E-5_wp)*xx+&
+                      1.1784234E-3_wp)*xx+1.4492441E-2_wp)*xx+&
+                      4.3352788E-1_wp)*xx + 6.228644E-1_wp
+      ELSEIF ( xx>-22.0_wp ) THEN
+         gg = ((((((((-8.1537735E-14_wp*xx+8.3232531E-13_wp)*xx+&
+                       1.0066362E-9_wp)*xx+8.1048663E-8_wp)*xx+&
+                       3.2916354E-6_wp)*xx+8.2711096E-5_wp)*xx+&
+                       1.3714667E-3_wp)*xx+1.5017245E-2_wp)*xx+&
+                       4.3432642E-1_wp)*xx + 6.2337691E-1_wp
+      ELSE
+         gg = 3.33338E-1_wp*xx + 3.0062102E-1_wp
+      ENDIF
+      Fl = exp(log((1.0_wp+exp(gg))*dimob0)/3.0_wp)
+      RETURN
+   END subroutine spag_block_1
+
+END subroutine shellg
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/stoer.html b/proc/stoer.html new file mode 100644 index 0000000..2ba87df --- /dev/null +++ b/proc/stoer.html @@ -0,0 +1,622 @@ + + + + + + + + + + + + + stoer – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

stoer + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine stoer(me, p, bq, r) +

+ + +

subroutine used for field line tracing in shellg +calls entry point feldi in geomagnetic field subroutine feldg

+ +

Type Bound

+

shellig_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(shellig_type), + intent(inout) + + ::me + +
+ + real(kind=wp), + intent(inout), + dimension(7) + ::p + +
+ + real(kind=wp), + intent(out) + + ::bq + +
+ + real(kind=wp), + intent(out) + + ::r + +
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~stoer~~CallsGraph + + + +proc~stoer + +shellig_module::shellig_type%stoer + + + +feldi + +feldi + + + +proc~stoer->feldi + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~stoer~~CalledByGraph + + + +proc~stoer + +shellig_module::shellig_type%stoer + + + +proc~findb0 + + +shellig_module::shellig_type%findb0 + + + + + +proc~findb0->proc~stoer + + + + + +proc~shellg + + +shellig_module::shellig_type%shellg + + + + + +proc~shellg->proc~stoer + + + + + +proc~igrf + + +shellig_module::shellig_type%igrf + + + + + +proc~igrf->proc~findb0 + + + + + +proc~igrf->proc~shellg + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~igrf + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
subroutine stoer(me,p,bq,r)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),dimension(7),intent(inout) :: p
+   real(wp),intent(out) :: bq
+   real(wp),intent(out) :: r
+
+   real(wp) :: dr , dsq , dx , dxm , dy , dym , dz , &
+               dzm , fli , q , rq , wr , xm , ym , zm
+
+!*****XM,YM,ZM ARE GEOMAGNETIC CARTESIAN INVERSE CO-ORDINATES
+   zm = P(3)
+   fli = P(1)*P(1) + P(2)*P(2) + 1.0e-15_wp
+   R = 0.5_wp*(fli+sqrt(fli*fli+(zm+zm)**2))
+   rq = R*R
+   wr = sqrt(R)
+   xm = P(1)*wr
+   ym = P(2)*wr
+!*****TRANSFORM TO GEOGRAPHIC CO-ORDINATE SYSTEM
+   me%Xi(1) = xm*u(1,1) + ym*u(1,2) + zm*u(1,3)
+   me%Xi(2) = xm*u(2,1) + ym*u(2,2) + zm*u(2,3)
+   me%Xi(3) = xm*u(3,1) + zm*u(3,3)
+!*****COMPUTE DERIVATIVES
+! Changed from CALL FELDI(XI,H); XI, H are in COMMON block; results
+! are the same; dkb Feb 1998.
+! JW : feb 2024 : xi, h now class variables.
+   CALL feldi(me)
+   q = me%H(1)/rq
+   dx = me%H(3) + me%H(3) + q*me%Xi(1)
+   dy = me%H(4) + me%H(4) + q*me%Xi(2)
+   dz = me%H(2) + me%H(2) + q*me%Xi(3)
+!*****TRANSFORM BACK TO GEOMAGNETIC CO-ORDINATE SYSTEM
+   dxm = u(1,1)*dx + u(2,1)*dy + u(3,1)*dz
+   dym = u(1,2)*dx + u(2,2)*dy
+   dzm = u(1,3)*dx + u(2,3)*dy + u(3,3)*dz
+   dr = (xm*dxm+ym*dym+zm*dzm)/R
+!*****FORM SLOWLY VARYING EXPRESSIONS
+   P(4) = (wr*dxm-0.5_wp*P(1)*dr)/(R*dzm)
+   P(5) = (wr*dym-0.5_wp*P(2)*dr)/(R*dzm)
+   dsq = rq*(dxm*dxm+dym*dym+dzm*dzm)
+   Bq = dsq*rq*rq
+   P(6) = sqrt(dsq/(rq+3.0_wp*zm*zm))
+   P(7) = P(6)*(rq+zm*zm)/(rq*dzm)
+END subroutine stoer
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/trara1.html b/proc/trara1.html new file mode 100644 index 0000000..91e1f6e --- /dev/null +++ b/proc/trara1.html @@ -0,0 +1,709 @@ + + + + + + + + + + + + + trara1 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

trara1 + Subroutine + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private subroutine trara1(me, descr, map, fl, bb0, e, f, n) +

+ + +

trara1 finds particle fluxes for given energies, magnetic field +strength and l-value. function trara2 is used to interpolate in +b-l-space.

+ +

Type Bound

+

trm_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(trm_type), + intent(inout) + + ::me + +
+ + integer, + intent(in) + + ::descr(8) +

header of specified trapped radition model

+
+ + integer, + intent(in) + + ::map(*) +

map of trapped radition model +(descr and map are explained at the begin +of the main program model)

+
+ + real(kind=wp), + intent(in) + + ::fl +

l-value

+
+ + real(kind=wp), + intent(in) + + ::bb0 +

=b/b0 magnetic field strength normalized +to field strength at magnetic equator

+
+ + real(kind=wp), + intent(in) + + ::e(n) +

array of energies in mev

+
+ + real(kind=wp), + intent(out) + + ::f(n) +

decadic logarithm of integral fluxes in +particles/(cmcmsec)

+
+ + integer, + intent(in) + + ::n +

number of energies

+
+ +
+
+
+

Calls

+
+
+
+ + + + + +proc~~trara1~~CallsGraph + + + +proc~trara1 + +trmfun_module::trm_type%trara1 + + + +proc~trara2 + + +trmfun_module::trm_type%trara2 + + + + + +proc~trara1->proc~trara2 + + + + + +
+ Help +
+ +
+
+
+
+

Called by

+
+
+
+ + + + + +proc~~trara1~~CalledByGraph + + + +proc~trara1 + +trmfun_module::trm_type%trara1 + + + +proc~aep8 + + +trmfun_module::trm_type%aep8 + + + + + +proc~aep8->proc~trara1 + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~aep8 + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
   subroutine trara1(me,descr,map,fl,bb0,e,f,n)
+
+   class(trm_type),intent(inout) :: me
+   integer,intent(in) :: n !! number of energies
+   integer,intent(in) :: descr(8) !! header of specified trapped radition model
+   real(wp),intent(in) :: e(n) !! array of energies in mev
+   real(wp),intent(in) :: fl !! l-value
+   real(wp),intent(in) :: bb0 !! =b/b0  magnetic field strength normalized
+                                 !! to field strength at magnetic equator
+   integer,intent(in) :: map(*) !! map of trapped radition model
+                                !! (descr and map are explained at the begin
+                                !! of the main program model)
+   real(wp),intent(out) :: f(n) !! decadic logarithm of integral fluxes in
+                                !! particles/(cm*cm*sec)
+
+   real(wp) :: e0 , e1 , e2 , escale , f0 , fscale , xnl
+   real(wp) :: bb0_ !! local copy of `bb0`. in the original code
+                    !! this was modified by this routine.
+                    !! added this so `bb0` could be `intent(in)`
+   integer :: i0 , i1 , i2 , i3 , ie , l3 , nb , nl
+   logical :: s0 , s1 , s2
+
+   bb0_ = bb0
+   me%fistep = descr(7)/descr(2)
+   escale = descr(4)
+   fscale = descr(7)
+   xnl = min(15.6_wp,abs(fl))
+   nl = xnl*descr(5)
+   if ( bb0_<1.0_wp ) bb0_ = 1.0_wp
+   nb = (bb0_-1.0_wp)*descr(6)
+
+   ! i2 is the number of elements in the flux map for the first energy.
+   ! i3 is the index of the last element of the second energy map.
+   ! l3 is the length of the map for the third energy.
+   ! e1 is the energy of the first energy map (unscaled)
+   ! e2 is the energy of the second energy map (unscaled)
+   i1 = 0
+   i2 = map(1)
+   i3 = i2 + map(i2+1)
+   l3 = map(i3+1)
+   e1 = map(i1+2)/escale
+   e2 = map(i2+2)/escale
+
+   ! s0, s1, s2 are logical variables which indicate whether the flux for
+   ! a particular e, b, l point has already been found in a previous call
+   ! to function trara2. if not, s.. =.true.
+   s1 = .true.
+   s2 = .true.
+
+   ! energy loop
+
+   do ie = 1 , n
+
+      ! for each energy e(i) find the successive energies e0,e1,e2 in
+      ! model map, which obey  e0 < e1 < e(i) < e2 .
+
+      do while ( (e(ie)>e2) .and. (l3/=0) )
+         i0 = i1
+         i1 = i2
+         i2 = i3
+         i3 = i3 + l3
+         l3 = map(i3+1)
+         e0 = e1
+         e1 = e2
+         e2 = map(i2+2)/escale
+         s0 = s1
+         s1 = s2
+         s2 = .true.
+         f0 = me%f1
+         me%f1 = me%f2
+      enddo
+
+      ! call trara2 to interpolate the flux-maps for e1,e2 in l-b/b0-
+      ! space to find fluxes f1,f2 [if they have not already been
+      ! calculated for a previous e(i)].
+
+      if ( s1 ) me%f1 = me%trara2(map(i1+3),nl,nb)/fscale
+      if ( s2 ) me%f2 = me%trara2(map(i2+3),nl,nb)/fscale
+      s1 = .false.
+      s2 = .false.
+
+      ! finally, interpolate in energy.
+
+      f(ie) = me%f1 + (me%f2-me%f1)*(e(ie)-e1)/(e2-e1)
+      if ( me%f2<=0.0_wp ) then
+         if ( i1/=0 ) then
+            ! --------- special interpolation ---------------------------------
+            ! if the flux for the second energy cannot be found (i.e. f2=0.0),
+            ! and the zeroth energy map has been defined (i.e. i1 not equal 0),
+            ! then interpolate using the flux maps for the zeroth and first
+            ! energy and choose the minimum of this interpolations and the
+            ! interpolation that was done with f2=0.
+            if ( s0 ) f0 = me%trara2(map(i0+3),nl,nb)/fscale
+            s0 = .false.
+            f(ie) = min(f(ie),f0+(me%f1-f0)*(e(ie)-e0)/(e1-e0))
+         endif
+      endif
+
+      ! the logarithmic flux is always kept greater or equal zero.
+
+      f(ie) = max(f(ie),0.0_wp)
+   enddo
+end subroutine trara1
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/proc/trara2.html b/proc/trara2.html new file mode 100644 index 0000000..2fd8c87 --- /dev/null +++ b/proc/trara2.html @@ -0,0 +1,655 @@ + + + + + + + + + + + + + trara2 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

trara2 + Function + +

+
+
+
+ +
+
+ +
+
+
+ + +
+ +
+ + +
+

private function trara2(me, map, il, ib) +

+ + +

trara2 interpolates linearly in l-b/b0-map to obtain + the logarithm of integral flux at given l and b/b0.

+

Note

+

see main program 'model' for explanation of map format + scaling factors.

+ +

Type Bound

+

trm_type

+ +

Arguments

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypeIntentOptional AttributesName
+ + class(trm_type), + intent(inout) + + ::me + +
+ + integer, + intent(in) + + ::map(*) +

is sub-map (for specific energy) of +trapped radiation model map

+
+ + integer, + intent(in) + + ::il +

scaled l-value

+
+ + integer, + intent(in) + + ::ib +

scaled b/b0-1

+
+ +

Return Value + + + real(kind=wp) + +

+

scaled logarithm of particle flux

+
+
+
+

Called by

+
+
+
+ + + + + +proc~~trara2~~CalledByGraph + + + +proc~trara2 + +trmfun_module::trm_type%trara2 + + + +proc~trara1 + + +trmfun_module::trm_type%trara1 + + + + + +proc~trara1->proc~trara2 + + + + + +proc~aep8 + + +trmfun_module::trm_type%aep8 + + + + + +proc~aep8->proc~trara1 + + + + + +proc~get_flux + + +core::get_flux + + + + + +proc~get_flux->proc~aep8 + + + + + +
+ Help +
+ +
+
+
+ + + + + + + + + + + +
+

Source Code

+
function trara2(me,map,il,ib)
+
+   class(trm_type),intent(inout) :: me
+   integer,intent(in) :: map(*) !! is sub-map (for specific energy) of
+                                !! trapped radiation model map
+   integer,intent(in) :: il !! scaled l-value
+   integer,intent(in) :: ib !! scaled b/b0-1
+   real(wp) :: trara2 !! scaled logarithm of particle flux
+
+   real(wp) :: dfl , fincr1 , fincr2 , fistep , fkb , fkb1 , fkb2 , fkbj1 , fkbj2 , &
+               fkbm , fll1 , fll2 , flog , flog1 , flog2 , flogm , &
+               fnb , fnl , sl1 , sl2
+   integer :: i1 , i2 , itime , j1 , j2 , kt , l1 , l2
+
+   integer :: spag_nextblock_1
+
+   fistep = me%fistep
+
+   spag_nextblock_1 = 1
+   main: do
+      select case (spag_nextblock_1)
+      case (1)
+         fnl = il
+         fnb = ib
+         itime = 0
+         i2 = 0
+         do
+
+            ! find consecutive sub-sub-maps for scaled l-values ls1,ls2,
+            ! with il less or equal ls2.  l1,l2 are lengths of sub-sub-maps.
+            ! i1,i2 are indeces of first elements minus 1.
+
+            l2 = map(i2+1)
+            if ( map(i2+2)<=il ) then
+               i1 = i2
+               l1 = l2
+               i2 = i2 + l2
+
+               ! if sub-sub-maps are empty, i. e. length less 4, than trara2=0
+
+            elseif ( (l1<4) .and. (l2<4) ) then
+               trara2 = 0.0_wp
+               return
+            else
+
+               ! if flog2 less flog1, than ls2 first map and ls1 second map
+
+               if ( map(i2+3)<=map(i1+3) ) exit
+               spag_nextblock_1 = 3
+               cycle main
+            endif
+         enddo
+         spag_nextblock_1 = 2
+      case (2)
+         kt = i1
+         i1 = i2
+         i2 = kt
+         kt = l1
+         l1 = l2
+         l2 = kt
+         spag_nextblock_1 = 3
+      case (3)
+
+         ! determine interpolate in scaled l-value
+
+         fll1 = map(i1+2)
+         fll2 = map(i2+2)
+         dfl = (fnl-fll1)/(fll2-fll1)
+         flog1 = map(i1+3)
+         flog2 = map(i2+3)
+         fkb1 = 0.0_wp
+         fkb2 = 0.0_wp
+         if ( l1>=4 ) then
+
+            ! b/b0 loop
+
+            do j2 = 4 , l2
+               fincr2 = map(i2+j2)
+               if ( fkb2+fincr2>fnb ) goto 10
+               fkb2 = fkb2 + fincr2
+               flog2 = flog2 - fistep
+            enddo
+            itime = itime + 1
+            if ( itime==1 ) then
+               spag_nextblock_1 = 2
+               cycle main
+            endif
+            trara2 = 0.0_wp
+            return
+ 10         if ( itime/=1 ) then
+               if ( j2==4 ) then
+                  spag_nextblock_1 = 4
+                  cycle main
+               endif
+               sl2 = flog2/fkb2
+               do j1 = 4 , l1
+                  fincr1 = map(i1+j1)
+                  fkb1 = fkb1 + fincr1
+                  flog1 = flog1 - fistep
+                  fkbj1 = ((flog1/fistep)*fincr1+fkb1)/((fincr1/fistep)*sl2+1.0_wp)
+                  if ( fkbj1<=fkb1 ) goto 15
+               enddo
+               if ( fkbj1<=fkb2 ) then
+                  trara2 = 0.0_wp
+                  return
+               endif
+ 15            if ( fkbj1<=fkb2 ) then
+                  fkbm = fkbj1 + (fkb2-fkbj1)*dfl
+                  flogm = fkbm*sl2
+                  flog2 = flog2 - fistep
+                  fkb2 = fkb2 + fincr2
+                  sl1 = flog1/fkb1
+                  sl2 = flog2/fkb2
+                  spag_nextblock_1 = 5
+                  cycle main
+               else
+                  fkb1 = 0.0_wp
+               endif
+            endif
+            fkb2 = 0.0_wp
+         endif
+         j2 = 4
+         fincr2 = map(i2+j2)
+         flog2 = map(i2+3)
+         flog1 = map(i1+3)
+         spag_nextblock_1 = 4
+      case (4)
+         flogm = flog1 + (flog2-flog1)*dfl
+         fkbm = 0.0_wp
+         fkb2 = fkb2 + fincr2
+         flog2 = flog2 - fistep
+         sl2 = flog2/fkb2
+         if ( l1<4 ) then
+            fincr1 = 0.0_wp
+            sl1 = -900000.0_wp
+            spag_nextblock_1 = 6
+            cycle main
+         else
+            j1 = 4
+            fincr1 = map(i1+j1)
+            fkb1 = fkb1 + fincr1
+            flog1 = flog1 - fistep
+            sl1 = flog1/fkb1
+         endif
+         spag_nextblock_1 = 5
+      case (5)
+         do while ( sl1>=sl2 )
+            fkbj2 = ((flog2/fistep)*fincr2+fkb2)/((fincr2/fistep)*sl1+1.0_wp)
+            fkb = fkb1 + (fkbj2-fkb1)*dfl
+            flog = fkb*sl1
+            if ( fkb>=fnb ) then
+               spag_nextblock_1 = 7
+               cycle main
+            endif
+            fkbm = fkb
+            flogm = flog
+            if ( j1>=l1 ) then
+               trara2 = 0.0_wp
+               return
+            else
+               j1 = j1 + 1
+               fincr1 = map(i1+j1)
+               flog1 = flog1 - fistep
+               fkb1 = fkb1 + fincr1
+               sl1 = flog1/fkb1
+            endif
+         enddo
+         spag_nextblock_1 = 6
+      case (6)
+         fkbj1 = ((flog1/fistep)*fincr1+fkb1)/((fincr1/fistep)*sl2+1.0_wp)
+         fkb = fkbj1 + (fkb2-fkbj1)*dfl
+         flog = fkb*sl2
+         if ( fkb<fnb ) then
+            fkbm = fkb
+            flogm = flog
+            if ( j2>=l2 ) then
+               trara2 = 0.0_wp
+               return
+            else
+               j2 = j2 + 1
+               fincr2 = map(i2+j2)
+               flog2 = flog2 - fistep
+               fkb2 = fkb2 + fincr2
+               sl2 = flog2/fkb2
+               spag_nextblock_1 = 5
+               cycle main
+            endif
+         endif
+         spag_nextblock_1 = 7
+      case (7)
+         if ( fkb<fkbm+1.0e-10_wp ) then
+            trara2 = 0.0_wp
+         else
+            trara2 = flogm + (flog-flogm)*((fnb-fkbm)/(fkb-fkbm))
+            trara2 = max(trara2,0.0_wp)
+            return
+         endif
+         exit main
+      end select
+   enddo main
+
+end function trara2
+
+ +
+
+ +
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/search.html b/search.html new file mode 100644 index 0000000..e952ae0 --- /dev/null +++ b/search.html @@ -0,0 +1,127 @@ + + + + + + + + + + + Search Results – radbelt + + + + + + + + + + + + + + + +
+ +
+ +
+
+
+

Search Results

+
+
+
+ + +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sourcefile/core.f90.html b/sourcefile/core.f90.html new file mode 100644 index 0000000..385572e --- /dev/null +++ b/sourcefile/core.f90.html @@ -0,0 +1,375 @@ + + + + + + + + + + + + + core.f90 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

core.f90 + Source File + +

+
+
+
+ +
+
+ +
+
+
+ + +
+
+ +
+ +
+
+
+

This file depends on

+
+
+
+ + + + + +sourcefile~~core.f90~~EfferentGraph + + + +sourcefile~core.f90 + +core.f90 + + + +sourcefile~radbelt_kinds_module.f90 + + +radbelt_kinds_module.F90 + + + + + +sourcefile~core.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +sourcefile~shellig.f90 + + +shellig.f90 + + + + + +sourcefile~core.f90->sourcefile~shellig.f90 + + + + + +sourcefile~trmfun.f90 + + +trmfun.f90 + + + + + +sourcefile~core.f90->sourcefile~trmfun.f90 + + + + + +sourcefile~shellig.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +sourcefile~trmfun.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +
+ Help +
+ +
+
+
+
+

Source Code

+
!*****************************************************************************************
+!>
+!  Main module.
+!
+!### See also
+!   * https://ccmc.gsfc.nasa.gov/pub/modelweb/geomagnetic/igrf/fortran_code/bilcal.for
+!   * https://ccmc.gsfc.nasa.gov/pub/modelweb/radiation_belt/radbelt/fortran_code/radbelt.for
+
+module core
+
+   use radbelt_kinds_module
+   use trmfun_module
+   use shellig_module
+
+   implicit none
+
+   public :: get_flux
+
+   contains
+
+!*****************************************************************************************
+!>
+!  Main routine.
+
+   function get_flux(Lon,Lat,Height,Year,E,Imname) result(flux)
+
+      real(wp),intent(in) :: lon
+      real(wp),intent(in) :: lat
+      real(wp),intent(in) :: height
+      real(wp),intent(in) :: year
+      real(wp),intent(in) :: e
+      integer,intent(in) :: imname
+      real(wp) :: flux
+
+      real(wp) :: xl, bbx
+      type(trm_type) :: trm
+      type(shellig_type) :: igrf
+
+      call igrf%igrf(lon,lat,height,year,xl,bbx)
+      call trm%aep8(e,xl,bbx,imname,flux)
+
+   end function get_flux
+!*****************************************************************************************
+
+end module core
+
+ +
+
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sourcefile/radbelt_kinds_module.f90.html b/sourcefile/radbelt_kinds_module.f90.html new file mode 100644 index 0000000..61e68dd --- /dev/null +++ b/sourcefile/radbelt_kinds_module.f90.html @@ -0,0 +1,367 @@ + + + + + + + + + + + + + radbelt_kinds_module.F90 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

radbelt_kinds_module.F90 + Source File + +

+
+
+
+ +
+
+ +
+
+
+ + +
+
+ +
+ +
+
+
+

Files dependent on this one

+
+
+
+ + + + + +sourcefile~~radbelt_kinds_module.f90~~AfferentGraph + + + +sourcefile~radbelt_kinds_module.f90 + +radbelt_kinds_module.F90 + + + +sourcefile~core.f90 + + +core.f90 + + + + + +sourcefile~core.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +sourcefile~shellig.f90 + + +shellig.f90 + + + + + +sourcefile~core.f90->sourcefile~shellig.f90 + + + + + +sourcefile~trmfun.f90 + + +trmfun.f90 + + + + + +sourcefile~core.f90->sourcefile~trmfun.f90 + + + + + +sourcefile~shellig.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +sourcefile~trmfun.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +
+ Help +
+ +
+
+
+
+

Source Code

+
!*****************************************************************************************
+!>
+!  Numeric kind definitions for radbelt.
+
+    module radbelt_kinds_module
+
+    use,intrinsic :: iso_fortran_env
+
+    implicit none
+
+    private
+
+#ifdef REAL32
+    integer,parameter,public :: wp = real32   !! Real working precision [4 bytes]
+#elif REAL64
+    integer,parameter,public :: wp = real64   !! Real working precision [8 bytes]
+#elif REAL128
+    integer,parameter,public :: wp = real128  !! Real working precision [16 bytes]
+#else
+    integer,parameter,public :: wp = real64   !! Real working precision if not specified [8 bytes]
+#endif
+
+#ifdef INT8
+    integer,parameter,public :: ip = int8     !! Integer working precision [1 byte]
+#elif INT16
+    integer,parameter,public :: ip = int16    !! Integer working precision [2 bytes]
+#elif INT32
+    integer,parameter,public :: ip = int32    !! Integer working precision [4 bytes]
+#elif INT64
+    integer,parameter,public :: ip = int64    !! Integer working precision [8 bytes]
+#else
+    integer,parameter,public :: ip = int32    !! Integer working precision if not specified [4 bytes]
+#endif
+
+!*****************************************************************************************
+    end module radbelt_kinds_module
+!*****************************************************************************************
+
+ +
+
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sourcefile/shellig.f90.html b/sourcefile/shellig.f90.html new file mode 100644 index 0000000..6efb95c --- /dev/null +++ b/sourcefile/shellig.f90.html @@ -0,0 +1,1316 @@ + + + + + + + + + + + + + shellig.f90 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

shellig.f90 + Source File + +

+
+
+
+ +
+
+ +
+
+
+ + +
+
+ +
+ +
+
+
+

This file depends on

+
+
+
+ + + + + +sourcefile~~shellig.f90~~EfferentGraph + + + +sourcefile~shellig.f90 + +shellig.f90 + + + +sourcefile~radbelt_kinds_module.f90 + + +radbelt_kinds_module.F90 + + + + + +sourcefile~shellig.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +
+ Help +
+ +
+
+
+
+

Files dependent on this one

+
+
+
+ + + + + +sourcefile~~shellig.f90~~AfferentGraph + + + +sourcefile~shellig.f90 + +shellig.f90 + + + +sourcefile~core.f90 + + +core.f90 + + + + + +sourcefile~core.f90->sourcefile~shellig.f90 + + + + + +
+ Help +
+ +
+
+
+
+

Source Code

+
!*****************************************************************************************
+!>
+!  IGRF model
+!
+!### History
+!  * SHELLIG.FOR, Version 2.0, January 1992
+!  * 11/01/91-DKB- SHELLG: lowest starting point for B0 search is 2
+!  * 1/27/92-DKB- Adopted to IGRF-91 coefficients model
+!  * 2/05/92-DKB- Reduce variable-names: INTER(P)SHC,EXTRA(P)SHC,INITI(ALI)ZE
+!  * 8/08/95-DKB- Updated to IGRF-45-95; new coeff. DGRF90, IGRF95, IGRF95S
+!  * 5/31/00-DKB- Updated to IGRF-45-00; new coeff.: IGRF00, IGRF00s
+!  * 3/24/05-DKB- Updated to IGRF-45-10; new coeff.: IGRF05, IGRF05s
+
+   module shellig_module
+
+      use radbelt_kinds_module
+
+      implicit none
+
+      private
+
+      integer,parameter :: filename_len = 14 !! length of the model data file names
+
+      ! parameters formerly in `gener` common block
+      real(wp),parameter :: Era = 6371.2_wp !! earth radius for normalization of cartesian coordinates (6371.2 km)
+      real(wp),parameter :: erequ = 6378.16_wp
+      real(wp),parameter :: erpol = 6356.775_wp
+      real(wp),parameter :: Aquad = erequ*erequ !! square of major half axis for
+                                                !! earth ellipsoid as recommended by international
+                                                !! astronomical union
+      real(wp),parameter :: Bquad = erpol*erpol !! square of minor half axis for
+                                                !! earth ellipsoid as recommended by international
+                                                !! astronomical union
+      real(wp),parameter :: Umr = atan(1.0_wp)*4.0_wp/180.0_wp !! atan(1.0)*4./180.   <degree>*umr=<radiant>
+
+      real(wp),dimension(3,3),parameter ::  u = reshape([ +0.3511737_wp , -0.9148385_wp , -0.1993679_wp , &
+                                                          +0.9335804_wp , +0.3583680_wp , +0.0000000_wp , &
+                                                          +0.0714471_wp , -0.1861260_wp , +0.9799247_wp], [3,3])
+
+       type,public :: shellig_type
+         private
+
+         ! formerly in the `fidb0` common block
+         real(wp),dimension(3) :: sp = 0.0_wp
+
+         ! formerly in blank common
+         real(wp),dimension(3) :: xi = 0.0_wp
+         real(wp),dimension(144) :: h = 0.0_wp !! Field model coefficients adjusted for [[shellg]]
+
+         ! formerly in `model` common block
+         integer :: iyea = 0 !! the int year corresponding to the file `name` that has been read
+         character(len=filename_len) :: name = '' !! file name
+         integer :: nmax = 0 !! maximum order of spherical harmonics
+         real(wp) :: Time = 0.0_wp !! year (decimal: 1973.5) for which magnetic field is to be calculated
+         real(wp),dimension(144) :: g = 0.0_wp  !! `g(m)` -- normalized field coefficients (see [[feldcof]]) m=nmax*(nmax+2)
+
+         ! formerly saved vars in shellg:
+         real(wp) :: step = 0.20_wp !! step size for field line tracing
+         real(wp) :: steq = 0.03_wp !! step size for integration
+
+         ! from feldcof, so we can cache the coefficients
+         real(wp),dimension(120) :: gh2 = 0.0_wp   ! JW : why is this 120 and g is 144 ???
+
+         contains
+         private
+
+         procedure,public :: igrf
+
+         procedure, public :: feldcof
+         procedure, public :: feldg
+         procedure, public :: shellg
+         procedure, public :: findb0
+         procedure :: stoer, getshc, intershc, extrashc
+
+      end type shellig_type
+
+   contains
+!*****************************************************************************************
+
+!*****************************************************************************************
+!>
+!  Wrapper for IGRF functions.
+
+   subroutine igrf(me,lon,lat,height,year,xl,bbx)
+
+      class(shellig_type),intent(inout) :: me
+      real(wp),intent(in) :: lon !! geodetic longitude in degrees (east)
+      real(wp),intent(in) :: lat !! geodetic latitude in degrees (north)
+      real(wp),intent(in) :: height !! altitude in km above sea level
+      real(wp),intent(in) :: year !! decimal year for which geomagnetic field is to
+                                  !! be calculated (e.g.:1995.5 for day 185 of 1995)
+      real(wp),intent(out) :: xl !! l-value
+      real(wp),intent(out) :: bbx
+
+      real(wp) :: bab1 , babs , bdel , bdown , beast , &
+                  beq , bequ , bnorth , dimo , rr0
+      integer :: icode
+      logical :: val
+
+      real(wp),parameter :: stps = 0.05_wp
+
+      call me%feldcof(year,dimo)
+      call me%feldg(lat,lon,height,bnorth,beast,bdown,babs)
+      call me%shellg(lat,lon,height,dimo,xl,icode,bab1)
+
+      bequ = dimo/(xl*xl*xl)
+      if ( icode==1 ) then
+         bdel = 1.0e-3_wp
+         call me%findb0(stps,bdel,val,beq,rr0)
+         if ( val ) bequ = beq
+      endif
+      bbx = babs/bequ
+
+   end subroutine igrf
+!*****************************************************************************************
+
+!*****************************************************************************************
+!>
+    subroutine findb0(me,stps,bdel,value,bequ,rr0)
+
+      class(shellig_type),intent(inout) :: me
+      real(wp),intent(in) :: stps
+      real(wp),intent(inout) :: bdel
+      real(wp),intent(out) :: bequ
+      logical,intent(out) :: value
+      real(wp),intent(out) :: rr0
+
+      real(wp) :: b , bdelta , bmin , bold , bq1 , &
+                  bq2 , bq3 , p(8,4) , r1 , r2 , r3 , &
+                  rold , step , step12 , zz
+      integer :: i , irun , j , n
+
+      step=stps
+      irun=0
+
+      main : do
+        irun=irun+1
+        if (irun>5) then
+            value=.false.
+            exit main
+        endif
+        !*********************first three points
+        p(1,2)=me%sp(1)
+        p(2,2)=me%sp(2)
+        p(3,2)=me%sp(3)
+        step=-sign(step,p(3,2))
+        call me%stoer(p(1,2),bq2,r2)
+        p(1,3)=p(1,2)+0.5_wp*step*p(4,2)
+        p(2,3)=p(2,2)+0.5_wp*step*p(5,2)
+        p(3,3)=p(3,2)+0.5_wp*step
+        call me%stoer(p(1,3),bq3,r3)
+        p(1,1)=p(1,2)-step*(2.0_wp*p(4,2)-p(4,3))
+        p(2,1)=p(2,2)-step*(2.0_wp*p(5,2)-p(5,3))
+        p(3,1)=p(3,2)-step
+        call me%stoer(p(1,1),bq1,r1)
+        p(1,3)=p(1,2)+step*(20.0_wp*p(4,3)-3.*p(4,2)+p(4,1))/18.0_wp
+        p(2,3)=p(2,2)+step*(20.0_wp*p(5,3)-3.*p(5,2)+p(5,1))/18.0_wp
+        p(3,3)=p(3,2)+step
+        call me%stoer(p(1,3),bq3,r3)
+        !******************invert sense if required
+        if (bq3>bq1) then
+            step=-step
+            r3=r1
+            bq3=bq1
+            do i=1,5
+                zz=p(i,1)
+                p(i,1)=p(i,3)
+                p(i,3)=zz
+            end do
+        end if
+        !******************initialization
+        step12=step/12.0_wp
+        value=.true.
+        bmin=1.0e4_wp
+        bold=1.0e4_wp
+        !******************corrector (field line tracing)
+        n=0
+        corrector : do
+            p(1,3)=p(1,2)+step12*(5.0_wp*p(4,3)+8.0_wp*p(4,2)-p(4,1))
+            n=n+1
+            p(2,3)=p(2,2)+step12*(5.0_wp*p(5,3)+8.0_wp*p(5,2)-p(5,1))
+            !******************predictor (field line tracing)
+            p(1,4)=p(1,3)+step12*(23.0_wp*p(4,3)-16.0_wp*p(4,2)+5.0_wp*p(4,1))
+            p(2,4)=p(2,3)+step12*(23.0_wp*p(5,3)-16.0_wp*p(5,2)+5.0_wp*p(5,1))
+            p(3,4)=p(3,3)+step
+            call me%stoer(p(1,4),bq3,r3)
+            do j=1,3
+                do i=1,8
+                    p(i,j)=p(i,j+1)
+                end do
+            end do
+            b=sqrt(bq3)
+            if (b<bmin) bmin=b
+            if (b>bold) exit corrector
+            bold=b
+            rold=1.0_wp/r3
+            me%sp(1)=p(1,4)
+            me%sp(2)=p(2,4)
+            me%sp(3)=p(3,4)
+        end do corrector
+        if (bold/=bmin) value=.false.
+        bdelta=(b-bold)/bold
+        if (bdelta<=bdel) exit main
+        step=step/10.0_wp
+    end do main
+
+    rr0=rold
+    bequ=bold
+    bdel=bdelta
+
+  end subroutine findb0
+
+!*****************************************************************************************
+!>
+!  calculates l-value for specified geodaetic coordinates, altitude
+!  and gemagnetic field model.
+!
+!### Reference
+!  * G. KLUGE, EUROPEAN SPACE OPERATIONS CENTER, INTERNAL NOTE
+!    NO. 67, 1970.
+!  * G. KLUGE, COMPUTER PHYSICS COMMUNICATIONS 3, 31-35, 1972
+!
+!### History
+! * CHANGES (D. BILITZA, NOV 87):
+!   - USING CORRECT DIPOL MOMENT I.E.,DIFFERENT COMMON/MODEL/
+!   - USING IGRF EARTH MAGNETIC FIELD MODELS FROM 1945 TO 1990
+
+  subroutine shellg(me,glat,glon,alt,dimo,fl,icode,b0)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: glat !! GEODETIC LATITUDE IN DEGREES (NORTH)
+   real(wp),intent(in) :: glon !! GEODETIC LONGITUDE IN DEGREES (EAST)
+   real(wp),intent(in) :: alt  !! ALTITUDE IN KM ABOVE SEA LEVEL
+   real(wp),intent(in) :: dimo !! DIPOL MOMENT IN GAUSS (NORMALIZED TO EARTH RADIUS)
+   real(wp),intent(out) :: fl  !! l-value
+   integer,intent(out) :: icode  !! * =1 normal completion
+                                 !! * =2 unphysical conjugate point (fl meaningless)
+                                 !! * =3 shell parameter greater than limit up to
+                                 !!   which accurate calculation is required;
+                                 !!   approximation is used.
+   real(wp),intent(out) :: b0 !! magnetic field strength in gauss
+
+   real(wp) :: arg1 , arg2 , bequ , bq1 , bq2 , bq3 , c0 , c1 , c2 , c3 , &
+               ct , d , d0 , d1 , d2, dimob0 , e0 , e1 , e2 , ff , fi , gg , &
+               hli , oradik , oterm , p(8,100) , r , r1 , r2 , r3 , r3h , radik , &
+               rlat , rlon , rq , st , step12 , step2 , &
+               stp , t , term , v(3) , xx , z , zq , zz
+   integer :: i , iequ , n
+
+   real(wp),parameter :: rmin = 0.05_wp !! boundaries for identification of `icode=2 and 3`
+   real(wp),parameter :: rmax = 1.01_wp !! boundaries for identification of `icode=2 and 3`
+
+   bequ = 1.0e10_wp
+
+   !*****ENTRY POINT SHELLG TO BE USED WITH GEODETIC CO-ORDINATES
+   rlat = Glat*Umr
+   ct = sin(rlat)
+   st = cos(rlat)
+   d = sqrt(Aquad-(Aquad-Bquad)*ct*ct)
+   me%Xi(1) = (Alt+Aquad/d)*st/Era
+   me%Xi(3) = (Alt+Bquad/d)*ct/Era
+   rlon = Glon*Umr
+   me%Xi(2) = me%Xi(1)*sin(rlon)
+   me%Xi(1) = me%Xi(1)*cos(rlon)
+   CALL spag_block_1()
+   RETURN
+
+!*****ENTRY POINT SHELLC TO BE USED WITH CARTESIAN CO-ORDINATES   ! JW : does not appear to be used anywhere.
+!    V(3)  CARTESIAN COORDINATES IN EARTH RADII (6371.2 KM)
+!      X-AXIS POINTING TO EQUATOR AT 0 LONGITUDE
+!      Y-AXIS POINTING TO EQUATOR AT 90 LONG.
+!      Z-AXIS POINTING TO NORTH POLE
+   ENTRY shellc(me,V,Fl,B0)
+   me%Xi(1) = V(1)
+   me%Xi(2) = V(2)
+   me%Xi(3) = V(3)
+   CALL spag_block_1()
+
+CONTAINS
+
+   subroutine spag_block_1
+
+      integer,parameter :: max_loop_index = 100  ! 3333   <--- JW : original code had 3333 ... was this a bug ????
+
+      !*****CONVERT TO DIPOL-ORIENTED CO-ORDINATES
+      rq = 1.0_wp/(me%Xi(1)*me%Xi(1)+me%Xi(2)*me%Xi(2)+me%Xi(3)*me%Xi(3))
+      r3h = sqrt(rq*sqrt(rq))
+      p(1,2) = (me%Xi(1)*u(1,1)+me%Xi(2)*u(2,1)+me%Xi(3)*u(3,1))*r3h
+      p(2,2) = (me%Xi(1)*u(1,2)+me%Xi(2)*u(2,2))*r3h
+      p(3,2) = (me%Xi(1)*u(1,3)+me%Xi(2)*u(2,3)+me%Xi(3)*u(3,3))*rq
+      !     *****FIRST THREE POINTS OF FIELD LINE
+      me%step = -sign(me%step,p(3,2))
+      call me%stoer(p(1,2),bq2,r2)
+      B0 = sqrt(bq2)
+      p(1,3) = p(1,2) + 0.5_wp*me%step*p(4,2)
+      p(2,3) = p(2,2) + 0.5_wp*me%step*p(5,2)
+      p(3,3) = p(3,2) + 0.5_wp*me%step
+      call me%stoer(p(1,3),bq3,r3)
+      p(1,1) = p(1,2) - me%step*(2.0_wp*p(4,2)-p(4,3))
+      p(2,1) = p(2,2) - me%step*(2.0_wp*p(5,2)-p(5,3))
+      p(3,1) = p(3,2) - me%step
+      call me%stoer(p(1,1),bq1,r1)
+      p(1,3) = p(1,2) + me%step*(20.0_wp*p(4,3)-3.*p(4,2)+p(4,1))/18.0_wp
+      p(2,3) = p(2,2) + me%step*(20.0_wp*p(5,3)-3.*p(5,2)+p(5,1))/18.0_wp
+      p(3,3) = p(3,2) + me%step
+      call me%stoer(p(1,3),bq3,r3)
+      !*****INVERT SENSE IF REQUIRED
+      IF ( bq3>bq1 ) THEN
+         me%step = -me%step
+         r3 = r1
+         bq3 = bq1
+         DO i = 1 , 7
+            zz = p(i,1)
+            p(i,1) = p(i,3)
+            p(i,3) = zz
+         ENDDO
+      ENDIF
+      !*****SEARCH FOR LOWEST MAGNETIC FIELD STRENGTH
+      IF ( bq1<bequ ) THEN
+         bequ = bq1
+         iequ = 1
+      ENDIF
+      IF ( bq2<bequ ) THEN
+         bequ = bq2
+         iequ = 2
+      ENDIF
+      IF ( bq3<bequ ) THEN
+         bequ = bq3
+         iequ = 3
+      ENDIF
+      !*****INITIALIZATION OF INTEGRATION LOOPS
+      step12 = me%step/12.0_wp
+      step2 = me%step + me%step
+      me%steq = sign(me%steq,me%step)
+      fi = 0.0_wp
+      Icode = 1
+      oradik = 0.0_wp
+      oterm = 0.0_wp
+      stp = r2*me%steq
+      z = p(3,2) + stp
+      stp = stp/0.75_wp
+      p(8,1) = step2*(p(1,1)*p(4,1)+p(2,1)*p(5,1))
+      p(8,2) = step2*(p(1,2)*p(4,2)+p(2,2)*p(5,2))
+      !*****MAIN LOOP (FIELD LINE TRACING)
+      main: DO n = 3 , max_loop_index
+         !*****CORRECTOR (FIELD LINE TRACING)
+         p(1,n) = p(1,n-1) + step12*(5.0_wp*p(4,n)+8.0_wp*p(4,n-1)-p(4,n-2))
+         p(2,n) = p(2,n-1) + step12*(5.0_wp*p(5,n)+8.0_wp*p(5,n-1)-p(5,n-2))
+         !*****PREPARE EXPANSION COEFFICIENTS FOR INTERPOLATION
+         !*****OF SLOWLY VARYING QUANTITIES
+         p(8,n) = step2*(p(1,n)*p(4,n)+p(2,n)*p(5,n))
+         c0 = p(1,n-1)**2 + p(2,n-1)**2
+         c1 = p(8,n-1)
+         c2 = (p(8,n)-p(8,n-2))*0.25_wp
+         c3 = (p(8,n)+p(8,n-2)-c1-c1)/6.0_wp
+         d0 = p(6,n-1)
+         d1 = (p(6,n)-p(6,n-2))*0.5_wp
+         d2 = (p(6,n)+p(6,n-2)-d0-d0)*0.5_wp
+         e0 = p(7,n-1)
+         e1 = (p(7,n)-p(7,n-2))*0.5_wp
+         e2 = (p(7,n)+p(7,n-2)-e0-e0)*0.5_wp
+         inner: DO
+            !*****INNER LOOP (FOR QUADRATURE)
+            t = (z-p(3,n-1))/me%step
+            IF ( t>1.0_wp ) THEN
+               !*****PREDICTOR (FIELD LINE TRACING)
+               p(1,n+1) = p(1,n) + step12*(23.0_wp*p(4,n)-16.0_wp*p(4,n-1)+5.0_wp*p(4,n-2))
+               p(2,n+1) = p(2,n) + step12*(23.0_wp*p(5,n)-16.0_wp*p(5,n-1)+5.0_wp*p(5,n-2))
+               p(3,n+1) = p(3,n) + me%step
+               call me%stoer(p(1,n+1),bq3,r3)
+               !*****SEARCH FOR LOWEST MAGNETIC FIELD STRENGTH
+               IF ( bq3<bequ ) THEN
+                  iequ = n + 1
+                  bequ = bq3
+               ENDIF
+               EXIT inner
+            ELSE
+               hli = 0.5_wp*(((c3*t+c2)*t+c1)*t+c0)
+               zq = z*z
+               r = hli + sqrt(hli*hli+zq)
+               IF ( r<=rmin ) THEN
+                  !*****APPROXIMATION FOR HIGH VALUES OF L.
+                  Icode = 3
+                  t = -p(3,n-1)/me%step
+                  Fl = 1.0_wp/(abs(((c3*t+c2)*t+c1)*t+c0)+1.0e-15_wp)
+                  RETURN
+               ENDIF
+               rq = r*r
+               ff = sqrt(1.0_wp+3.0_wp*zq/rq)
+               radik = B0 - ((d2*t+d1)*t+d0)*r*rq*ff
+               IF ( r>rmax ) THEN
+                  Icode = 2
+                  radik = radik - 12.0_wp*(r-rmax)**2
+               ENDIF
+               IF ( radik+radik<=oradik ) EXIT main
+               term = sqrt(radik)*ff*((e2*t+e1)*t+e0)/(rq+zq)
+               fi = fi + stp*(oterm+term)
+               oradik = radik
+               oterm = term
+               stp = r*me%steq
+               z = z + stp
+            ENDIF
+         ENDDO inner
+      ENDDO main
+      IF ( iequ<2 ) iequ = 2
+      me%Sp(1) = p(1,iequ-1)
+      me%Sp(2) = p(2,iequ-1)
+      me%Sp(3) = p(3,iequ-1)
+      IF ( oradik>=1.0e-15_wp ) fi = fi + stp/0.75_wp*oterm*oradik/(oradik-radik)
+      !
+      !-- The minimal allowable value of FI was changed from 1E-15 to 1E-12,
+      !-- because 1E-38 is the minimal allowable arg. for ALOG in our envir.
+      !-- D. Bilitza, Nov 87.
+      !
+      fi = 0.5_wp*abs(fi)/sqrt(B0) + 1.0e-12_wp
+      !*****COMPUTE L FROM B AND I.  SAME AS CARMEL IN INVAR.
+      !
+      !-- Correct dipole moment is used here. D. Bilitza, Nov 87.
+      !
+      dimob0 = Dimo/B0
+      arg1 = log(fi)
+      arg2 = log(dimob0)
+!       arg = FI*FI*FI/DIMOB0
+!       if(abs(arg)>88.0_wp) arg=88.0_wp
+      xx = 3*arg1 - arg2
+      IF ( xx>23.0_wp ) THEN
+         gg = xx - 3.0460681_wp
+      ELSEIF ( xx>11.7_wp ) THEN
+         gg = (((((2.8212095E-8_wp*xx-3.8049276E-6_wp)*xx+&
+                   2.170224E-4_wp)*xx-6.7310339E-3_wp)*xx+&
+                   1.2038224E-1_wp)*xx-1.8461796E-1_wp)*xx + 2.0007187_wp
+      ELSEIF ( xx>+3.0_wp ) THEN
+         gg = ((((((((6.3271665E-10_wp*xx-3.958306E-8_wp)*xx+&
+                      9.9766148E-07_wp)*xx-1.2531932E-5_wp)*xx+&
+                      7.9451313E-5_wp)*xx-3.2077032E-4_wp)*xx+&
+                      2.1680398E-3_wp)*xx+1.2817956E-2_wp)*xx+&
+                      4.3510529E-1_wp)*xx + 6.222355E-1_wp
+      ELSEIF ( xx>-3.0_wp ) THEN
+         gg = ((((((((2.6047023E-10_wp*xx+2.3028767E-9_wp)*xx-&
+                      2.1997983E-8_wp)*xx-5.3977642E-7_wp)*xx-&
+                      3.3408822E-6_wp)*xx+3.8379917E-5_wp)*xx+&
+                      1.1784234E-3_wp)*xx+1.4492441E-2_wp)*xx+&
+                      4.3352788E-1_wp)*xx + 6.228644E-1_wp
+      ELSEIF ( xx>-22.0_wp ) THEN
+         gg = ((((((((-8.1537735E-14_wp*xx+8.3232531E-13_wp)*xx+&
+                       1.0066362E-9_wp)*xx+8.1048663E-8_wp)*xx+&
+                       3.2916354E-6_wp)*xx+8.2711096E-5_wp)*xx+&
+                       1.3714667E-3_wp)*xx+1.5017245E-2_wp)*xx+&
+                       4.3432642E-1_wp)*xx + 6.2337691E-1_wp
+      ELSE
+         gg = 3.33338E-1_wp*xx + 3.0062102E-1_wp
+      ENDIF
+      Fl = exp(log((1.0_wp+exp(gg))*dimob0)/3.0_wp)
+      RETURN
+   END subroutine spag_block_1
+
+END subroutine shellg
+
+!*****************************************************************************************
+!>
+!  subroutine used for field line tracing in [[shellg]]
+!  calls entry point [[feldi]] in geomagnetic field subroutine [[feldg]]
+
+subroutine stoer(me,p,bq,r)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),dimension(7),intent(inout) :: p
+   real(wp),intent(out) :: bq
+   real(wp),intent(out) :: r
+
+   real(wp) :: dr , dsq , dx , dxm , dy , dym , dz , &
+               dzm , fli , q , rq , wr , xm , ym , zm
+
+!*****XM,YM,ZM ARE GEOMAGNETIC CARTESIAN INVERSE CO-ORDINATES
+   zm = P(3)
+   fli = P(1)*P(1) + P(2)*P(2) + 1.0e-15_wp
+   R = 0.5_wp*(fli+sqrt(fli*fli+(zm+zm)**2))
+   rq = R*R
+   wr = sqrt(R)
+   xm = P(1)*wr
+   ym = P(2)*wr
+!*****TRANSFORM TO GEOGRAPHIC CO-ORDINATE SYSTEM
+   me%Xi(1) = xm*u(1,1) + ym*u(1,2) + zm*u(1,3)
+   me%Xi(2) = xm*u(2,1) + ym*u(2,2) + zm*u(2,3)
+   me%Xi(3) = xm*u(3,1) + zm*u(3,3)
+!*****COMPUTE DERIVATIVES
+! Changed from CALL FELDI(XI,H); XI, H are in COMMON block; results
+! are the same; dkb Feb 1998.
+! JW : feb 2024 : xi, h now class variables.
+   CALL feldi(me)
+   q = me%H(1)/rq
+   dx = me%H(3) + me%H(3) + q*me%Xi(1)
+   dy = me%H(4) + me%H(4) + q*me%Xi(2)
+   dz = me%H(2) + me%H(2) + q*me%Xi(3)
+!*****TRANSFORM BACK TO GEOMAGNETIC CO-ORDINATE SYSTEM
+   dxm = u(1,1)*dx + u(2,1)*dy + u(3,1)*dz
+   dym = u(1,2)*dx + u(2,2)*dy
+   dzm = u(1,3)*dx + u(2,3)*dy + u(3,3)*dz
+   dr = (xm*dxm+ym*dym+zm*dzm)/R
+!*****FORM SLOWLY VARYING EXPRESSIONS
+   P(4) = (wr*dxm-0.5_wp*P(1)*dr)/(R*dzm)
+   P(5) = (wr*dym-0.5_wp*P(2)*dr)/(R*dzm)
+   dsq = rq*(dxm*dxm+dym*dym+dzm*dzm)
+   Bq = dsq*rq*rq
+   P(6) = sqrt(dsq/(rq+3.0_wp*zm*zm))
+   P(7) = P(6)*(rq+zm*zm)/(rq*dzm)
+END subroutine stoer
+
+!*****************************************************************************************
+!>
+!  Calculates earth magnetic field from spherical harmonics model
+!
+!### Reference
+! ref: g. kluge, european space operations centre, internal note 61,
+!      1970.
+!
+!### History
+!  * changes (d. bilitza, nov 87):
+!   - field coefficients in binary data files instead of block data
+!   - calculates dipol moment
+
+subroutine feldg(me,glat,glon,alt,bnorth,beast,bdown,babs)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: glat  !! geodetic latitude in degrees (north)
+   real(wp),intent(in) :: glon  !! geodetic longitude in degrees (east)
+   real(wp),intent(in) :: alt   !! altitude in km above sea level
+   real(wp),intent(out) :: bnorth, beast, bdown !! components of the field with respect
+                                                !! to the local geodetic coordinate system, with axis
+                                                !! pointing in the tangential plane to the north, east
+                                                !! and downward.
+   real(wp),intent(out) :: Babs !! magnetic field strength in gauss
+
+   real(wp) :: b(3) , brho , bxxx , &
+               byyy , bzzz , cp , ct , d , f , rho , &
+               rlat , rlon , rq , s , sp , st , t , v(3) , x , xxx , &
+               y , yyy , z , zzz
+   integer :: i , ih , ihmax , il , imax , is , k , last , m
+
+   !-- is records entry point
+   !
+   !*****entry point  feldg  to be used with geodetic co-ordinates
+         is=1
+         rlat=glat*umr
+         ct=sin(rlat)
+         st=cos(rlat)
+         d=sqrt(aquad-(aquad-bquad)*ct*ct)
+         rlon=glon*umr
+         cp=cos(rlon)
+         sp=sin(rlon)
+         zzz=(alt+bquad/d)*ct/era
+         rho=(alt+aquad/d)*st/era
+         xxx=rho*cp
+         yyy=rho*sp
+         goto 10
+
+   !*****entry point  feldc  to be used with cartesian co-ordinates
+   !        v(3)  cartesian coordinates in earth radii (6371.2 km)
+   !            x-axis pointing to equator at 0 longitude
+   !            y-axis pointing to equator at 90 long.
+   !            z-axis pointing to north pole
+         entry feldc(me,v,b)
+         is=2
+         xxx=v(1)
+         yyy=v(2)
+         zzz=v(3)
+
+   10    rq=1.0_wp/(xxx*xxx+yyy*yyy+zzz*zzz)
+         me%xi(1)=xxx*rq
+         me%xi(2)=yyy*rq
+         me%xi(3)=zzz*rq
+         goto 20
+
+   !*****entry point  feldi  used for l computation
+         entry feldi(me)
+         is=3
+   20    ihmax=me%nmax*me%nmax+1
+         last=ihmax+me%nmax+me%nmax
+         imax=me%nmax+me%nmax-1
+         do i=ihmax,last
+             me%h(i)=me%g(i)
+         end do
+         do k=1,3,2
+            i=imax
+            ih=ihmax
+            do
+               il=ih-i
+               f=2.0_wp/real(i-k+2, wp)
+               x=me%xi(1)*f
+               y=me%xi(2)*f
+               z=me%xi(3)*(f+f)
+               i=i-2
+               if ((i-1)>=0) then
+                  if ((i-1)>0) then
+                     do m=3,i,2
+                        me%h(il+m+1)=me%g(il+m+1)+z*me%h(ih+m+1)+x*(me%h(ih+m+3)-&
+                                     me%h(ih+m-1))-y*(me%h(ih+m+2)+me%h(ih+m-2))
+                        me%h(il+m)=me%g(il+m)+z*me%h(ih+m)+x*(me%h(ih+m+2)-&
+                                   me%h(ih+m-2))+y*(me%h(ih+m+3)+me%h(ih+m-1))
+                     end do
+                  end if
+                  me%h(il+2)=me%g(il+2)+z*me%h(ih+2)+x*me%h(ih+4)-y*(me%h(ih+3)+me%h(ih))
+                  me%h(il+1)=me%g(il+1)+z*me%h(ih+1)+y*me%h(ih+4)+x*(me%h(ih+3)-me%h(ih))
+               end if
+               me%h(il)=me%g(il)+z*me%h(ih)+2.0_wp*(x*me%h(ih+1)+y*me%h(ih+2))
+               ih=il
+               if (i<k) exit
+            end do
+         end do
+
+         if (is==3) return
+
+         s=0.5_wp*me%h(1)+2.0_wp*(me%h(2)*me%xi(3)+me%h(3)*me%xi(1)+me%h(4)*me%xi(2))
+         t=(rq+rq)*sqrt(rq)
+         bxxx=t*(me%h(3)-s*xxx)
+         byyy=t*(me%h(4)-s*yyy)
+         bzzz=t*(me%h(2)-s*zzz)
+         if (is==2) then
+            b(1)=bxxx
+            b(2)=byyy
+            b(3)=bzzz
+         else
+            babs=sqrt(bxxx*bxxx+byyy*byyy+bzzz*bzzz)
+            beast=byyy*cp-bxxx*sp
+            brho=byyy*sp+bxxx*cp
+            bnorth=bzzz*st-brho*ct
+            bdown=-bzzz*ct-brho*st
+         end if
+
+   end subroutine feldg
+
+!*****************************************************************************************
+!>
+!  Determines coefficients and dipol moment from IGRF models
+!
+!### Author
+!  * D. BILITZA, NSSDC, GSFC, CODE 633, GREENBELT, MD 20771,
+!    (301) 286-9536 NOV 1987.
+!
+!### History
+!  * corrected for 2000 update - dkb- 5/31/2000
+!  * updated to IGRF-2000 version -dkb- 5/31/2000
+!  * updated to IGRF-2005 version -dkb- 3/24/2000
+
+   subroutine feldcof(me,year,dimo)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: year !! decimal year for which geomagnetic field is to
+                               !! be calculated (e.g.:1995.5 for day 185 of 1995)
+   real(wp),intent(out) :: dimo !! geomagnetic dipol moment in gauss (normalized
+                                !! to earth's radius) at the time (year)
+
+   real(wp) :: dte1 , dte2 , erad , gha(144) , sqrt2
+   integer :: i , ier , j , l , m , n , nmax1 , nmax2, iyea
+   character(len=filename_len) :: fil2
+   real(wp) :: x , f0 , f !! these were double precision in original
+                          !! code while everything else was single precision
+
+   ! changed to conform with IGRF 45-95, also FILMOD, DTEMOD arrays +1
+   character(len=filename_len),dimension(17),parameter :: filmod = [&
+         'dgrf1945.dat ' , 'dgrf1950.dat ' , 'dgrf1955.dat ' , 'dgrf1960.dat ' , &
+         'dgrf1965.dat ' , 'dgrf1970.dat ' , 'dgrf1975.dat ' , 'dgrf1980.dat ' , &
+         'dgrf1985.dat ' , 'dgrf1990.dat ' , 'dgrf1995.dat ' , 'dgrf2000.dat ' , &
+         'dgrf2005.dat ' , 'dgrf2010.dat ' , 'dgrf2015.dat ' , 'igrf2020.dat ' , &
+         'igrf2020s.dat']
+   real(wp),dimension(17),parameter :: dtemod = [1945.0_wp , 1950.0_wp , 1955.0_wp , &
+                                                 1960.0_wp , 1965.0_wp , 1970.0_wp , &
+                                                 1975.0_wp , 1980.0_wp , 1985.0_wp , &
+                                                 1990.0_wp , 1995.0_wp , 2000.0_wp , &
+                                                 2005.0_wp , 2010.0_wp , 2015.0_wp , &
+                                                 2020.0_wp , 2025.0_wp]
+   integer,parameter :: numye = size(dtemod)-1 ! number of 5-year priods represented by IGRF
+   integer,parameter :: is = 0 !! * is=0 for schmidt normalization
+                               !! * is=1 gauss normalization
+
+   logical :: read_file
+
+   !-- determine igrf-years for input-year
+   me%time = year
+   iyea = int(year/5.0_wp)*5
+   read_file = iyea /= me%iyea  ! if we have to read the file
+   me%iyea = iyea
+   l = (me%iyea-1945)/5 + 1
+   if ( l<1 ) l = 1
+   if ( l>numye ) l = numye
+   dte1 = dtemod(l)
+   me%name = filmod(l)
+   dte2 = dtemod(l+1)
+   fil2 = filmod(l+1)
+   if (read_file) then
+      ! get igrf coefficients for the boundary years
+      ! [if they have not ready been loaded]
+      call me%getshc(me%name,nmax1,erad,me%g,ier)
+      if ( ier/=0 ) error stop 'error reading file: '//trim(me%name)
+      call me%getshc(fil2,nmax2,erad,me%gh2,ier)
+      if ( ier/=0 ) error stop 'error reading file: '//trim(fil2)
+   end if
+   !-- determine igrf coefficients for year
+   if ( l<=numye-1 ) then
+      call me%intershc(year,dte1,nmax1,me%g,dte2,nmax2,me%gh2,me%nmax,gha)
+   else
+      call me%extrashc(year,dte1,nmax1,me%g,nmax2,me%gh2,me%nmax,gha)
+   endif
+   !-- determine magnetic dipol moment and coeffiecients g
+   f0 = 0.0_wp
+   do j = 1 , 3
+      f = gha(j)*1.0e-5_wp
+      f0 = f0 + f*f
+   enddo
+   dimo = sqrt(f0)
+
+   me%g(1) = 0.0_wp
+   i = 2
+   f0 = 1.0e-5_wp
+   if ( is==0 ) f0 = -f0
+   sqrt2 = sqrt(2.0_wp)
+
+   do n = 1 , me%nmax
+      x = n
+      f0 = f0*x*x/(4.0_wp*x-2.0_wp)
+      if ( is==0 ) f0 = f0*(2.0_wp*x-1.0_wp)/x
+      f = f0*0.5_wp
+      if ( is==0 ) f = f*sqrt2
+      me%g(i) = gha(i-1)*f0
+      i = i + 1
+      do m = 1 , n
+         f = f*(x+m)/(x-m+1.0_wp)
+         if ( is==0 ) f = f*sqrt((x-m+1.0_wp)/(x+m))
+         me%g(i) = gha(i-1)*f
+         me%g(i+1) = gha(i)*f
+         i = i + 2
+      enddo
+   enddo
+
+end subroutine feldcof
+
+!*****************************************************************************************
+!>
+!  Reads spherical harmonic coefficients from the specified
+!  file into an array.
+!
+!### Author
+!  * Version 1.01, A. Zunde, USGS, MS 964,
+!    Box 25046 Federal Center, Denver, CO  80225
+
+subroutine getshc(me,Fspec,Nmax,Erad,Gh,Ier)
+
+   class(shellig_type),intent(inout) :: me
+   character(len=*),intent(in) :: Fspec !! File specification
+   integer,intent(out) :: Nmax !! Maximum degree and order of model
+   real(wp),intent(out) :: Erad !! Earth's radius associated with the spherical
+                                !! harmonic coefficients, in the same units as
+                                !! elevation
+   real(wp),dimension(*),intent(out) :: Gh !! Schmidt quasi-normal internal spherical
+                                           !! harmonic coefficients
+   integer,intent(out) :: Ier !! Error number:
+                              !!
+                              !!  * 0, no error
+                              !!  * -2, records out of order
+                              !!  * FORTRAN run-time error number
+
+   integer :: iu !! logical unit number
+   real(wp) :: g , h
+   integer :: i , m , mm , n , nn
+
+   read_file : block
+      ! ---------------------------------------------------------------
+      !  Open coefficient file. Read past first header record.
+      !  Read degree and order of model and Earth's radius.
+      ! ---------------------------------------------------------------
+      OPEN (newunit=Iu,FILE=Fspec,STATUS='OLD',IOSTAT=Ier)
+      if (Ier/=0) then
+         write(*,*) 'Error opening file: '//trim(fspec)
+         exit read_file
+      end if
+      READ (Iu,*,IOSTAT=Ier)
+      if (Ier/=0) exit read_file
+      READ (Iu,*,IOSTAT=Ier) Nmax , Erad
+      if (Ier/=0) exit read_file
+
+      ! ---------------------------------------------------------------
+      !  Read the coefficient file, arranged as follows:
+      !
+      !          N     M     G     H
+      !          ----------------------
+      !            /   1     0    GH(1)  -
+      !           /  1     1    GH(2) GH(3)
+      !          /  2     0    GH(4)  -
+      !         /  2     1    GH(5) GH(6)
+      !      NMAX*(NMAX+3)/2   /  2     2    GH(7) GH(8)
+      !         records    \  3     0    GH(9)  -
+      !         \      .     .     .     .
+      !          \  .     .     .     .
+      !      NMAX*(NMAX+2)     \  .     .     .     .
+      !      elements in GH      \  NMAX  NMAX   .     .
+      !
+      !  N and M are, respectively, the degree and order of the
+      !  coefficient.
+      ! ---------------------------------------------------------------
+      i = 0
+      main: DO nn = 1 , Nmax
+         DO mm = 0 , nn
+            READ (Iu,*,IOSTAT=Ier) n , m , g , h
+            if (Ier/=0) exit main
+            IF ( nn/=n .OR. mm/=m ) THEN
+               Ier = -2
+               EXIT main
+            ENDIF
+            i = i + 1
+            Gh(i) = g
+            IF ( m/=0 ) THEN
+               i = i + 1
+               Gh(i) = h
+            ENDIF
+         ENDDO
+      ENDDO main
+
+   end block read_file
+
+   CLOSE (Iu)
+
+END subroutine getshc
+
+!*****************************************************************************************
+!>
+!  Interpolates linearly, in time, between two spherical
+!  harmonic models.
+!
+!  The coefficients (GH) of the resulting model, at date
+!  DATE, are computed by linearly interpolating between the
+!  coefficients of the earlier model (GH1), at date DTE1,
+!  and those of the later model (GH2), at date DTE2. If one
+!  model is smaller than the other, the interpolation is
+!  performed with the missing coefficients assumed to be 0.
+!
+!### Author
+!  * Version 1.01, A. Zunde
+!    USGS, MS 964, Box 25046 Federal Center, Denver, CO  80225
+
+subroutine intershc(me,date,dte1,nmax1,gh1,dte2,nmax2,gh2,nmax,gh)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: date !! Date of resulting model (in decimal year)
+   real(wp),intent(in) :: dte1 !! Date of earlier model
+   integer,intent(in) :: nmax1 !! Maximum degree and order of earlier model
+   real(wp),intent(in) :: gh1(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of earlier model
+   real(wp),intent(in) :: dte2 !! Date of later model
+   integer,intent(in) :: nmax2 !! Maximum degree and order of later model
+   real(wp),intent(in) :: gh2(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of later model
+   real(wp),intent(out) :: gh(*) !! Coefficients of resulting model
+   integer,intent(out) :: nmax !! Maximum degree and order of resulting model
+
+   real(wp) :: factor
+   integer :: i , k , l
+
+   factor = (date-dte1)/(dte2-dte1)
+
+   if ( nmax1==nmax2 ) then
+      k = nmax1*(nmax1+2)
+      nmax = nmax1
+   elseif ( nmax1>nmax2 ) then
+      k = nmax2*(nmax2+2)
+      l = nmax1*(nmax1+2)
+      do i = k + 1 , l
+         gh(i) = gh1(i) + factor*(-gh1(i))
+      enddo
+      nmax = nmax1
+   else
+      k = nmax1*(nmax1+2)
+      l = nmax2*(nmax2+2)
+      do i = k + 1 , l
+         gh(i) = factor*gh2(i)
+      enddo
+      nmax = nmax2
+   endif
+
+   do i = 1 , k
+      gh(i) = gh1(i) + factor*(gh2(i)-gh1(i))
+   enddo
+
+end subroutine intershc
+
+!*****************************************************************************************
+!>
+!  Extrapolates linearly a spherical harmonic model with a
+!  rate-of-change model.
+!
+!  The coefficients (GH) of the resulting model, at date
+!  DATE, are computed by linearly extrapolating the coef-
+!  ficients of the base model (GH1), at date DTE1, using
+!  those of the rate-of-change model (GH2), at date DTE2. If
+!  one model is smaller than the other, the extrapolation is
+!  performed with the missing coefficients assumed to be 0.
+!
+!### Author
+!  * Version 1.01, A. Zunde
+!    USGS, MS 964, Box 25046 Federal Center, Denver, CO  80225
+
+subroutine extrashc(me,date,dte1,nmax1,gh1,nmax2,gh2,nmax,gh)
+
+   class(shellig_type),intent(inout) :: me
+   real(wp),intent(in) :: date   !! Date of resulting model (in decimal year)
+   real(wp),intent(in) :: dte1   !! Date of base model
+   integer,intent(in)  :: nmax1  !! Maximum degree and order of base model
+   real(wp),intent(in) :: gh1(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of base model
+   integer,intent(in)  :: nmax2  !! Maximum degree and order of rate-of-change model
+   real(wp),intent(in) :: gh2(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of rate-of-change model
+   real(wp),intent(out) :: gh(*) !! Coefficients of resulting model
+   integer,intent(out) :: nmax   !! Maximum degree and order of resulting model
+
+   real(wp) :: factor
+   integer :: i , k , l
+
+   factor = (date-dte1)
+
+   if ( nmax1==nmax2 ) then
+      k = nmax1*(nmax1+2)
+      nmax = nmax1
+   elseif ( nmax1>nmax2 ) then
+      k = nmax2*(nmax2+2)
+      l = nmax1*(nmax1+2)
+      do i = k + 1 , l
+         gh(i) = gh1(i)
+      enddo
+      nmax = nmax1
+   else
+      k = nmax1*(nmax1+2)
+      l = nmax2*(nmax2+2)
+      do i = k + 1 , l
+         gh(i) = factor*gh2(i)
+      enddo
+      nmax = nmax2
+   endif
+
+   do i = 1 , k
+      gh(i) = gh1(i) + factor*gh2(i)
+   enddo
+
+end subroutine extrashc
+
+end module SHELLIG_module
+
+ +
+
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sourcefile/trmfun.f90.html b/sourcefile/trmfun.f90.html new file mode 100644 index 0000000..7351cb3 --- /dev/null +++ b/sourcefile/trmfun.f90.html @@ -0,0 +1,792 @@ + + + + + + + + + + + + + trmfun.f90 – radbelt + + + + + + + + + + + + + + +
+ +
+ +
+
+

trmfun.f90 + Source File + +

+
+
+
+ +
+
+ +
+
+
+ + +
+
+ +
+ +
+
+
+

This file depends on

+
+
+
+ + + + + +sourcefile~~trmfun.f90~~EfferentGraph + + + +sourcefile~trmfun.f90 + +trmfun.f90 + + + +sourcefile~radbelt_kinds_module.f90 + + +radbelt_kinds_module.F90 + + + + + +sourcefile~trmfun.f90->sourcefile~radbelt_kinds_module.f90 + + + + + +
+ Help +
+ +
+
+
+
+

Files dependent on this one

+
+
+
+ + + + + +sourcefile~~trmfun.f90~~AfferentGraph + + + +sourcefile~trmfun.f90 + +trmfun.f90 + + + +sourcefile~core.f90 + + +core.f90 + + + + + +sourcefile~core.f90->sourcefile~trmfun.f90 + + + + + +
+ Help +
+ +
+
+
+
+

Source Code

+
!*****************************************************************************************
+!>
+!  Trapped radiation model.
+!
+!### History
+!  * Based on: `trmfun.for` 1987
+
+module trmfun_module
+
+   use radbelt_kinds_module
+
+   implicit none
+
+   private
+
+   character(len=10),dimension(4),parameter :: mname = [ 'ae8min.asc' , &
+                                                         'ae8max.asc' , &
+                                                         'ap8min.asc' , &
+                                                         'ap8max.asc'] !! data files available
+
+   type,public :: trm_type
+      !! main class for the `aep8` model
+      private
+
+      ! data read from the files:
+      character(len=:),allocatable :: file_loaded !! the file that has been loaded
+      integer,dimension(8) :: ihead = 0
+      integer,dimension(:),allocatable :: map
+
+      real(wp) :: fistep = 0.0_wp !! the stepsize for the parameterization of the logarithm of flux.
+                                  !! formerly stored in common block `tra2`
+
+      ! formerly saved variables in trara1:
+      real(wp) :: f1 = 1.001_wp
+      real(wp) :: f2 = 1.002_wp
+
+      contains
+      private
+      procedure,public :: aep8 !! main routine
+      procedure,public :: trara1, trara2 !! low-level routine
+   end type trm_type
+
+   contains
+
+!*****************************************************************************************
+!>
+!  Main wrapper for the radiation model.
+!  Reads the coefficient file and calls the low-level routine.
+
+   subroutine aep8(me,e,l,bb0,imname,flux)
+
+      class(trm_type),intent(inout) :: me
+
+      real(wp),intent(in) :: e
+      real(wp),intent(in) :: l
+      real(wp),intent(in) :: bb0
+      integer,intent(in) :: imname !! which model to load (index in `mname` array)
+      real(wp),intent(out) :: flux
+
+      real(wp) :: ee(1), f(1) !! temp variables
+      integer :: i , ierr, iuaeap , nmap
+      character(len=len(mname)) :: name
+      logical :: load_file
+
+      name = mname(Imname) ! the file to load
+
+      ! check to see if this file has already been loaded
+      ! [the class can store one file at a time]
+      load_file = .true.
+      if (allocated(me%file_loaded)) then
+         if (name == me%file_loaded) load_file = .false.
+      end if
+
+      if (load_file) then
+         open (newunit = iuaeap,file=name,status='OLD',iostat=ierr,form='FORMATTED')
+         if ( ierr/=0 ) then
+            error stop 'error reading '//trim(name)
+         end if
+         read (iuaeap,'(1X,12I6)') me%ihead
+         nmap = me%ihead(8)
+         allocate(me%map(nmap))
+         read (iuaeap,'(1X,12I6)') (me%map(i),i=1,nmap)
+         close (iuaeap)
+         me%file_loaded = trim(name)
+      end if
+
+      ee(1) = e
+      call me%trara1(me%ihead,me%map,L,Bb0,ee,f,1)
+      flux = f(1)
+      IF ( Flux>0.0_wp ) Flux = 10.0_wp**Flux
+
+   end subroutine aep8
+!*****************************************************************************************
+
+!*****************************************************************************************
+!>
+!  [[trara1]] finds particle fluxes for given energies, magnetic field
+!  strength and l-value. function [[trara2]] is used to interpolate in
+!  b-l-space.
+
+   subroutine trara1(me,descr,map,fl,bb0,e,f,n)
+
+   class(trm_type),intent(inout) :: me
+   integer,intent(in) :: n !! number of energies
+   integer,intent(in) :: descr(8) !! header of specified trapped radition model
+   real(wp),intent(in) :: e(n) !! array of energies in mev
+   real(wp),intent(in) :: fl !! l-value
+   real(wp),intent(in) :: bb0 !! =b/b0  magnetic field strength normalized
+                                 !! to field strength at magnetic equator
+   integer,intent(in) :: map(*) !! map of trapped radition model
+                                !! (descr and map are explained at the begin
+                                !! of the main program model)
+   real(wp),intent(out) :: f(n) !! decadic logarithm of integral fluxes in
+                                !! particles/(cm*cm*sec)
+
+   real(wp) :: e0 , e1 , e2 , escale , f0 , fscale , xnl
+   real(wp) :: bb0_ !! local copy of `bb0`. in the original code
+                    !! this was modified by this routine.
+                    !! added this so `bb0` could be `intent(in)`
+   integer :: i0 , i1 , i2 , i3 , ie , l3 , nb , nl
+   logical :: s0 , s1 , s2
+
+   bb0_ = bb0
+   me%fistep = descr(7)/descr(2)
+   escale = descr(4)
+   fscale = descr(7)
+   xnl = min(15.6_wp,abs(fl))
+   nl = xnl*descr(5)
+   if ( bb0_<1.0_wp ) bb0_ = 1.0_wp
+   nb = (bb0_-1.0_wp)*descr(6)
+
+   ! i2 is the number of elements in the flux map for the first energy.
+   ! i3 is the index of the last element of the second energy map.
+   ! l3 is the length of the map for the third energy.
+   ! e1 is the energy of the first energy map (unscaled)
+   ! e2 is the energy of the second energy map (unscaled)
+   i1 = 0
+   i2 = map(1)
+   i3 = i2 + map(i2+1)
+   l3 = map(i3+1)
+   e1 = map(i1+2)/escale
+   e2 = map(i2+2)/escale
+
+   ! s0, s1, s2 are logical variables which indicate whether the flux for
+   ! a particular e, b, l point has already been found in a previous call
+   ! to function trara2. if not, s.. =.true.
+   s1 = .true.
+   s2 = .true.
+
+   ! energy loop
+
+   do ie = 1 , n
+
+      ! for each energy e(i) find the successive energies e0,e1,e2 in
+      ! model map, which obey  e0 < e1 < e(i) < e2 .
+
+      do while ( (e(ie)>e2) .and. (l3/=0) )
+         i0 = i1
+         i1 = i2
+         i2 = i3
+         i3 = i3 + l3
+         l3 = map(i3+1)
+         e0 = e1
+         e1 = e2
+         e2 = map(i2+2)/escale
+         s0 = s1
+         s1 = s2
+         s2 = .true.
+         f0 = me%f1
+         me%f1 = me%f2
+      enddo
+
+      ! call trara2 to interpolate the flux-maps for e1,e2 in l-b/b0-
+      ! space to find fluxes f1,f2 [if they have not already been
+      ! calculated for a previous e(i)].
+
+      if ( s1 ) me%f1 = me%trara2(map(i1+3),nl,nb)/fscale
+      if ( s2 ) me%f2 = me%trara2(map(i2+3),nl,nb)/fscale
+      s1 = .false.
+      s2 = .false.
+
+      ! finally, interpolate in energy.
+
+      f(ie) = me%f1 + (me%f2-me%f1)*(e(ie)-e1)/(e2-e1)
+      if ( me%f2<=0.0_wp ) then
+         if ( i1/=0 ) then
+            ! --------- special interpolation ---------------------------------
+            ! if the flux for the second energy cannot be found (i.e. f2=0.0),
+            ! and the zeroth energy map has been defined (i.e. i1 not equal 0),
+            ! then interpolate using the flux maps for the zeroth and first
+            ! energy and choose the minimum of this interpolations and the
+            ! interpolation that was done with f2=0.
+            if ( s0 ) f0 = me%trara2(map(i0+3),nl,nb)/fscale
+            s0 = .false.
+            f(ie) = min(f(ie),f0+(me%f1-f0)*(e(ie)-e0)/(e1-e0))
+         endif
+      endif
+
+      ! the logarithmic flux is always kept greater or equal zero.
+
+      f(ie) = max(f(ie),0.0_wp)
+   enddo
+end subroutine trara1
+
+!*****************************************************************************************
+!>
+!  [[trara2]] interpolates linearly in l-b/b0-map to obtain
+!  the logarithm of integral flux at given l and b/b0.
+!
+!### Note
+!  see main program 'model' for explanation of map format
+!  scaling factors.
+
+function trara2(me,map,il,ib)
+
+   class(trm_type),intent(inout) :: me
+   integer,intent(in) :: map(*) !! is sub-map (for specific energy) of
+                                !! trapped radiation model map
+   integer,intent(in) :: il !! scaled l-value
+   integer,intent(in) :: ib !! scaled b/b0-1
+   real(wp) :: trara2 !! scaled logarithm of particle flux
+
+   real(wp) :: dfl , fincr1 , fincr2 , fistep , fkb , fkb1 , fkb2 , fkbj1 , fkbj2 , &
+               fkbm , fll1 , fll2 , flog , flog1 , flog2 , flogm , &
+               fnb , fnl , sl1 , sl2
+   integer :: i1 , i2 , itime , j1 , j2 , kt , l1 , l2
+
+   integer :: spag_nextblock_1
+
+   fistep = me%fistep
+
+   spag_nextblock_1 = 1
+   main: do
+      select case (spag_nextblock_1)
+      case (1)
+         fnl = il
+         fnb = ib
+         itime = 0
+         i2 = 0
+         do
+
+            ! find consecutive sub-sub-maps for scaled l-values ls1,ls2,
+            ! with il less or equal ls2.  l1,l2 are lengths of sub-sub-maps.
+            ! i1,i2 are indeces of first elements minus 1.
+
+            l2 = map(i2+1)
+            if ( map(i2+2)<=il ) then
+               i1 = i2
+               l1 = l2
+               i2 = i2 + l2
+
+               ! if sub-sub-maps are empty, i. e. length less 4, than trara2=0
+
+            elseif ( (l1<4) .and. (l2<4) ) then
+               trara2 = 0.0_wp
+               return
+            else
+
+               ! if flog2 less flog1, than ls2 first map and ls1 second map
+
+               if ( map(i2+3)<=map(i1+3) ) exit
+               spag_nextblock_1 = 3
+               cycle main
+            endif
+         enddo
+         spag_nextblock_1 = 2
+      case (2)
+         kt = i1
+         i1 = i2
+         i2 = kt
+         kt = l1
+         l1 = l2
+         l2 = kt
+         spag_nextblock_1 = 3
+      case (3)
+
+         ! determine interpolate in scaled l-value
+
+         fll1 = map(i1+2)
+         fll2 = map(i2+2)
+         dfl = (fnl-fll1)/(fll2-fll1)
+         flog1 = map(i1+3)
+         flog2 = map(i2+3)
+         fkb1 = 0.0_wp
+         fkb2 = 0.0_wp
+         if ( l1>=4 ) then
+
+            ! b/b0 loop
+
+            do j2 = 4 , l2
+               fincr2 = map(i2+j2)
+               if ( fkb2+fincr2>fnb ) goto 10
+               fkb2 = fkb2 + fincr2
+               flog2 = flog2 - fistep
+            enddo
+            itime = itime + 1
+            if ( itime==1 ) then
+               spag_nextblock_1 = 2
+               cycle main
+            endif
+            trara2 = 0.0_wp
+            return
+ 10         if ( itime/=1 ) then
+               if ( j2==4 ) then
+                  spag_nextblock_1 = 4
+                  cycle main
+               endif
+               sl2 = flog2/fkb2
+               do j1 = 4 , l1
+                  fincr1 = map(i1+j1)
+                  fkb1 = fkb1 + fincr1
+                  flog1 = flog1 - fistep
+                  fkbj1 = ((flog1/fistep)*fincr1+fkb1)/((fincr1/fistep)*sl2+1.0_wp)
+                  if ( fkbj1<=fkb1 ) goto 15
+               enddo
+               if ( fkbj1<=fkb2 ) then
+                  trara2 = 0.0_wp
+                  return
+               endif
+ 15            if ( fkbj1<=fkb2 ) then
+                  fkbm = fkbj1 + (fkb2-fkbj1)*dfl
+                  flogm = fkbm*sl2
+                  flog2 = flog2 - fistep
+                  fkb2 = fkb2 + fincr2
+                  sl1 = flog1/fkb1
+                  sl2 = flog2/fkb2
+                  spag_nextblock_1 = 5
+                  cycle main
+               else
+                  fkb1 = 0.0_wp
+               endif
+            endif
+            fkb2 = 0.0_wp
+         endif
+         j2 = 4
+         fincr2 = map(i2+j2)
+         flog2 = map(i2+3)
+         flog1 = map(i1+3)
+         spag_nextblock_1 = 4
+      case (4)
+         flogm = flog1 + (flog2-flog1)*dfl
+         fkbm = 0.0_wp
+         fkb2 = fkb2 + fincr2
+         flog2 = flog2 - fistep
+         sl2 = flog2/fkb2
+         if ( l1<4 ) then
+            fincr1 = 0.0_wp
+            sl1 = -900000.0_wp
+            spag_nextblock_1 = 6
+            cycle main
+         else
+            j1 = 4
+            fincr1 = map(i1+j1)
+            fkb1 = fkb1 + fincr1
+            flog1 = flog1 - fistep
+            sl1 = flog1/fkb1
+         endif
+         spag_nextblock_1 = 5
+      case (5)
+         do while ( sl1>=sl2 )
+            fkbj2 = ((flog2/fistep)*fincr2+fkb2)/((fincr2/fistep)*sl1+1.0_wp)
+            fkb = fkb1 + (fkbj2-fkb1)*dfl
+            flog = fkb*sl1
+            if ( fkb>=fnb ) then
+               spag_nextblock_1 = 7
+               cycle main
+            endif
+            fkbm = fkb
+            flogm = flog
+            if ( j1>=l1 ) then
+               trara2 = 0.0_wp
+               return
+            else
+               j1 = j1 + 1
+               fincr1 = map(i1+j1)
+               flog1 = flog1 - fistep
+               fkb1 = fkb1 + fincr1
+               sl1 = flog1/fkb1
+            endif
+         enddo
+         spag_nextblock_1 = 6
+      case (6)
+         fkbj1 = ((flog1/fistep)*fincr1+fkb1)/((fincr1/fistep)*sl2+1.0_wp)
+         fkb = fkbj1 + (fkb2-fkbj1)*dfl
+         flog = fkb*sl2
+         if ( fkb<fnb ) then
+            fkbm = fkb
+            flogm = flog
+            if ( j2>=l2 ) then
+               trara2 = 0.0_wp
+               return
+            else
+               j2 = j2 + 1
+               fincr2 = map(i2+j2)
+               flog2 = flog2 - fistep
+               fkb2 = fkb2 + fincr2
+               sl2 = flog2/fkb2
+               spag_nextblock_1 = 5
+               cycle main
+            endif
+         endif
+         spag_nextblock_1 = 7
+      case (7)
+         if ( fkb<fkbm+1.0e-10_wp ) then
+            trara2 = 0.0_wp
+         else
+            trara2 = flogm + (flog-flogm)*((fnb-fkbm)/(fkb-fkbm))
+            trara2 = max(trara2,0.0_wp)
+            return
+         endif
+         exit main
+      end select
+   enddo main
+
+end function trara2
+
+end module trmfun_module
+
+ +
+
+
+ +
+
+
+
+
+

radbelt was developed by Jacob Williams
© 2024 +

+
+
+

+ Documentation generated by + FORD +

+
+
+
+
+
+ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/core.f90 b/src/core.f90 new file mode 100644 index 0000000..e0d1a69 --- /dev/null +++ b/src/core.f90 @@ -0,0 +1,45 @@ +!***************************************************************************************** +!> +! Main module. +! +!### See also +! * https://ccmc.gsfc.nasa.gov/pub/modelweb/geomagnetic/igrf/fortran_code/bilcal.for +! * https://ccmc.gsfc.nasa.gov/pub/modelweb/radiation_belt/radbelt/fortran_code/radbelt.for + +module core + + use radbelt_kinds_module + use trmfun_module + use shellig_module + + implicit none + + public :: get_flux + + contains + +!***************************************************************************************** +!> +! Main routine. + + function get_flux(Lon,Lat,Height,Year,E,Imname) result(flux) + + real(wp),intent(in) :: lon + real(wp),intent(in) :: lat + real(wp),intent(in) :: height + real(wp),intent(in) :: year + real(wp),intent(in) :: e + integer,intent(in) :: imname + real(wp) :: flux + + real(wp) :: xl, bbx + type(trm_type) :: trm + type(shellig_type) :: igrf + + call igrf%igrf(lon,lat,height,year,xl,bbx) + call trm%aep8(e,xl,bbx,imname,flux) + + end function get_flux +!***************************************************************************************** + +end module core diff --git a/src/radbelt_kinds_module.F90 b/src/radbelt_kinds_module.F90 new file mode 100644 index 0000000..b814007 --- /dev/null +++ b/src/radbelt_kinds_module.F90 @@ -0,0 +1,37 @@ +!***************************************************************************************** +!> +! Numeric kind definitions for radbelt. + + module radbelt_kinds_module + + use,intrinsic :: iso_fortran_env + + implicit none + + private + +#ifdef REAL32 + integer,parameter,public :: wp = real32 !! Real working precision [4 bytes] +#elif REAL64 + integer,parameter,public :: wp = real64 !! Real working precision [8 bytes] +#elif REAL128 + integer,parameter,public :: wp = real128 !! Real working precision [16 bytes] +#else + integer,parameter,public :: wp = real64 !! Real working precision if not specified [8 bytes] +#endif + +#ifdef INT8 + integer,parameter,public :: ip = int8 !! Integer working precision [1 byte] +#elif INT16 + integer,parameter,public :: ip = int16 !! Integer working precision [2 bytes] +#elif INT32 + integer,parameter,public :: ip = int32 !! Integer working precision [4 bytes] +#elif INT64 + integer,parameter,public :: ip = int64 !! Integer working precision [8 bytes] +#else + integer,parameter,public :: ip = int32 !! Integer working precision if not specified [4 bytes] +#endif + +!***************************************************************************************** + end module radbelt_kinds_module +!***************************************************************************************** diff --git a/src/shellig.f90 b/src/shellig.f90 new file mode 100644 index 0000000..a4227bd --- /dev/null +++ b/src/shellig.f90 @@ -0,0 +1,941 @@ +!***************************************************************************************** +!> +! IGRF model +! +!### History +! * SHELLIG.FOR, Version 2.0, January 1992 +! * 11/01/91-DKB- SHELLG: lowest starting point for B0 search is 2 +! * 1/27/92-DKB- Adopted to IGRF-91 coefficients model +! * 2/05/92-DKB- Reduce variable-names: INTER(P)SHC,EXTRA(P)SHC,INITI(ALI)ZE +! * 8/08/95-DKB- Updated to IGRF-45-95; new coeff. DGRF90, IGRF95, IGRF95S +! * 5/31/00-DKB- Updated to IGRF-45-00; new coeff.: IGRF00, IGRF00s +! * 3/24/05-DKB- Updated to IGRF-45-10; new coeff.: IGRF05, IGRF05s + + module shellig_module + + use radbelt_kinds_module + + implicit none + + private + + integer,parameter :: filename_len = 14 !! length of the model data file names + + ! parameters formerly in `gener` common block + real(wp),parameter :: Era = 6371.2_wp !! earth radius for normalization of cartesian coordinates (6371.2 km) + real(wp),parameter :: erequ = 6378.16_wp + real(wp),parameter :: erpol = 6356.775_wp + real(wp),parameter :: Aquad = erequ*erequ !! square of major half axis for + !! earth ellipsoid as recommended by international + !! astronomical union + real(wp),parameter :: Bquad = erpol*erpol !! square of minor half axis for + !! earth ellipsoid as recommended by international + !! astronomical union + real(wp),parameter :: Umr = atan(1.0_wp)*4.0_wp/180.0_wp !! atan(1.0)*4./180. *umr= + + real(wp),dimension(3,3),parameter :: u = reshape([ +0.3511737_wp , -0.9148385_wp , -0.1993679_wp , & + +0.9335804_wp , +0.3583680_wp , +0.0000000_wp , & + +0.0714471_wp , -0.1861260_wp , +0.9799247_wp], [3,3]) + + type,public :: shellig_type + private + + ! formerly in the `fidb0` common block + real(wp),dimension(3) :: sp = 0.0_wp + + ! formerly in blank common + real(wp),dimension(3) :: xi = 0.0_wp + real(wp),dimension(144) :: h = 0.0_wp !! Field model coefficients adjusted for [[shellg]] + + ! formerly in `model` common block + integer :: iyea = 0 !! the int year corresponding to the file `name` that has been read + character(len=filename_len) :: name = '' !! file name + integer :: nmax = 0 !! maximum order of spherical harmonics + real(wp) :: Time = 0.0_wp !! year (decimal: 1973.5) for which magnetic field is to be calculated + real(wp),dimension(144) :: g = 0.0_wp !! `g(m)` -- normalized field coefficients (see [[feldcof]]) m=nmax*(nmax+2) + + ! formerly saved vars in shellg: + real(wp) :: step = 0.20_wp !! step size for field line tracing + real(wp) :: steq = 0.03_wp !! step size for integration + + ! from feldcof, so we can cache the coefficients + real(wp),dimension(120) :: gh2 = 0.0_wp ! JW : why is this 120 and g is 144 ??? + + contains + private + + procedure,public :: igrf + + procedure, public :: feldcof + procedure, public :: feldg + procedure, public :: shellg + procedure, public :: findb0 + procedure :: stoer, getshc, intershc, extrashc + + end type shellig_type + + contains +!***************************************************************************************** + +!***************************************************************************************** +!> +! Wrapper for IGRF functions. + + subroutine igrf(me,lon,lat,height,year,xl,bbx) + + class(shellig_type),intent(inout) :: me + real(wp),intent(in) :: lon !! geodetic longitude in degrees (east) + real(wp),intent(in) :: lat !! geodetic latitude in degrees (north) + real(wp),intent(in) :: height !! altitude in km above sea level + real(wp),intent(in) :: year !! decimal year for which geomagnetic field is to + !! be calculated (e.g.:1995.5 for day 185 of 1995) + real(wp),intent(out) :: xl !! l-value + real(wp),intent(out) :: bbx + + real(wp) :: bab1 , babs , bdel , bdown , beast , & + beq , bequ , bnorth , dimo , rr0 + integer :: icode + logical :: val + + real(wp),parameter :: stps = 0.05_wp + + call me%feldcof(year,dimo) + call me%feldg(lat,lon,height,bnorth,beast,bdown,babs) + call me%shellg(lat,lon,height,dimo,xl,icode,bab1) + + bequ = dimo/(xl*xl*xl) + if ( icode==1 ) then + bdel = 1.0e-3_wp + call me%findb0(stps,bdel,val,beq,rr0) + if ( val ) bequ = beq + endif + bbx = babs/bequ + + end subroutine igrf +!***************************************************************************************** + +!***************************************************************************************** +!> + subroutine findb0(me,stps,bdel,value,bequ,rr0) + + class(shellig_type),intent(inout) :: me + real(wp),intent(in) :: stps + real(wp),intent(inout) :: bdel + real(wp),intent(out) :: bequ + logical,intent(out) :: value + real(wp),intent(out) :: rr0 + + real(wp) :: b , bdelta , bmin , bold , bq1 , & + bq2 , bq3 , p(8,4) , r1 , r2 , r3 , & + rold , step , step12 , zz + integer :: i , irun , j , n + + step=stps + irun=0 + + main : do + irun=irun+1 + if (irun>5) then + value=.false. + exit main + endif + !*********************first three points + p(1,2)=me%sp(1) + p(2,2)=me%sp(2) + p(3,2)=me%sp(3) + step=-sign(step,p(3,2)) + call me%stoer(p(1,2),bq2,r2) + p(1,3)=p(1,2)+0.5_wp*step*p(4,2) + p(2,3)=p(2,2)+0.5_wp*step*p(5,2) + p(3,3)=p(3,2)+0.5_wp*step + call me%stoer(p(1,3),bq3,r3) + p(1,1)=p(1,2)-step*(2.0_wp*p(4,2)-p(4,3)) + p(2,1)=p(2,2)-step*(2.0_wp*p(5,2)-p(5,3)) + p(3,1)=p(3,2)-step + call me%stoer(p(1,1),bq1,r1) + p(1,3)=p(1,2)+step*(20.0_wp*p(4,3)-3.*p(4,2)+p(4,1))/18.0_wp + p(2,3)=p(2,2)+step*(20.0_wp*p(5,3)-3.*p(5,2)+p(5,1))/18.0_wp + p(3,3)=p(3,2)+step + call me%stoer(p(1,3),bq3,r3) + !******************invert sense if required + if (bq3>bq1) then + step=-step + r3=r1 + bq3=bq1 + do i=1,5 + zz=p(i,1) + p(i,1)=p(i,3) + p(i,3)=zz + end do + end if + !******************initialization + step12=step/12.0_wp + value=.true. + bmin=1.0e4_wp + bold=1.0e4_wp + !******************corrector (field line tracing) + n=0 + corrector : do + p(1,3)=p(1,2)+step12*(5.0_wp*p(4,3)+8.0_wp*p(4,2)-p(4,1)) + n=n+1 + p(2,3)=p(2,2)+step12*(5.0_wp*p(5,3)+8.0_wp*p(5,2)-p(5,1)) + !******************predictor (field line tracing) + p(1,4)=p(1,3)+step12*(23.0_wp*p(4,3)-16.0_wp*p(4,2)+5.0_wp*p(4,1)) + p(2,4)=p(2,3)+step12*(23.0_wp*p(5,3)-16.0_wp*p(5,2)+5.0_wp*p(5,1)) + p(3,4)=p(3,3)+step + call me%stoer(p(1,4),bq3,r3) + do j=1,3 + do i=1,8 + p(i,j)=p(i,j+1) + end do + end do + b=sqrt(bq3) + if (bbold) exit corrector + bold=b + rold=1.0_wp/r3 + me%sp(1)=p(1,4) + me%sp(2)=p(2,4) + me%sp(3)=p(3,4) + end do corrector + if (bold/=bmin) value=.false. + bdelta=(b-bold)/bold + if (bdelta<=bdel) exit main + step=step/10.0_wp + end do main + + rr0=rold + bequ=bold + bdel=bdelta + + end subroutine findb0 + +!***************************************************************************************** +!> +! calculates l-value for specified geodaetic coordinates, altitude +! and gemagnetic field model. +! +!### Reference +! * G. KLUGE, EUROPEAN SPACE OPERATIONS CENTER, INTERNAL NOTE +! NO. 67, 1970. +! * G. KLUGE, COMPUTER PHYSICS COMMUNICATIONS 3, 31-35, 1972 +! +!### History +! * CHANGES (D. BILITZA, NOV 87): +! - USING CORRECT DIPOL MOMENT I.E.,DIFFERENT COMMON/MODEL/ +! - USING IGRF EARTH MAGNETIC FIELD MODELS FROM 1945 TO 1990 + + subroutine shellg(me,glat,glon,alt,dimo,fl,icode,b0) + + class(shellig_type),intent(inout) :: me + real(wp),intent(in) :: glat !! GEODETIC LATITUDE IN DEGREES (NORTH) + real(wp),intent(in) :: glon !! GEODETIC LONGITUDE IN DEGREES (EAST) + real(wp),intent(in) :: alt !! ALTITUDE IN KM ABOVE SEA LEVEL + real(wp),intent(in) :: dimo !! DIPOL MOMENT IN GAUSS (NORMALIZED TO EARTH RADIUS) + real(wp),intent(out) :: fl !! l-value + integer,intent(out) :: icode !! * =1 normal completion + !! * =2 unphysical conjugate point (fl meaningless) + !! * =3 shell parameter greater than limit up to + !! which accurate calculation is required; + !! approximation is used. + real(wp),intent(out) :: b0 !! magnetic field strength in gauss + + real(wp) :: arg1 , arg2 , bequ , bq1 , bq2 , bq3 , c0 , c1 , c2 , c3 , & + ct , d , d0 , d1 , d2, dimob0 , e0 , e1 , e2 , ff , fi , gg , & + hli , oradik , oterm , p(8,100) , r , r1 , r2 , r3 , r3h , radik , & + rlat , rlon , rq , st , step12 , step2 , & + stp , t , term , v(3) , xx , z , zq , zz + integer :: i , iequ , n + + real(wp),parameter :: rmin = 0.05_wp !! boundaries for identification of `icode=2 and 3` + real(wp),parameter :: rmax = 1.01_wp !! boundaries for identification of `icode=2 and 3` + + bequ = 1.0e10_wp + + !*****ENTRY POINT SHELLG TO BE USED WITH GEODETIC CO-ORDINATES + rlat = Glat*Umr + ct = sin(rlat) + st = cos(rlat) + d = sqrt(Aquad-(Aquad-Bquad)*ct*ct) + me%Xi(1) = (Alt+Aquad/d)*st/Era + me%Xi(3) = (Alt+Bquad/d)*ct/Era + rlon = Glon*Umr + me%Xi(2) = me%Xi(1)*sin(rlon) + me%Xi(1) = me%Xi(1)*cos(rlon) + CALL spag_block_1() + RETURN + +!*****ENTRY POINT SHELLC TO BE USED WITH CARTESIAN CO-ORDINATES ! JW : does not appear to be used anywhere. +! V(3) CARTESIAN COORDINATES IN EARTH RADII (6371.2 KM) +! X-AXIS POINTING TO EQUATOR AT 0 LONGITUDE +! Y-AXIS POINTING TO EQUATOR AT 90 LONG. +! Z-AXIS POINTING TO NORTH POLE + ENTRY shellc(me,V,Fl,B0) + me%Xi(1) = V(1) + me%Xi(2) = V(2) + me%Xi(3) = V(3) + CALL spag_block_1() + +CONTAINS + + subroutine spag_block_1 + + integer,parameter :: max_loop_index = 100 ! 3333 <--- JW : original code had 3333 ... was this a bug ???? + + !*****CONVERT TO DIPOL-ORIENTED CO-ORDINATES + rq = 1.0_wp/(me%Xi(1)*me%Xi(1)+me%Xi(2)*me%Xi(2)+me%Xi(3)*me%Xi(3)) + r3h = sqrt(rq*sqrt(rq)) + p(1,2) = (me%Xi(1)*u(1,1)+me%Xi(2)*u(2,1)+me%Xi(3)*u(3,1))*r3h + p(2,2) = (me%Xi(1)*u(1,2)+me%Xi(2)*u(2,2))*r3h + p(3,2) = (me%Xi(1)*u(1,3)+me%Xi(2)*u(2,3)+me%Xi(3)*u(3,3))*rq + ! *****FIRST THREE POINTS OF FIELD LINE + me%step = -sign(me%step,p(3,2)) + call me%stoer(p(1,2),bq2,r2) + B0 = sqrt(bq2) + p(1,3) = p(1,2) + 0.5_wp*me%step*p(4,2) + p(2,3) = p(2,2) + 0.5_wp*me%step*p(5,2) + p(3,3) = p(3,2) + 0.5_wp*me%step + call me%stoer(p(1,3),bq3,r3) + p(1,1) = p(1,2) - me%step*(2.0_wp*p(4,2)-p(4,3)) + p(2,1) = p(2,2) - me%step*(2.0_wp*p(5,2)-p(5,3)) + p(3,1) = p(3,2) - me%step + call me%stoer(p(1,1),bq1,r1) + p(1,3) = p(1,2) + me%step*(20.0_wp*p(4,3)-3.*p(4,2)+p(4,1))/18.0_wp + p(2,3) = p(2,2) + me%step*(20.0_wp*p(5,3)-3.*p(5,2)+p(5,1))/18.0_wp + p(3,3) = p(3,2) + me%step + call me%stoer(p(1,3),bq3,r3) + !*****INVERT SENSE IF REQUIRED + IF ( bq3>bq1 ) THEN + me%step = -me%step + r3 = r1 + bq3 = bq1 + DO i = 1 , 7 + zz = p(i,1) + p(i,1) = p(i,3) + p(i,3) = zz + ENDDO + ENDIF + !*****SEARCH FOR LOWEST MAGNETIC FIELD STRENGTH + IF ( bq11.0_wp ) THEN + !*****PREDICTOR (FIELD LINE TRACING) + p(1,n+1) = p(1,n) + step12*(23.0_wp*p(4,n)-16.0_wp*p(4,n-1)+5.0_wp*p(4,n-2)) + p(2,n+1) = p(2,n) + step12*(23.0_wp*p(5,n)-16.0_wp*p(5,n-1)+5.0_wp*p(5,n-2)) + p(3,n+1) = p(3,n) + me%step + call me%stoer(p(1,n+1),bq3,r3) + !*****SEARCH FOR LOWEST MAGNETIC FIELD STRENGTH + IF ( bq3rmax ) THEN + Icode = 2 + radik = radik - 12.0_wp*(r-rmax)**2 + ENDIF + IF ( radik+radik<=oradik ) EXIT main + term = sqrt(radik)*ff*((e2*t+e1)*t+e0)/(rq+zq) + fi = fi + stp*(oterm+term) + oradik = radik + oterm = term + stp = r*me%steq + z = z + stp + ENDIF + ENDDO inner + ENDDO main + IF ( iequ<2 ) iequ = 2 + me%Sp(1) = p(1,iequ-1) + me%Sp(2) = p(2,iequ-1) + me%Sp(3) = p(3,iequ-1) + IF ( oradik>=1.0e-15_wp ) fi = fi + stp/0.75_wp*oterm*oradik/(oradik-radik) + ! + !-- The minimal allowable value of FI was changed from 1E-15 to 1E-12, + !-- because 1E-38 is the minimal allowable arg. for ALOG in our envir. + !-- D. Bilitza, Nov 87. + ! + fi = 0.5_wp*abs(fi)/sqrt(B0) + 1.0e-12_wp + !*****COMPUTE L FROM B AND I. SAME AS CARMEL IN INVAR. + ! + !-- Correct dipole moment is used here. D. Bilitza, Nov 87. + ! + dimob0 = Dimo/B0 + arg1 = log(fi) + arg2 = log(dimob0) +! arg = FI*FI*FI/DIMOB0 +! if(abs(arg)>88.0_wp) arg=88.0_wp + xx = 3*arg1 - arg2 + IF ( xx>23.0_wp ) THEN + gg = xx - 3.0460681_wp + ELSEIF ( xx>11.7_wp ) THEN + gg = (((((2.8212095E-8_wp*xx-3.8049276E-6_wp)*xx+& + 2.170224E-4_wp)*xx-6.7310339E-3_wp)*xx+& + 1.2038224E-1_wp)*xx-1.8461796E-1_wp)*xx + 2.0007187_wp + ELSEIF ( xx>+3.0_wp ) THEN + gg = ((((((((6.3271665E-10_wp*xx-3.958306E-8_wp)*xx+& + 9.9766148E-07_wp)*xx-1.2531932E-5_wp)*xx+& + 7.9451313E-5_wp)*xx-3.2077032E-4_wp)*xx+& + 2.1680398E-3_wp)*xx+1.2817956E-2_wp)*xx+& + 4.3510529E-1_wp)*xx + 6.222355E-1_wp + ELSEIF ( xx>-3.0_wp ) THEN + gg = ((((((((2.6047023E-10_wp*xx+2.3028767E-9_wp)*xx-& + 2.1997983E-8_wp)*xx-5.3977642E-7_wp)*xx-& + 3.3408822E-6_wp)*xx+3.8379917E-5_wp)*xx+& + 1.1784234E-3_wp)*xx+1.4492441E-2_wp)*xx+& + 4.3352788E-1_wp)*xx + 6.228644E-1_wp + ELSEIF ( xx>-22.0_wp ) THEN + gg = ((((((((-8.1537735E-14_wp*xx+8.3232531E-13_wp)*xx+& + 1.0066362E-9_wp)*xx+8.1048663E-8_wp)*xx+& + 3.2916354E-6_wp)*xx+8.2711096E-5_wp)*xx+& + 1.3714667E-3_wp)*xx+1.5017245E-2_wp)*xx+& + 4.3432642E-1_wp)*xx + 6.2337691E-1_wp + ELSE + gg = 3.33338E-1_wp*xx + 3.0062102E-1_wp + ENDIF + Fl = exp(log((1.0_wp+exp(gg))*dimob0)/3.0_wp) + RETURN + END subroutine spag_block_1 + +END subroutine shellg + +!***************************************************************************************** +!> +! subroutine used for field line tracing in [[shellg]] +! calls entry point [[feldi]] in geomagnetic field subroutine [[feldg]] + +subroutine stoer(me,p,bq,r) + + class(shellig_type),intent(inout) :: me + real(wp),dimension(7),intent(inout) :: p + real(wp),intent(out) :: bq + real(wp),intent(out) :: r + + real(wp) :: dr , dsq , dx , dxm , dy , dym , dz , & + dzm , fli , q , rq , wr , xm , ym , zm + +!*****XM,YM,ZM ARE GEOMAGNETIC CARTESIAN INVERSE CO-ORDINATES + zm = P(3) + fli = P(1)*P(1) + P(2)*P(2) + 1.0e-15_wp + R = 0.5_wp*(fli+sqrt(fli*fli+(zm+zm)**2)) + rq = R*R + wr = sqrt(R) + xm = P(1)*wr + ym = P(2)*wr +!*****TRANSFORM TO GEOGRAPHIC CO-ORDINATE SYSTEM + me%Xi(1) = xm*u(1,1) + ym*u(1,2) + zm*u(1,3) + me%Xi(2) = xm*u(2,1) + ym*u(2,2) + zm*u(2,3) + me%Xi(3) = xm*u(3,1) + zm*u(3,3) +!*****COMPUTE DERIVATIVES +! Changed from CALL FELDI(XI,H); XI, H are in COMMON block; results +! are the same; dkb Feb 1998. +! JW : feb 2024 : xi, h now class variables. + CALL feldi(me) + q = me%H(1)/rq + dx = me%H(3) + me%H(3) + q*me%Xi(1) + dy = me%H(4) + me%H(4) + q*me%Xi(2) + dz = me%H(2) + me%H(2) + q*me%Xi(3) +!*****TRANSFORM BACK TO GEOMAGNETIC CO-ORDINATE SYSTEM + dxm = u(1,1)*dx + u(2,1)*dy + u(3,1)*dz + dym = u(1,2)*dx + u(2,2)*dy + dzm = u(1,3)*dx + u(2,3)*dy + u(3,3)*dz + dr = (xm*dxm+ym*dym+zm*dzm)/R +!*****FORM SLOWLY VARYING EXPRESSIONS + P(4) = (wr*dxm-0.5_wp*P(1)*dr)/(R*dzm) + P(5) = (wr*dym-0.5_wp*P(2)*dr)/(R*dzm) + dsq = rq*(dxm*dxm+dym*dym+dzm*dzm) + Bq = dsq*rq*rq + P(6) = sqrt(dsq/(rq+3.0_wp*zm*zm)) + P(7) = P(6)*(rq+zm*zm)/(rq*dzm) +END subroutine stoer + +!***************************************************************************************** +!> +! Calculates earth magnetic field from spherical harmonics model +! +!### Reference +! ref: g. kluge, european space operations centre, internal note 61, +! 1970. +! +!### History +! * changes (d. bilitza, nov 87): +! - field coefficients in binary data files instead of block data +! - calculates dipol moment + +subroutine feldg(me,glat,glon,alt,bnorth,beast,bdown,babs) + + class(shellig_type),intent(inout) :: me + real(wp),intent(in) :: glat !! geodetic latitude in degrees (north) + real(wp),intent(in) :: glon !! geodetic longitude in degrees (east) + real(wp),intent(in) :: alt !! altitude in km above sea level + real(wp),intent(out) :: bnorth, beast, bdown !! components of the field with respect + !! to the local geodetic coordinate system, with axis + !! pointing in the tangential plane to the north, east + !! and downward. + real(wp),intent(out) :: Babs !! magnetic field strength in gauss + + real(wp) :: b(3) , brho , bxxx , & + byyy , bzzz , cp , ct , d , f , rho , & + rlat , rlon , rq , s , sp , st , t , v(3) , x , xxx , & + y , yyy , z , zzz + integer :: i , ih , ihmax , il , imax , is , k , last , m + + !-- is records entry point + ! + !*****entry point feldg to be used with geodetic co-ordinates + is=1 + rlat=glat*umr + ct=sin(rlat) + st=cos(rlat) + d=sqrt(aquad-(aquad-bquad)*ct*ct) + rlon=glon*umr + cp=cos(rlon) + sp=sin(rlon) + zzz=(alt+bquad/d)*ct/era + rho=(alt+aquad/d)*st/era + xxx=rho*cp + yyy=rho*sp + goto 10 + + !*****entry point feldc to be used with cartesian co-ordinates + ! v(3) cartesian coordinates in earth radii (6371.2 km) + ! x-axis pointing to equator at 0 longitude + ! y-axis pointing to equator at 90 long. + ! z-axis pointing to north pole + entry feldc(me,v,b) + is=2 + xxx=v(1) + yyy=v(2) + zzz=v(3) + + 10 rq=1.0_wp/(xxx*xxx+yyy*yyy+zzz*zzz) + me%xi(1)=xxx*rq + me%xi(2)=yyy*rq + me%xi(3)=zzz*rq + goto 20 + + !*****entry point feldi used for l computation + entry feldi(me) + is=3 + 20 ihmax=me%nmax*me%nmax+1 + last=ihmax+me%nmax+me%nmax + imax=me%nmax+me%nmax-1 + do i=ihmax,last + me%h(i)=me%g(i) + end do + do k=1,3,2 + i=imax + ih=ihmax + do + il=ih-i + f=2.0_wp/real(i-k+2, wp) + x=me%xi(1)*f + y=me%xi(2)*f + z=me%xi(3)*(f+f) + i=i-2 + if ((i-1)>=0) then + if ((i-1)>0) then + do m=3,i,2 + me%h(il+m+1)=me%g(il+m+1)+z*me%h(ih+m+1)+x*(me%h(ih+m+3)-& + me%h(ih+m-1))-y*(me%h(ih+m+2)+me%h(ih+m-2)) + me%h(il+m)=me%g(il+m)+z*me%h(ih+m)+x*(me%h(ih+m+2)-& + me%h(ih+m-2))+y*(me%h(ih+m+3)+me%h(ih+m-1)) + end do + end if + me%h(il+2)=me%g(il+2)+z*me%h(ih+2)+x*me%h(ih+4)-y*(me%h(ih+3)+me%h(ih)) + me%h(il+1)=me%g(il+1)+z*me%h(ih+1)+y*me%h(ih+4)+x*(me%h(ih+3)-me%h(ih)) + end if + me%h(il)=me%g(il)+z*me%h(ih)+2.0_wp*(x*me%h(ih+1)+y*me%h(ih+2)) + ih=il + if (i +! Determines coefficients and dipol moment from IGRF models +! +!### Author +! * D. BILITZA, NSSDC, GSFC, CODE 633, GREENBELT, MD 20771, +! (301) 286-9536 NOV 1987. +! +!### History +! * corrected for 2000 update - dkb- 5/31/2000 +! * updated to IGRF-2000 version -dkb- 5/31/2000 +! * updated to IGRF-2005 version -dkb- 3/24/2000 + + subroutine feldcof(me,year,dimo) + + class(shellig_type),intent(inout) :: me + real(wp),intent(in) :: year !! decimal year for which geomagnetic field is to + !! be calculated (e.g.:1995.5 for day 185 of 1995) + real(wp),intent(out) :: dimo !! geomagnetic dipol moment in gauss (normalized + !! to earth's radius) at the time (year) + + real(wp) :: dte1 , dte2 , erad , gha(144) , sqrt2 + integer :: i , ier , j , l , m , n , nmax1 , nmax2, iyea + character(len=filename_len) :: fil2 + real(wp) :: x , f0 , f !! these were double precision in original + !! code while everything else was single precision + + ! changed to conform with IGRF 45-95, also FILMOD, DTEMOD arrays +1 + character(len=filename_len),dimension(17),parameter :: filmod = [& + 'dgrf1945.dat ' , 'dgrf1950.dat ' , 'dgrf1955.dat ' , 'dgrf1960.dat ' , & + 'dgrf1965.dat ' , 'dgrf1970.dat ' , 'dgrf1975.dat ' , 'dgrf1980.dat ' , & + 'dgrf1985.dat ' , 'dgrf1990.dat ' , 'dgrf1995.dat ' , 'dgrf2000.dat ' , & + 'dgrf2005.dat ' , 'dgrf2010.dat ' , 'dgrf2015.dat ' , 'igrf2020.dat ' , & + 'igrf2020s.dat'] + real(wp),dimension(17),parameter :: dtemod = [1945.0_wp , 1950.0_wp , 1955.0_wp , & + 1960.0_wp , 1965.0_wp , 1970.0_wp , & + 1975.0_wp , 1980.0_wp , 1985.0_wp , & + 1990.0_wp , 1995.0_wp , 2000.0_wp , & + 2005.0_wp , 2010.0_wp , 2015.0_wp , & + 2020.0_wp , 2025.0_wp] + integer,parameter :: numye = size(dtemod)-1 ! number of 5-year priods represented by IGRF + integer,parameter :: is = 0 !! * is=0 for schmidt normalization + !! * is=1 gauss normalization + + logical :: read_file + + !-- determine igrf-years for input-year + me%time = year + iyea = int(year/5.0_wp)*5 + read_file = iyea /= me%iyea ! if we have to read the file + me%iyea = iyea + l = (me%iyea-1945)/5 + 1 + if ( l<1 ) l = 1 + if ( l>numye ) l = numye + dte1 = dtemod(l) + me%name = filmod(l) + dte2 = dtemod(l+1) + fil2 = filmod(l+1) + if (read_file) then + ! get igrf coefficients for the boundary years + ! [if they have not ready been loaded] + call me%getshc(me%name,nmax1,erad,me%g,ier) + if ( ier/=0 ) error stop 'error reading file: '//trim(me%name) + call me%getshc(fil2,nmax2,erad,me%gh2,ier) + if ( ier/=0 ) error stop 'error reading file: '//trim(fil2) + end if + !-- determine igrf coefficients for year + if ( l<=numye-1 ) then + call me%intershc(year,dte1,nmax1,me%g,dte2,nmax2,me%gh2,me%nmax,gha) + else + call me%extrashc(year,dte1,nmax1,me%g,nmax2,me%gh2,me%nmax,gha) + endif + !-- determine magnetic dipol moment and coeffiecients g + f0 = 0.0_wp + do j = 1 , 3 + f = gha(j)*1.0e-5_wp + f0 = f0 + f*f + enddo + dimo = sqrt(f0) + + me%g(1) = 0.0_wp + i = 2 + f0 = 1.0e-5_wp + if ( is==0 ) f0 = -f0 + sqrt2 = sqrt(2.0_wp) + + do n = 1 , me%nmax + x = n + f0 = f0*x*x/(4.0_wp*x-2.0_wp) + if ( is==0 ) f0 = f0*(2.0_wp*x-1.0_wp)/x + f = f0*0.5_wp + if ( is==0 ) f = f*sqrt2 + me%g(i) = gha(i-1)*f0 + i = i + 1 + do m = 1 , n + f = f*(x+m)/(x-m+1.0_wp) + if ( is==0 ) f = f*sqrt((x-m+1.0_wp)/(x+m)) + me%g(i) = gha(i-1)*f + me%g(i+1) = gha(i)*f + i = i + 2 + enddo + enddo + +end subroutine feldcof + +!***************************************************************************************** +!> +! Reads spherical harmonic coefficients from the specified +! file into an array. +! +!### Author +! * Version 1.01, A. Zunde, USGS, MS 964, +! Box 25046 Federal Center, Denver, CO 80225 + +subroutine getshc(me,Fspec,Nmax,Erad,Gh,Ier) + + class(shellig_type),intent(inout) :: me + character(len=*),intent(in) :: Fspec !! File specification + integer,intent(out) :: Nmax !! Maximum degree and order of model + real(wp),intent(out) :: Erad !! Earth's radius associated with the spherical + !! harmonic coefficients, in the same units as + !! elevation + real(wp),dimension(*),intent(out) :: Gh !! Schmidt quasi-normal internal spherical + !! harmonic coefficients + integer,intent(out) :: Ier !! Error number: + !! + !! * 0, no error + !! * -2, records out of order + !! * FORTRAN run-time error number + + integer :: iu !! logical unit number + real(wp) :: g , h + integer :: i , m , mm , n , nn + + read_file : block + ! --------------------------------------------------------------- + ! Open coefficient file. Read past first header record. + ! Read degree and order of model and Earth's radius. + ! --------------------------------------------------------------- + OPEN (newunit=Iu,FILE=Fspec,STATUS='OLD',IOSTAT=Ier) + if (Ier/=0) then + write(*,*) 'Error opening file: '//trim(fspec) + exit read_file + end if + READ (Iu,*,IOSTAT=Ier) + if (Ier/=0) exit read_file + READ (Iu,*,IOSTAT=Ier) Nmax , Erad + if (Ier/=0) exit read_file + + ! --------------------------------------------------------------- + ! Read the coefficient file, arranged as follows: + ! + ! N M G H + ! ---------------------- + ! / 1 0 GH(1) - + ! / 1 1 GH(2) GH(3) + ! / 2 0 GH(4) - + ! / 2 1 GH(5) GH(6) + ! NMAX*(NMAX+3)/2 / 2 2 GH(7) GH(8) + ! records \ 3 0 GH(9) - + ! \ . . . . + ! \ . . . . + ! NMAX*(NMAX+2) \ . . . . + ! elements in GH \ NMAX NMAX . . + ! + ! N and M are, respectively, the degree and order of the + ! coefficient. + ! --------------------------------------------------------------- + i = 0 + main: DO nn = 1 , Nmax + DO mm = 0 , nn + READ (Iu,*,IOSTAT=Ier) n , m , g , h + if (Ier/=0) exit main + IF ( nn/=n .OR. mm/=m ) THEN + Ier = -2 + EXIT main + ENDIF + i = i + 1 + Gh(i) = g + IF ( m/=0 ) THEN + i = i + 1 + Gh(i) = h + ENDIF + ENDDO + ENDDO main + + end block read_file + + CLOSE (Iu) + +END subroutine getshc + +!***************************************************************************************** +!> +! Interpolates linearly, in time, between two spherical +! harmonic models. +! +! The coefficients (GH) of the resulting model, at date +! DATE, are computed by linearly interpolating between the +! coefficients of the earlier model (GH1), at date DTE1, +! and those of the later model (GH2), at date DTE2. If one +! model is smaller than the other, the interpolation is +! performed with the missing coefficients assumed to be 0. +! +!### Author +! * Version 1.01, A. Zunde +! USGS, MS 964, Box 25046 Federal Center, Denver, CO 80225 + +subroutine intershc(me,date,dte1,nmax1,gh1,dte2,nmax2,gh2,nmax,gh) + + class(shellig_type),intent(inout) :: me + real(wp),intent(in) :: date !! Date of resulting model (in decimal year) + real(wp),intent(in) :: dte1 !! Date of earlier model + integer,intent(in) :: nmax1 !! Maximum degree and order of earlier model + real(wp),intent(in) :: gh1(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of earlier model + real(wp),intent(in) :: dte2 !! Date of later model + integer,intent(in) :: nmax2 !! Maximum degree and order of later model + real(wp),intent(in) :: gh2(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of later model + real(wp),intent(out) :: gh(*) !! Coefficients of resulting model + integer,intent(out) :: nmax !! Maximum degree and order of resulting model + + real(wp) :: factor + integer :: i , k , l + + factor = (date-dte1)/(dte2-dte1) + + if ( nmax1==nmax2 ) then + k = nmax1*(nmax1+2) + nmax = nmax1 + elseif ( nmax1>nmax2 ) then + k = nmax2*(nmax2+2) + l = nmax1*(nmax1+2) + do i = k + 1 , l + gh(i) = gh1(i) + factor*(-gh1(i)) + enddo + nmax = nmax1 + else + k = nmax1*(nmax1+2) + l = nmax2*(nmax2+2) + do i = k + 1 , l + gh(i) = factor*gh2(i) + enddo + nmax = nmax2 + endif + + do i = 1 , k + gh(i) = gh1(i) + factor*(gh2(i)-gh1(i)) + enddo + +end subroutine intershc + +!***************************************************************************************** +!> +! Extrapolates linearly a spherical harmonic model with a +! rate-of-change model. +! +! The coefficients (GH) of the resulting model, at date +! DATE, are computed by linearly extrapolating the coef- +! ficients of the base model (GH1), at date DTE1, using +! those of the rate-of-change model (GH2), at date DTE2. If +! one model is smaller than the other, the extrapolation is +! performed with the missing coefficients assumed to be 0. +! +!### Author +! * Version 1.01, A. Zunde +! USGS, MS 964, Box 25046 Federal Center, Denver, CO 80225 + +subroutine extrashc(me,date,dte1,nmax1,gh1,nmax2,gh2,nmax,gh) + + class(shellig_type),intent(inout) :: me + real(wp),intent(in) :: date !! Date of resulting model (in decimal year) + real(wp),intent(in) :: dte1 !! Date of base model + integer,intent(in) :: nmax1 !! Maximum degree and order of base model + real(wp),intent(in) :: gh1(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of base model + integer,intent(in) :: nmax2 !! Maximum degree and order of rate-of-change model + real(wp),intent(in) :: gh2(*) !! Schmidt quasi-normal internal spherical harmonic coefficients of rate-of-change model + real(wp),intent(out) :: gh(*) !! Coefficients of resulting model + integer,intent(out) :: nmax !! Maximum degree and order of resulting model + + real(wp) :: factor + integer :: i , k , l + + factor = (date-dte1) + + if ( nmax1==nmax2 ) then + k = nmax1*(nmax1+2) + nmax = nmax1 + elseif ( nmax1>nmax2 ) then + k = nmax2*(nmax2+2) + l = nmax1*(nmax1+2) + do i = k + 1 , l + gh(i) = gh1(i) + enddo + nmax = nmax1 + else + k = nmax1*(nmax1+2) + l = nmax2*(nmax2+2) + do i = k + 1 , l + gh(i) = factor*gh2(i) + enddo + nmax = nmax2 + endif + + do i = 1 , k + gh(i) = gh1(i) + factor*gh2(i) + enddo + +end subroutine extrashc + +end module SHELLIG_module \ No newline at end of file diff --git a/src/trmfun.f90 b/src/trmfun.f90 new file mode 100644 index 0000000..baab593 --- /dev/null +++ b/src/trmfun.f90 @@ -0,0 +1,417 @@ +!***************************************************************************************** +!> +! Trapped radiation model. +! +!### History +! * Based on: `trmfun.for` 1987 + +module trmfun_module + + use radbelt_kinds_module + + implicit none + + private + + character(len=10),dimension(4),parameter :: mname = [ 'ae8min.asc' , & + 'ae8max.asc' , & + 'ap8min.asc' , & + 'ap8max.asc'] !! data files available + + type,public :: trm_type + !! main class for the `aep8` model + private + + ! data read from the files: + character(len=:),allocatable :: file_loaded !! the file that has been loaded + integer,dimension(8) :: ihead = 0 + integer,dimension(:),allocatable :: map + + real(wp) :: fistep = 0.0_wp !! the stepsize for the parameterization of the logarithm of flux. + !! formerly stored in common block `tra2` + + ! formerly saved variables in trara1: + real(wp) :: f1 = 1.001_wp + real(wp) :: f2 = 1.002_wp + + contains + private + procedure,public :: aep8 !! main routine + procedure,public :: trara1, trara2 !! low-level routine + end type trm_type + + contains + +!***************************************************************************************** +!> +! Main wrapper for the radiation model. +! Reads the coefficient file and calls the low-level routine. + + subroutine aep8(me,e,l,bb0,imname,flux) + + class(trm_type),intent(inout) :: me + + real(wp),intent(in) :: e + real(wp),intent(in) :: l + real(wp),intent(in) :: bb0 + integer,intent(in) :: imname !! which model to load (index in `mname` array) + real(wp),intent(out) :: flux + + real(wp) :: ee(1), f(1) !! temp variables + integer :: i , ierr, iuaeap , nmap + character(len=len(mname)) :: name + logical :: load_file + + name = mname(Imname) ! the file to load + + ! check to see if this file has already been loaded + ! [the class can store one file at a time] + load_file = .true. + if (allocated(me%file_loaded)) then + if (name == me%file_loaded) load_file = .false. + end if + + if (load_file) then + open (newunit = iuaeap,file=name,status='OLD',iostat=ierr,form='FORMATTED') + if ( ierr/=0 ) then + error stop 'error reading '//trim(name) + end if + read (iuaeap,'(1X,12I6)') me%ihead + nmap = me%ihead(8) + allocate(me%map(nmap)) + read (iuaeap,'(1X,12I6)') (me%map(i),i=1,nmap) + close (iuaeap) + me%file_loaded = trim(name) + end if + + ee(1) = e + call me%trara1(me%ihead,me%map,L,Bb0,ee,f,1) + flux = f(1) + IF ( Flux>0.0_wp ) Flux = 10.0_wp**Flux + + end subroutine aep8 +!***************************************************************************************** + +!***************************************************************************************** +!> +! [[trara1]] finds particle fluxes for given energies, magnetic field +! strength and l-value. function [[trara2]] is used to interpolate in +! b-l-space. + + subroutine trara1(me,descr,map,fl,bb0,e,f,n) + + class(trm_type),intent(inout) :: me + integer,intent(in) :: n !! number of energies + integer,intent(in) :: descr(8) !! header of specified trapped radition model + real(wp),intent(in) :: e(n) !! array of energies in mev + real(wp),intent(in) :: fl !! l-value + real(wp),intent(in) :: bb0 !! =b/b0 magnetic field strength normalized + !! to field strength at magnetic equator + integer,intent(in) :: map(*) !! map of trapped radition model + !! (descr and map are explained at the begin + !! of the main program model) + real(wp),intent(out) :: f(n) !! decadic logarithm of integral fluxes in + !! particles/(cm*cm*sec) + + real(wp) :: e0 , e1 , e2 , escale , f0 , fscale , xnl + real(wp) :: bb0_ !! local copy of `bb0`. in the original code + !! this was modified by this routine. + !! added this so `bb0` could be `intent(in)` + integer :: i0 , i1 , i2 , i3 , ie , l3 , nb , nl + logical :: s0 , s1 , s2 + + bb0_ = bb0 + me%fistep = descr(7)/descr(2) + escale = descr(4) + fscale = descr(7) + xnl = min(15.6_wp,abs(fl)) + nl = xnl*descr(5) + if ( bb0_<1.0_wp ) bb0_ = 1.0_wp + nb = (bb0_-1.0_wp)*descr(6) + + ! i2 is the number of elements in the flux map for the first energy. + ! i3 is the index of the last element of the second energy map. + ! l3 is the length of the map for the third energy. + ! e1 is the energy of the first energy map (unscaled) + ! e2 is the energy of the second energy map (unscaled) + i1 = 0 + i2 = map(1) + i3 = i2 + map(i2+1) + l3 = map(i3+1) + e1 = map(i1+2)/escale + e2 = map(i2+2)/escale + + ! s0, s1, s2 are logical variables which indicate whether the flux for + ! a particular e, b, l point has already been found in a previous call + ! to function trara2. if not, s.. =.true. + s1 = .true. + s2 = .true. + + ! energy loop + + do ie = 1 , n + + ! for each energy e(i) find the successive energies e0,e1,e2 in + ! model map, which obey e0 < e1 < e(i) < e2 . + + do while ( (e(ie)>e2) .and. (l3/=0) ) + i0 = i1 + i1 = i2 + i2 = i3 + i3 = i3 + l3 + l3 = map(i3+1) + e0 = e1 + e1 = e2 + e2 = map(i2+2)/escale + s0 = s1 + s1 = s2 + s2 = .true. + f0 = me%f1 + me%f1 = me%f2 + enddo + + ! call trara2 to interpolate the flux-maps for e1,e2 in l-b/b0- + ! space to find fluxes f1,f2 [if they have not already been + ! calculated for a previous e(i)]. + + if ( s1 ) me%f1 = me%trara2(map(i1+3),nl,nb)/fscale + if ( s2 ) me%f2 = me%trara2(map(i2+3),nl,nb)/fscale + s1 = .false. + s2 = .false. + + ! finally, interpolate in energy. + + f(ie) = me%f1 + (me%f2-me%f1)*(e(ie)-e1)/(e2-e1) + if ( me%f2<=0.0_wp ) then + if ( i1/=0 ) then + ! --------- special interpolation --------------------------------- + ! if the flux for the second energy cannot be found (i.e. f2=0.0), + ! and the zeroth energy map has been defined (i.e. i1 not equal 0), + ! then interpolate using the flux maps for the zeroth and first + ! energy and choose the minimum of this interpolations and the + ! interpolation that was done with f2=0. + if ( s0 ) f0 = me%trara2(map(i0+3),nl,nb)/fscale + s0 = .false. + f(ie) = min(f(ie),f0+(me%f1-f0)*(e(ie)-e0)/(e1-e0)) + endif + endif + + ! the logarithmic flux is always kept greater or equal zero. + + f(ie) = max(f(ie),0.0_wp) + enddo +end subroutine trara1 + +!***************************************************************************************** +!> +! [[trara2]] interpolates linearly in l-b/b0-map to obtain +! the logarithm of integral flux at given l and b/b0. +! +!### Note +! see main program 'model' for explanation of map format +! scaling factors. + +function trara2(me,map,il,ib) + + class(trm_type),intent(inout) :: me + integer,intent(in) :: map(*) !! is sub-map (for specific energy) of + !! trapped radiation model map + integer,intent(in) :: il !! scaled l-value + integer,intent(in) :: ib !! scaled b/b0-1 + real(wp) :: trara2 !! scaled logarithm of particle flux + + real(wp) :: dfl , fincr1 , fincr2 , fistep , fkb , fkb1 , fkb2 , fkbj1 , fkbj2 , & + fkbm , fll1 , fll2 , flog , flog1 , flog2 , flogm , & + fnb , fnl , sl1 , sl2 + integer :: i1 , i2 , itime , j1 , j2 , kt , l1 , l2 + + integer :: spag_nextblock_1 + + fistep = me%fistep + + spag_nextblock_1 = 1 + main: do + select case (spag_nextblock_1) + case (1) + fnl = il + fnb = ib + itime = 0 + i2 = 0 + do + + ! find consecutive sub-sub-maps for scaled l-values ls1,ls2, + ! with il less or equal ls2. l1,l2 are lengths of sub-sub-maps. + ! i1,i2 are indeces of first elements minus 1. + + l2 = map(i2+1) + if ( map(i2+2)<=il ) then + i1 = i2 + l1 = l2 + i2 = i2 + l2 + + ! if sub-sub-maps are empty, i. e. length less 4, than trara2=0 + + elseif ( (l1<4) .and. (l2<4) ) then + trara2 = 0.0_wp + return + else + + ! if flog2 less flog1, than ls2 first map and ls1 second map + + if ( map(i2+3)<=map(i1+3) ) exit + spag_nextblock_1 = 3 + cycle main + endif + enddo + spag_nextblock_1 = 2 + case (2) + kt = i1 + i1 = i2 + i2 = kt + kt = l1 + l1 = l2 + l2 = kt + spag_nextblock_1 = 3 + case (3) + + ! determine interpolate in scaled l-value + + fll1 = map(i1+2) + fll2 = map(i2+2) + dfl = (fnl-fll1)/(fll2-fll1) + flog1 = map(i1+3) + flog2 = map(i2+3) + fkb1 = 0.0_wp + fkb2 = 0.0_wp + if ( l1>=4 ) then + + ! b/b0 loop + + do j2 = 4 , l2 + fincr2 = map(i2+j2) + if ( fkb2+fincr2>fnb ) goto 10 + fkb2 = fkb2 + fincr2 + flog2 = flog2 - fistep + enddo + itime = itime + 1 + if ( itime==1 ) then + spag_nextblock_1 = 2 + cycle main + endif + trara2 = 0.0_wp + return + 10 if ( itime/=1 ) then + if ( j2==4 ) then + spag_nextblock_1 = 4 + cycle main + endif + sl2 = flog2/fkb2 + do j1 = 4 , l1 + fincr1 = map(i1+j1) + fkb1 = fkb1 + fincr1 + flog1 = flog1 - fistep + fkbj1 = ((flog1/fistep)*fincr1+fkb1)/((fincr1/fistep)*sl2+1.0_wp) + if ( fkbj1<=fkb1 ) goto 15 + enddo + if ( fkbj1<=fkb2 ) then + trara2 = 0.0_wp + return + endif + 15 if ( fkbj1<=fkb2 ) then + fkbm = fkbj1 + (fkb2-fkbj1)*dfl + flogm = fkbm*sl2 + flog2 = flog2 - fistep + fkb2 = fkb2 + fincr2 + sl1 = flog1/fkb1 + sl2 = flog2/fkb2 + spag_nextblock_1 = 5 + cycle main + else + fkb1 = 0.0_wp + endif + endif + fkb2 = 0.0_wp + endif + j2 = 4 + fincr2 = map(i2+j2) + flog2 = map(i2+3) + flog1 = map(i1+3) + spag_nextblock_1 = 4 + case (4) + flogm = flog1 + (flog2-flog1)*dfl + fkbm = 0.0_wp + fkb2 = fkb2 + fincr2 + flog2 = flog2 - fistep + sl2 = flog2/fkb2 + if ( l1<4 ) then + fincr1 = 0.0_wp + sl1 = -900000.0_wp + spag_nextblock_1 = 6 + cycle main + else + j1 = 4 + fincr1 = map(i1+j1) + fkb1 = fkb1 + fincr1 + flog1 = flog1 - fistep + sl1 = flog1/fkb1 + endif + spag_nextblock_1 = 5 + case (5) + do while ( sl1>=sl2 ) + fkbj2 = ((flog2/fistep)*fincr2+fkb2)/((fincr2/fistep)*sl1+1.0_wp) + fkb = fkb1 + (fkbj2-fkb1)*dfl + flog = fkb*sl1 + if ( fkb>=fnb ) then + spag_nextblock_1 = 7 + cycle main + endif + fkbm = fkb + flogm = flog + if ( j1>=l1 ) then + trara2 = 0.0_wp + return + else + j1 = j1 + 1 + fincr1 = map(i1+j1) + flog1 = flog1 - fistep + fkb1 = fkb1 + fincr1 + sl1 = flog1/fkb1 + endif + enddo + spag_nextblock_1 = 6 + case (6) + fkbj1 = ((flog1/fistep)*fincr1+fkb1)/((fincr1/fistep)*sl2+1.0_wp) + fkb = fkbj1 + (fkb2-fkbj1)*dfl + flog = fkb*sl2 + if ( fkb=l2 ) then + trara2 = 0.0_wp + return + else + j2 = j2 + 1 + fincr2 = map(i2+j2) + flog2 = flog2 - fistep + fkb2 = fkb2 + fincr2 + sl2 = flog2/fkb2 + spag_nextblock_1 = 5 + cycle main + endif + endif + spag_nextblock_1 = 7 + case (7) + if ( fkb'); + var t_2 = html.toLowerCase().indexOf('', t_1 + 7); + if (t_1 != -1 && t_2 != -1) + { + var tit = html.slice(t_1 + 7, t_2); + } + else + { + var tit = 'No title'; + } + + tipuesearch_in.pages.push({ + "title": tit, + "text": desc, + "tags": cont, + "loc": tipuesearch_pages[i] + }); + } + ); + } + } + + if (set.mode == 'json') + { + $.getJSON(set.contentLocation, + function(json) + { + tipuesearch_in = $.extend({}, json); + } + ); + } + + if (set.mode == 'static') + { + tipuesearch_in = $.extend({}, tipuesearch); + } + + var tipue_search_w = ''; + if (set.newWindow) + { + tipue_search_w = ' target="_blank"'; + } + + function getURLP(name) + { + return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20')) || null; + } + if (getURLP('q')) + { + $('#tipue_search_input').val(getURLP('q')); + getTipueSearch(0, true); + } + + $(this).keyup(function(event) + { + if(event.keyCode == '13') + { + getTipueSearch(0, true); + } + }); + + function getTipueSearch(start, replace) + { + $('#tipue_search_content').hide(); + var out = ''; + var results = ''; + var show_replace = false; + var show_stop = false; + var standard = true; + var c = 0; + found = new Array(); + + var d = $('#tipue_search_input').val().toLowerCase(); + d = $.trim(d); + + if ((d.match("^\"") && d.match("\"$")) || (d.match("^'") && d.match("'$"))) + { + standard = false; + } + + if (standard) + { + var d_w = d.split(' '); + d = ''; + for (var i = 0; i < d_w.length; i++) + { + var a_w = true; + for (var f = 0; f < tipuesearch_stop_words.length; f++) + { + if (d_w[i] == tipuesearch_stop_words[f]) + { + a_w = false; + show_stop = true; + } + } + if (a_w) + { + d = d + ' ' + d_w[i]; + } + } + d = $.trim(d); + d_w = d.split(' '); + } + else + { + d = d.substring(1, d.length - 1); + } + + if (d.length >= set.minimumLength) + { + if (standard) + { + if (replace) + { + var d_r = d; + for (var i = 0; i < d_w.length; i++) + { + for (var f = 0; f < tipuesearch_replace.words.length; f++) + { + if (d_w[i] == tipuesearch_replace.words[f].word) + { + d = d.replace(d_w[i], tipuesearch_replace.words[f].replace_with); + show_replace = true; + } + } + } + d_w = d.split(' '); + } + + var d_t = d; + for (var i = 0; i < d_w.length; i++) + { + for (var f = 0; f < tipuesearch_stem.words.length; f++) + { + if (d_w[i] == tipuesearch_stem.words[f].word) + { + d_t = d_t + ' ' + tipuesearch_stem.words[f].stem; + } + } + } + d_w = d_t.split(' '); + + for (var i = 0; i < tipuesearch_in.pages.length; i++) + { + var score = 1000000000; + var s_t = tipuesearch_in.pages[i].text; + for (var f = 0; f < d_w.length; f++) + { + var pat = new RegExp(d_w[f], 'i'); + if (tipuesearch_in.pages[i].title.search(pat) != -1) + { + score -= (200000 - i); + } + if (tipuesearch_in.pages[i].text.search(pat) != -1) + { + score -= (150000 - i); + } + + if (set.highlightTerms) + { + if (set.highlightEveryTerm) + { + var patr = new RegExp('(' + d_w[f] + ')', 'gi'); + } + else + { + var patr = new RegExp('(' + d_w[f] + ')', 'i'); + } + s_t = s_t.replace(patr, "$1"); + } + if (tipuesearch_in.pages[i].tags.search(pat) != -1) + { + score -= (100000 - i); + } + + if (d_w[f].match("^-")) + { + pat = new RegExp(d_w[f].substring(1), 'i'); + if (tipuesearch_in.pages[i].title.search(pat) != -1 || tipuesearch_in.pages[i].text.search(pat) != -1 || tipuesearch_in.pages[i].tags.search(pat) != -1) + { + score = 1000000000; + } + } + } + + if (score < 1000000000) + { + found[c++] = score + '^' + tipuesearch_in.pages[i].title + '^' + s_t + '^' + tipuesearch_in.pages[i].loc; + } + } + } + else + { + for (var i = 0; i < tipuesearch_in.pages.length; i++) + { + var score = 1000000000; + var s_t = tipuesearch_in.pages[i].text; + var pat = new RegExp(d, 'i'); + if (tipuesearch_in.pages[i].title.search(pat) != -1) + { + score -= (200000 - i); + } + if (tipuesearch_in.pages[i].text.search(pat) != -1) + { + score -= (150000 - i); + } + + if (set.highlightTerms) + { + if (set.highlightEveryTerm) + { + var patr = new RegExp('(' + d + ')', 'gi'); + } + else + { + var patr = new RegExp('(' + d + ')', 'i'); + } + s_t = s_t.replace(patr, "$1"); + } + if (tipuesearch_in.pages[i].tags.search(pat) != -1) + { + score -= (100000 - i); + } + + if (score < 1000000000) + { + found[c++] = score + '^' + tipuesearch_in.pages[i].title + '^' + s_t + '^' + tipuesearch_in.pages[i].loc; + } + } + } + + if (c != 0) + { + if (show_replace == 1) + { + out += '
Showing results for ' + d + '
'; + out += '
Search instead for ' + d_r + '
'; + } + if (c == 1) + { + out += '
1 result
'; + } + else + { + c_c = c.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ","); + out += '
' + c_c + ' results
'; + } + + found.sort(); + var l_o = 0; + for (var i = 0; i < found.length; i++) + { + var fo = found[i].split('^'); + if (l_o >= start && l_o < set.show + start) + { + out += ''; + + if (set.showURL) + { + out += ''; + } + + var t = fo[2]; + var t_d = ''; + var t_w = t.split(' '); + if (t_w.length < set.descriptiveWords) + { + t_d = t; + } + else + { + for (var f = 0; f < set.descriptiveWords; f++) + { + t_d += t_w[f] + ' '; + } + } + t_d = $.trim(t_d); + if (t_d.charAt(t_d.length - 1) != '.') + { + t_d += ' ...'; + } + out += '
' + t_d + '
'; + } + l_o++; + } + + if (c > set.show) + { + var pages = Math.ceil(c / set.show); + var page = (start / set.show); + out += '