commit
stringlengths
40
40
subject
stringlengths
4
1.73k
repos
stringlengths
5
127k
old_file
stringlengths
2
751
new_file
stringlengths
2
751
new_contents
stringlengths
1
8.98k
old_contents
stringlengths
0
6.59k
license
stringclasses
13 values
lang
stringclasses
23 values
219759e14f16bd7a0531d07344bae05aa7b445e1
Update header.
owainkenwayucl/mandel,owainkenwayucl/mandel,owainkenwayucl/mandel,owainkenwayucl/mandel,owainkenwayucl/mandel,owainkenwayucl/mandel,owainkenwayucl/mandel,owainkenwayucl/mandel
fortran/imageout.f90
fortran/imageout.f90
module imageout ! Module for doing image output ! Owain Kenway contains ! Write a 2D array out as a PGM. ! d is the 2D array (x,y) of pixels. ! cols is the max colour (colours go 0 -> col) ! u is the unit to write to. subroutine writepgm(d, x, y, cols, u) implicit none integer, intent(in) :: x, y, cols, u ...
module imageout ! Module for doing image output ! Owain Kenway contains ! Write a 2D array out as a PGM. ! d is the 2D array (x,y) of pixels. ! cols is the max colour (colours go 0 -> col) ! u is the unit to write to. subroutine writepgm(d, x, y, cols, u) implicit none integer, intent(in) :: x, y, cols, u ...
mit
FORTRAN
69cfb29236f1e8f886b43adab6c518c703a40edc
Update reference with new var names
clementval/claw-compiler,clementval/claw-compiler
test/claw/kcache1/reference.f90
test/claw/kcache1/reference.f90
PROGRAM claw_test INTEGER :: istart = 0 INTEGER :: iend = 10 INTEGER :: jstart = 0 INTEGER :: jend = 20 CALL kcache ( istart , iend , jstart , jend ) END PROGRAM claw_test SUBROUTINE kcache ( istart , iend , jstart , jend ) INTEGER , INTENT(IN) :: istart INTEGER , INTENT(IN) :: iend INTEGER , INTENT(IN) :: js...
PROGRAM claw_test INTEGER :: istart = 0 INTEGER :: iend = 10 INTEGER :: jstart = 0 INTEGER :: jend = 20 CALL kcache ( istart , iend , jstart , jend ) END PROGRAM claw_test SUBROUTINE kcache ( istart , iend , jstart , jend ) INTEGER , INTENT(IN) :: istart INTEGER , INTENT(IN) :: iend INTEGER , INTENT(IN) :: js...
bsd-2-clause
FORTRAN
8c736057590745700556e154817a319d0459330f
interpolate syntax candidate.
nushio3/formura,nushio3/formura,nushio3/formura,nushio3/formura,nushio3/formura,nushio3/formura
example/test.f90
example/test.f90
parameter dimension = 2 parameter extent0 = 400 parameter extent1 = 300 parameter precision = double array A array Sxx, Syy, Szz, Sxy(1/2,1/2,0), Sxz(1/2,0,1/2), Syz(0,1/2,1/2) subroutine init A = exp(0-(((index0 - extent0)/2)**2 + ((index1 - extent1)/2)**2)/100) end subroutine init subroutine proceed B = 1/3*(...
parameter dimension = 2 parameter extent0 = 400 parameter extent1 = 300 parameter precision = double array A array Sxx, Syy, Szz, Sxy(1/2,1/2,0), Sxz(1/2,0,1/2), Syz(0,1/2,1/2) subroutine init A = exp(0-(((index0 - extent0)/2)**2 + ((index1 - extent1)/2)**2)/100) end subroutine init subroutine proceed B = 1/3*(...
mit
FORTRAN
d515663b36f6c67bb230140a53cde28b338bdfd2
Create SwapArray.f90
Hranz/Project-Daily,Hranz/Project-Daily,Hranz/Project-Daily
Fortran90/SwapArray.f90
Fortran90/SwapArray.f90
!Programmer: Kristoffer Larson !Date: February 18, 2014 ! !Description: Places values in array X, reverses the ! order of the values from X into Y. ! program SwapArray dimension X(5), Y(5) integer J do 10 I = 1, 5, 1 X(I) = I 10 continue J = 5 do 20 I = 1, 5, 1 Y(I) = X(J) J = J - ...
mit
FORTRAN
839ee505de71e99283e8ff2517436967b52165f3
Transform blank fortran strings to C strings as a single blank character rather than an empty string. Otherwise, the trimming of trailing blank characters proceeds as before.
FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot,FreeScienceCommunity/PLPlot
bindings/f77/strutil.f
bindings/f77/strutil.f
! $Id$ ! ! Copyright (C) 2004 Alan W. Irwin ! ! This file is part of PLplot. ! ! PLplot is free software; you can redistribute it and/or modify ! it under the terms of the GNU General Library Public License as published ! by the Free Software Foundation; either version 2 of the License, or ! (at your option) any later...
! $Id$ ! ! Copyright (C) 2004 Alan W. Irwin ! ! This file is part of PLplot. ! ! PLplot is free software; you can redistribute it and/or modify ! it under the terms of the GNU General Library Public License as published ! by the Free Software Foundation; either version 2 of the License, or ! (at your option) any later...
lgpl-2.1
FORTRAN
3a26d3221247f023ab52baaede3bc4a4f7dc255e
add case for different slopes
zingale/hydro1d
interface_states.f90
interface_states.f90
module interface_states_module use datatypes_module use grid_module use variables_module implicit none contains subroutine make_interface_states(U, U_l, U_r, dt) type(gridvar_t), intent(in ) :: U type(gridedgevar_t), intent( out) :: U_l, U_r real (kind=dp_t), intent(in ) :: dt ...
module interface_states_module use datatypes_module use grid_module use variables_module implicit none contains subroutine make_interface_states(U, U_l, U_r, dt) type(gridvar_t), intent(in ) :: U type(gridedgevar_t), intent( out) :: U_l, U_r real (kind=dp_t), intent(in ) :: dt ...
bsd-3-clause
FORTRAN
283c7ef2aed5bf45ef80b1ed3a292ebf89727c80
Improve WRITE() in hello_world_omp
samjcus/pragma_pragma_pragma,samjcus/pragma_pragma_pragma,samjcus/pragma_pragma_pragma
hello_world/src/hello_world_omp.f90
hello_world/src/hello_world_omp.f90
PROGRAM hello_f USE omp_lib IMPLICIT NONE INTEGER :: th_id INTEGER :: nthreads !$OMP PARALLEL private(th_id) th_id = omp_get_thread_num() WRITE (*,'(A,I0)') "Hello, World from thread ", th_id !$OMP BARRIER IF (th_id == 0) THEN nthreads = omp_get_num_threads() WRITE (*,'(A,I0,A)') "Th...
PROGRAM hello_f USE omp_lib IMPLICIT NONE INTEGER :: th_id INTEGER :: nthreads !$OMP PARALLEL private(th_id) th_id = omp_get_thread_num() WRITE (*,*) "Hello, World from thread", th_id !$OMP BARRIER IF (th_id == 0) THEN nthreads = omp_get_num_threads() WRITE (*,*) "There are", nthread...
mit
FORTRAN
45e8d93b1e4226b7647d30bf15c27e8437953247
add copyout
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction1/main.f90
test/claw/abstraction1/main.f90
! Test the CLAW abstraction model with one additional dimension. PROGRAM test_abstraction1 USE mo_column, ONLY: compute_column REAL, DIMENSION(20,60) :: q, t ! Fields as declared in the whole model INTEGER :: nproma, nz ! Size of array fields INTEGER :: p ! Loop index nproma = ...
! Test the CLAW abstraction model with one additional dimension. PROGRAM test_abstraction1 USE mo_column, ONLY: compute_column REAL, DIMENSION(20,60) :: q, t ! Fields as declared in the whole model INTEGER :: nproma, nz ! Size of array fields INTEGER :: p ! Loop index nproma = ...
bsd-2-clause
FORTRAN
df44384f6835e789a52012c2017739da3d35d5c7
Change default test run params to verify momentum splitting
kramer314/2d-vd-test
params.f90
params.f90
! Run parameters module params use progvars implicit none private public :: params_init public :: params_cleanup contains subroutine params_init() ! Units hbar = 1.0_dp ! Particle parameters m = 1.0_dp ! Gaussian parameters En = 10.0_dp phi = pi / 4.0_dp ! Equal momentum sp...
! Run parameters module params use progvars implicit none private public :: params_init public :: params_cleanup contains subroutine params_init() ! Units hbar = 1.0_dp ! Particle parameters m = 1.0_dp ! Gaussian parameters En = 10.0_dp phi = pi / 4.0_dp ! Equal momentum sp...
mit
FORTRAN
d3380f99c13a974cdf30800f755da53994ac84be
Correct the definition of vector cross.
jungerstein/plasmaPhyLib,jungerstein/plasmaPhyLib
dataType/vec3d.f90
dataType/vec3d.f90
! vim : tw=72 ts=2 sw=2 ! vec3d.f90 ! Implements for 3D vectors. ! Coded by jungerstein. ! Except for the licence, it is kind to contact me ! if the codes are involved in your original research. module vec3d type vec3 double precision :: x double precision :: y double precision :: z end type vec3 ...
! vim : tw=72 ts=2 sw=2 ! vec3d.f90 ! Implements for 3D vectors. ! Coded by jungerstein. ! Except for the licence, it is kind to contact me ! if the codes are involved in your original research. module vec3d type vec3 double precision :: x double precision :: y double precision :: z end type vec3 ...
apache-2.0
FORTRAN
af8c76bfad1ea10f4bc3011095608fcca300fd5d
Fix another typing-error.
jungerstein/plasmaPhyLib,jungerstein/plasmaPhyLib
utils/common/segment.f90
utils/common/segment.f90
! Segment.f90 ! Operations about segments. module segment contains elemental function whichSegment(x, xLower,xUpper, iLower,iUpper) result (i) implicit none double precision, intent (in) :: x, xLower, xUpper integer, intent (in) :: iLower, iUpper integer :: i i = iLower + floor(0.5 + (x-xLower) / (xUpper-...
! Segment.f90 ! Operations about segments. module segment contains elemental function whichSegment(x, xLower,xUpper, iLower,iUpper) result (i) implicit none double presicion, intent (in) :: x, xLower, xUpper integer, intent (in) :: iLower, iUpper integer :: i i = iLower + floor(0.5 + (x-xLower) / (xUpper-...
apache-2.0
FORTRAN
0bc132ce007f240878eee966efe50daf7f38393d
Move sread.f to selci_sread.f to avoid name conflicts in ar.
rangsimanketkaew/NWChem
src/selci/selci_sread.f
src/selci/selci_sread.f
subroutine selci_sread(itape,a,n) * * $Id: selci_sread.f,v 1.1 2003-04-08 00:23:28 windus Exp $ * real*8 a(n) parameter (lenbuf = 512) c if (n.le.0) return left = n nbuf = (n-1)/lenbuf + 1 do 10 ibuf = 1,nbuf m = min(lenbuf, left) call sselci_sread(itape, a(1 + ...
mit
FORTRAN
fe51af2d08d5c935c2d0cde84c01c368ae27eb3a
Remove unused variables
lscalfi/chemfiles,Luthaf/Chemharp,chemfiles/chemfiles,chemfiles/chemfiles,chemfiles/chemfiles,chemfiles/chemfiles,Luthaf/Chemharp,lscalfi/chemfiles,lscalfi/chemfiles,Luthaf/Chemharp,lscalfi/chemfiles
bindings/fortran/strings.f90
bindings/fortran/strings.f90
module strings use iso_c_binding implicit none contains !** Convert a C string to a Fortran string function c_to_f_str(c_string) result(f_string) implicit none type(c_ptr), target, intent(in) :: c_string character(len=1024), pointer :: tmp character(len=1024) ...
module strings use iso_c_binding implicit none contains !** Convert a C string to a Fortran string function c_to_f_str(c_string) result(f_string) implicit none type(c_ptr), target, intent(in) :: c_string character(len=1024), pointer :: tmp character(len=1024) ...
bsd-3-clause
FORTRAN
7a4b59d0c53bf23d518c8f98c2c33fec00107977
Update reference for extract2 test case
clementval/claw-compiler,clementval/claw-compiler
test/loops/extract2/reference.f90
test/loops/extract2/reference.f90
PROGRAM loop_extract INTEGER :: value1 ( 1 : 10 ) INTEGER :: value2 ( 1 : 10 ) INTEGER :: j INTEGER :: i INTEGER :: istart = 1 INTEGER :: iend = 10 DO j = 1 , 10 , 1 value1 ( j ) = j value2 ( j ) = j END DO DO i = istart , iend , 1 CALL clawloop_extracted0 ( value1 ( i ) , value2 ( i ) ) END DO CALL ...
PROGRAM loop_extract INTEGER :: value1 ( 1 : 10 ) INTEGER :: value2 ( 1 : 10 ) INTEGER :: j INTEGER :: i INTEGER :: istart = 1 INTEGER :: iend = 10 DO j = 1 , 10 , 1 value1 ( j ) = j value2 ( j ) = j END DO DO i = istart , iend , 1 CALL clawloop_extracted0 ( value1 ( i ) , value2 ( i ) ) END DO CALL t...
bsd-2-clause
FORTRAN
c2cd4e26a2ed2f5c0ff2f8595ce77ec6cc3c39e1
Add backslash
clementval/claw-compiler,clementval/claw-compiler
test/driver/backslash_preprocessor/original_code.f90
test/driver/backslash_preprocessor/original_code.f90
!> !! Dummy comment !! !! Some comment1 !! Comment that is super long to produce a long line if the fix fails \\\ !! Comment that is super long to produce a long line if the fix fails \\\ !! Comment that is super long to produce a long line if the fix fails \\\ !! Comment that is super long to produce a long line if t...
!> !! Dummy comment !! !! Some comment1 !! Comment that is super long to produce a long line if the fix fails \\\ !! Comment that is super long to produce a long line if the fix fails \\\ !! Comment that is super long to produce a long line if the fix fails \\\ !! Comment that is super long to produce a long line if t...
bsd-2-clause
FORTRAN
24ac0ea3149770b3fe910c81e5c9956847e38d8d
fix random_data
simomarsili/elss
src/random.f90
src/random.f90
! Copyright (C) 2015-2017, Simone Marsili ! All rights reserved. ! License: BSD 3 clause module random use kinds implicit none private public :: random_initialize public :: random_data interface random_data module procedure random_data_1d module procedure random_data_2d end interface random_d...
! Copyright (C) 2015-2017, Simone Marsili ! All rights reserved. ! License: BSD 3 clause module random use kinds implicit none private public :: random_initialize public :: random_data interface random_data module procedure random_data_1d module procedure random_data_2d end interface random_d...
bsd-3-clause
FORTRAN
654ee2d60aef5c5dd5219033b8380106566bfcdd
Update reference
clementval/claw-compiler,clementval/claw-compiler
test/openacc/primitive2/reference.f90
test/openacc/primitive2/reference.f90
PROGRAM test_primitive USE openacc INTEGER :: i INTEGER :: nd nd = acc_get_num_devices ( 4 ) !$acc parallel DO i = 1 , 10 , 1 PRINT * , i END DO !$acc end parallel !$claw omp do DO i = 1 , 10 , 1 PRINT * , i END DO !$claw omp end do END PROGRAM test_primitive
PROGRAM test_primitive USE openacc INTEGER :: i INTEGER :: nd nd = acc_get_num_devices ( 0 ) !$acc parallel DO i = 1 , 10 , 1 PRINT * , i END DO !$acc end parallel !$claw omp do DO i = 1 , 10 , 1 PRINT * , i END DO !$claw omp end do END PROGRAM test_primitive
bsd-2-clause
FORTRAN
0e6a8ca8edfa03cc67dff7a9c424222ea27add7b
call runtime diagnostics
zingale/hydro1d
main.f90
main.f90
program hydro1d use datatypes_module use grid_module use params_module use probparams_module, only: init_probparams use init_module use variables_module use output_module use runtime_diag_module use bcs_module use dt_module use interface_states_godunov_module use interface_states_plm_module u...
program hydro1d use datatypes_module use grid_module use params_module use probparams_module, only: init_probparams use init_module use variables_module use output_module use bcs_module use dt_module use interface_states_godunov_module use interface_states_plm_module use interface_states_ppm_mo...
bsd-3-clause
FORTRAN
790b3efa30c0a2e46a07eea9a5cbcb5b50dc8db7
Add some comments
cphyc/n-body,cphyc/n-body
main.f90
main.f90
program n_body use io_tools use constants use physics implicit none real(kind = xp), dimension(:), allocatable :: m ! Masses of the particles real(kind = xp), dimension(:, :), allocatable :: r ! Positions of the particles (3-dim vectors) real(kind = xp), dimension(:, :), allocatable :: v ! Spe...
program n_body use io_tools use constants use physics implicit none real(kind = xp), dimension(:), allocatable :: m real(kind = xp), dimension(:, :), allocatable :: r, v, a real(kind = xp) :: t = 0._xp, dt, Ec, Ep, E!, minEc, maxEc integer :: iter = 0 integer :: dump_freq = 10 integer...
mit
FORTRAN
8cfdf3919c6974c5b4919bd305da90febe974114
Add plaintext config file management
kramer314/fortran-lib
src/config.f90
src/config.f90
module config use globvars, only: dp use string, only: string_to_val implicit none private public :: config_init public :: config_cleanup public :: config_get_param interface config_get_param ! Get parameter module procedure config_get_int module procedure config_get_real_dp mo...
mit
FORTRAN
48ddc6685e538ac2b4d82fd9caf7e56fd834b581
Change to zero indexing for y.
ihuston/pyflation,ihuston/pyflation
rk4fortran/rk4fortran.f90
rk4fortran/rk4fortran.f90
subroutine rk4stepks(x, y, h, out_vector, n,m) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m real(8) :: x, h real(8) :: y(0:n-1,0:m-1) real(8) :: out_vector(n+m-1) !f2py real(8), intent(in)...
subroutine rk4stepks(x, y, h, out_vector, n,m) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m real(8) :: x, h real(8) :: y(n,m) real(8) :: out_vector(n+m-1) !f2py real(8), intent(in) :: x, h...
bsd-3-clause
FORTRAN
b9ce800e0ef0c71325d5b3d2b7b2ab102ceebb04
Implement pearson's model correctly.
nushio3/formura,nushio3/formura,nushio3/formura,nushio3/formura,nushio3/formura,nushio3/formura
attic/sayaendou/main.f90
attic/sayaendou/main.f90
program main implicit none double precision, dimension(50,50,50) :: u,v double precision, dimension(50,50,50) :: u_other,v_other integer t call init() do t = 1, 1024 call proceed(u,v, u_other, v_other) call proceed(u_other,v_other, u, v) end do print *, u(25,25,25), v(25,25,25) contains ...
program main implicit none double precision, dimension(50,50,50) :: u,v double precision, dimension(50,50,50) :: u_m,v_m call init() print *, u(25,25,25), v(25,25,25) contains subroutine init() integer x,y,z do z = 1, 50 do y = 1, 50 do x = 1, 50 u(x,y,z) = 1.0 ...
mit
FORTRAN
3a9e0072a90c005db031267acf30f31a8519fe14
Update reference
clementval/claw-compiler,clementval/claw-compiler
test/openacc/continuation/reference.f90
test/openacc/continuation/reference.f90
PROGRAM openacc_cont !$ACC parallel !$ACC end parallel !$acc data present ( pti,pdp,pclc,pwv,psw,pqlwc,pqiwc,pduco2,pduo3 ) & !$acc present ( paeq1,paeq2,paeq3,paeq4,paeq5,psmu0,palso ) present ( & !$acc palth,pskyview,pfcor ) present ( papre & !$acc ) present ( pflt,pfls,pflt_s,pf...
PROGRAM openacc_cont !$ACC parallel !$ACC end parallel !$acc data present ( pti,pdp,pclc,pwv,psw,pqlwc,pqiwc,pduco2,pduo3 ) & !$acc present ( paeq1,paeq2,paeq3,paeq4,paeq5,psmu0,palso ) present ( & !$acc palth,pskyview,pfcor ) present ( papre & !$acc ) present ( & !$acc pflt,pfls,p...
bsd-2-clause
FORTRAN
08ec44d2ba61db6f8f95ddeb0662e84a755fba41
Add query functions that can be easily called from fortran
ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw
src/mappings/map_query.f
src/mappings/map_query.f
logical function ispillowsphere() implicit none integer id, fclaw2d_map_is_pillowsphere integer*8 cont, get_context cont = get_context() id = fclaw2d_map_is_pillowsphere(cont) ispillowsphere = id .ne. 0 end logical function iscubedsphere() implicit none ...
bsd-2-clause
FORTRAN
b3d02c34a3860e69d62ed356cb4cebb7a93ef0e3
Add error stop on failure and cleanup EOF spacing
sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays
src/tests/regression/reported/issue-503-multidim-array-broadcast.f90
src/tests/regression/reported/issue-503-multidim-array-broadcast.f90
! caf -o bcast bcast.f90 ! cafrun -np 2 ./bcast ! mwe for issue github.com/sourceryinstitute/OpenCoarrays/issues/503 program main real, allocatable, dimension(:, :, :) :: arr1, arr2 integer :: i, me, nimg real :: red1, sum1, red2, sum2 allocate(arr1(10, 20, 8)) allocate(arr2(10, 20, 30)) me = th...
! caf -o bcast bcast.f90 ! cafrun -np 2 ./bcast ! mwe for issue github.com/sourceryinstitute/OpenCoarrays/issues/503 program main real, allocatable, dimension(:, :, :) :: arr1, arr2 integer :: i, me, nimg real :: red1, sum1, red2, sum2 allocate(arr1(10, 20, 8)) allocate(arr2(10, 20, 30)) me = th...
bsd-3-clause
FORTRAN
ebae946e4cc345f916c9f8a7dc84e90bb273202d
Add utility routines for interpolation
ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw
src/fortran_source2d/fclaw2d_interpolate_util.f
src/fortran_source2d/fclaw2d_interpolate_util.f
double precision function compute_slopes(sl,sr,mth) implicit none double precision sl,sr, s, sc, philim, slim integer mth c # ------------------------------------------------ c # Slope limiting done in amrclaw - see filpatch.f c dupc = valp10 - valc c dumc = valc - valm10...
bsd-2-clause
FORTRAN
4bdd6a145d1d8ba9c99429d1fd77ed561cc983cc
Fix simple_prof_f.f90, still using old API for geopm_tprof_increment().
geopm/geopm,cmcantalupo/geopm,geopm/geopm,sssylvester/geopm,sssylvester/geopm,geopm/geopm,sssylvester/geopm,cmcantalupo/geopm,geopm/geopm,cmcantalupo/geopm,sssylvester/geopm,cmcantalupo/geopm,cmcantalupo/geopm,geopm/geopm
examples/simple_prof_f.f90
examples/simple_prof_f.f90
! ! Copyright (c) 2015, 2016, Intel Corporation ! ! Redistribution and use in source and binary forms, with or without ! modification, are permitted provided that the following conditions ! are met: ! ! * Redistributions of source code must retain the above copyright ! notice, this list of conditions and the ...
! ! Copyright (c) 2015, 2016, Intel Corporation ! ! Redistribution and use in source and binary forms, with or without ! modification, are permitted provided that the following conditions ! are met: ! ! * Redistributions of source code must retain the above copyright ! notice, this list of conditions and the ...
bsd-3-clause
FORTRAN
c9f032ffffefffdf7a52fcec8f9006b658ce0e6d
fix data order (finally)
kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-p...
Fortran/ModernFortran/stock-prices/stock_volatility.f90
Fortran/ModernFortran/stock-prices/stock_volatility.f90
! vim: set ft=fortran sw=4 ts=4 : program stock_volatility use mod_arrays, only: reverse, average, std, moving_average, moving_std use mod_io, only: read_stock, write_stock implicit none character(len=4), allocatable :: symbols(:) character(len=:), allocatable :: time(:) real, allocatable ::...
! vim: set ft=fortran sw=4 ts=4 : program stock_volatility use mod_arrays, only: reverse, average, std, moving_average, moving_std use mod_io, only: read_stock, write_stock implicit none character(len=4), allocatable :: symbols(:) character(len=:), allocatable :: time(:) real, allocatable ::...
mit
FORTRAN
56e86e11a0272be75532b5bc79d27cdab6ea1b50
fix indent
kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-p...
Fortran/ModernFortran/stock-prices/mod_array.f95
Fortran/ModernFortran/stock-prices/mod_array.f95
! vim: set ft=fortran sw=4 ts=4 : module mod_arrays implicit none private public :: reverse contains pure function reverse(x) real, intent(in) :: x(:) real :: reverse(size(x)) reverse = x(size(x):1:-1) end function reverse end module
! vim: set ft=fortran sw=4 ts=4 : module mod_arrays implicit none private public :: reverse contains pure function reverse(x) real, intent(in) :: x(:) real :: reverse(size(x)) reverse = x(size(x):1:-1) end function reverse end module
mit
FORTRAN
d35e35dcb436cf251fb0a710288e27c5c19f7953
Add intermediate variable
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction2/mo_column.f90
test/claw/abstraction2/mo_column.f90
MODULE mo_column IMPLICIT NONE CONTAINS ! Compute only one column SUBROUTINE compute_column(nz, q, t) IMPLICIT NONE INTEGER, INTENT(IN) :: nz ! Size of the array field REAL, INTENT(INOUT) :: t(:) ! Field declared as one column only REAL, INTENT(INOUT) :: q(:) ! Field declared as one colum...
MODULE mo_column IMPLICIT NONE CONTAINS ! Compute only one column SUBROUTINE compute_column(nz, q, t) IMPLICIT NONE INTEGER, INTENT(IN) :: nz ! Size of the array field REAL, INTENT(INOUT) :: t(:) ! Field declared as one column only REAL, INTENT(INOUT) :: q(:) ! Field declared as one colum...
bsd-2-clause
FORTRAN
6c4b523963fdd8d385e503f9a13afb4459429802
Add missing testcase's source.
sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays
src/tests/unit/simple/random_init.f90
src/tests/unit/simple/random_init.f90
! random init test ! ! Copyright (c) 2021-2021, Sourcery, Inc. ! All rights reserved. ! ! Redistribution and use in source and binary forms, with or without ! modification, are permitted provided that the following conditions are met: ! * Redistributions of source code must retain the above copyright ! notice...
bsd-3-clause
FORTRAN
84a15ca9a37d2b40254e398dd8742f479a752919
Add derivs calling statement.
ihuston/pyflation,ihuston/pyflation
rk4fortran/rk4fortran.f90
rk4fortran/rk4fortran.f90
subroutine rk4stepks(x, y, h, yout, n, m, derivs) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m real(8) :: x, h real(8) :: y(0:n-1,0:m-1) real(8) :: yout(0:n-1,0:m-1) real(8), external :: ...
subroutine rk4stepks(x, y, h, yout, n, m, derivs) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m real(8) :: x, h real(8) :: y(0:n-1,0:m-1) real(8) :: yout(0:n-1,0:m-1) real(8), external :: ...
bsd-3-clause
FORTRAN
3fcf7ee89f632b7165bfba47394759a94bf8fcf8
Add reference for the test
clementval/claw-compiler,clementval/claw-compiler
test/utilities/remove1/reference.f90
test/utilities/remove1/reference.f90
PROGRAM remove1 CALL dummy ( ) END PROGRAM remove1 SUBROUTINE dummy ( ) INTEGER :: k INTEGER :: i INTEGER :: kend = 5 INTEGER :: iend = 10 DO k = 1 , kend , 1 DO i = 1 , iend , 1 END DO DO i = 1 , iend , 1 END DO END DO END SUBROUTINE dummy
bsd-2-clause
FORTRAN
012947ed10e7064128ca4ce0e4dba103d13d5fc4
Update reference
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction1/reference_gpu.f90
test/claw/abstraction1/reference_gpu.f90
MODULE mo_column CONTAINS SUBROUTINE compute_column ( nz , q , t , nproma ) INTEGER , INTENT(IN) :: nz REAL , INTENT(INOUT) :: t ( : , : ) REAL , INTENT(INOUT) :: q ( : , : ) INTEGER :: k REAL :: c INTEGER , INTENT(IN) :: nproma INTEGER :: proma !$acc parallel !$acc loop DO proma = 1 , nproma , 1 ...
MODULE mo_column CONTAINS SUBROUTINE compute_column ( nz , q , t , nproma ) INTEGER , INTENT(IN) :: nz REAL , INTENT(INOUT) :: t ( : , : ) REAL , INTENT(INOUT) :: q ( : , : ) INTEGER :: k REAL :: c INTEGER , INTENT(IN) :: nproma INTEGER :: proma DO proma = 1 , nproma , 1 c = 5.345 DO k = 1 , nz...
bsd-2-clause
FORTRAN
b7157e94d2bc679ef2e3f7ab94649f6e285b0ae9
Update reference to new test case
clementval/claw-compiler,clementval/claw-compiler
test/openacc/continuation/reference.f90
test/openacc/continuation/reference.f90
PROGRAM openacc_cont !$ACC parallel !$ACC end parallel !$acc data present ( pti,pdp,pclc,pwv,psw,pqlwc,pqiwc,pduco2,pduo3 ) & !$acc present ( paeq1,paeq2,paeq3,paeq4,paeq5,psmu0,palso ) present ( & !$acc palth,pskyview,pfcor ) present ( papre & !$acc ) present ( pflt,pfls,pflt_s,pfl...
PROGRAM openacc_cont !$ACC parallel !$ACC end parallel !$acc data present ( pti,pdp,pclc,pwv,psw,pqlwc,pqiwc,pduco2,pduo3 ) & !$acc present ( paeq1,paeq2,paeq3,paeq4,paeq5,psmu0,palso ) present ( & !$acc palth,pskyview,pfcor ) present ( papre & !$acc ) present ( pflt,pfls,pflt_s,pfl...
bsd-2-clause
FORTRAN
554506ef96205507f5afcbf5e93045be683af571
use integer format
cphyc/n-body,cphyc/n-body
io_tools.f90
io_tools.f90
module io_tools use constants implicit none private public :: read_npoints, read_mpos, write_dump contains subroutine read_npoints (un) integer, intent(in) :: un read (un, *) npoints end subroutine read_npoints subroutine read_mpos(un, m, r) integer, intent(in) ...
module io_tools use constants implicit none private public :: read_npoints, read_mpos, write_dump contains subroutine read_npoints (un) integer, intent(in) :: un read (un, *) npoints end subroutine read_npoints subroutine read_mpos(un, m, r) integer, intent(in) ...
mit
FORTRAN
aa176b1f047556105480089ee2a5ef6f1be4d7ea
Add new twisted torus map
ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw,ForestClaw/forestclaw
src/mappings/torus/mapc2m_twisted_torus.f
src/mappings/torus/mapc2m_twisted_torus.f
subroutine mapc2m_torus(blockno,xc,yc,xp,yp,zp,alpha) implicit none integer blockno double precision xc,yc,xp,yp,zp double precision alpha, r double precision pi common /compi/ pi r = 1 + alpha*cos(2*pi*(yc + xc)) xp = r*cos(2*pi*xc) yp = r*sin(2*pi*xc) ...
bsd-2-clause
FORTRAN
798a2c854d5d68e3990e650e2804a62844536ea6
Fix test
clementval/claw-compiler,clementval/claw-compiler
test/openacc/primitive2/original_code.f90
test/openacc/primitive2/original_code.f90
PROGRAM test_primitive USE openacc INTEGER :: i INTEGER :: nd INTEGER :: acc_device_nvidia nd = acc_get_num_devices( acc_device_nvidia ) !$claw acc parallel DO i = 1, 10 PRINT*,i END DO !$claw acc end parallel !$claw omp do DO i = 1, 10 PRINT*,i END DO !$claw omp end do END PROGR...
PROGRAM test_primitive USE openacc INTEGER :: i INTEGER :: nd INTEGER :: acc_device_nvidia acc_device_nvidia = 0 ! Dummy just to test OMNI Compiler front-end nd = acc_get_num_devices( acc_device_nvidia ) !$claw acc parallel DO i = 1, 10 PRINT*,i END DO !$claw acc end parallel !$claw omp d...
bsd-2-clause
FORTRAN
2cf67f97bdd023ee152e6504dfacf57e6857a898
add mod_distance.f90
M2-AAIS/BAD
mod_distance.f90
mod_distance.f90
module mod_distance use mod_constants use mod_read_parameters implicit none private contains end module mod_distance
mit
FORTRAN
8ef3210e5a75985abc7e7dbbabe558b27eeb4ed1
Add assertion to async_com_alloc_2 for minimum img
sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays
src/tests/unit/init_register/async_comp_alloc_2.f90
src/tests/unit/init_register/async_comp_alloc_2.f90
program async_comp_alloc_2 !! Author: Izaak Beekman, Andre Vehreschild !! Category: Regression !! Regression test for issue [#399](https://github.com/sourceryinstitute/OpenCoarrays/issues/399) implicit none type :: nonsymmetric real, dimension(:), allocatable :: arr end type type(nonsymmetric), codi...
program async_comp_alloc_2 !! Author: Izaak Beekman, Andre Vehreschild !! Category: Regression !! Regression test for issue [#399](https://github.com/sourceryinstitute/OpenCoarrays/issues/399) implicit none type :: nonsymmetric real, dimension(:), allocatable :: arr end type type(nonsymmetric), codi...
bsd-3-clause
FORTRAN
3988331a9049fbdc12733a3d318ee18eadd8041e
Use new lighting shader
io7m/jsom0
io7m-jsom0-core/src/main/resources/com/io7m/jsom0/shaders/jsom0-textured-chrome.f
io7m-jsom0-core/src/main/resources/com/io7m/jsom0/shaders/jsom0-textured-chrome.f
#version 110 varying vec3 vertex_position; varying vec3 vertex_normal; varying vec2 vertex_uv; uniform vec3 light_position; uniform vec3 ambient; uniform vec3 diffuse; uniform vec4 specular; uniform float shininess; uniform float alpha; uniform sampler2D texture; uniform float texture_alpha; void main (void) {...
#version 110 varying vec3 vertex_position; varying vec3 vertex_normal; uniform vec3 light_direction; uniform vec3 ambient; uniform vec3 diffuse; uniform vec4 specular; uniform float shininess; uniform float alpha; uniform sampler2D texture; uniform float texture_alpha; void main (void) { vec3 light_direction =...
isc
FORTRAN
3ccd8ee0b6505ae1e42167603a67c206c9efa77c
Update ref for ignore2
clementval/claw-compiler,clementval/claw-compiler
test/driver/ignore2/reference.f90
test/driver/ignore2/reference.f90
PROGRAM testignore !$claw remove PRINT*,'These lines' PRINT*,'are ignored' PRINT*,'by the CLAW compiler' PRINT*,'but kept in the final transformed code' PRINT*,'with the remove directives.' !$claw end remove PRINT*,'These lines' PRINT*,'are ignored' END PROGRAM testignore
PROGRAM testignore !$claw remove PRINT*,'These lines' PRINT*,'are ignored' PRINT*,'by the CLAW compiler' PRINT*,'but kept in the final transformed code' PRINT*,'with the remove directives.' !$claw end remove PRINT*,'These lines' PRINT*,'are ignored' END PROGRAM testignore
bsd-2-clause
FORTRAN
dbe01ea25e067a0f09bea879a96f2e86f29860d5
Add npoint, unit var
cphyc/n-body,cphyc/n-body
constants.f90
constants.f90
module constants implicit none private integer, parameter :: xp = selected_real_kind(8) real(kind = xp), parameter :: pi = 4.0_xp*atan(1.0_xp) real(kind = xp), parameter :: G = 1._xp integer, parameter :: npoints = 1000 integer :: un, una ! Unit numbers for ...
module constants implicit none private integer, parameter :: xp = selected_real_kind(8) real(kind = xp), parameter :: pi = 4.0_xp*atan(1.0_xp) real(kind = xp), parameter :: G = 1._xp real(kind = xp) :: epsilon2 integer :: npoints public :: xp, pi, G, epsilon2, npoin...
mit
FORTRAN
d232bd44d68b0a5a859d6f1d0dd9878dd4cfdb44
Update ref for ignore1
clementval/claw-compiler,clementval/claw-compiler
test/driver/ignore1/reference.f90
test/driver/ignore1/reference.f90
PROGRAM testignore !$claw remove PRINT*,'These lines' PRINT*,'are ignored' PRINT*,'by the CLAW compiler' PRINT*,'but kept in the final transformed code' PRINT*,'with the remove directives.' !$claw end remove END PROGRAM testignore
PROGRAM testignore !$claw remove PRINT*,'These lines' PRINT*,'are ignored' PRINT*,'by the CLAW compiler' PRINT*,'but kept in the final transformed code' PRINT*,'with the remove directives.' !$claw end remove END PROGRAM testignore
bsd-2-clause
FORTRAN
19c592bbeff8a4cf78c2fc059ba3552619b358e6
fix style in units module
simomarsili/elss
src/units.f90
src/units.f90
! Copyright (C) 2015-2017, Simone Marsili ! All rights reserved. ! License: BSD 3 clause module units use kinds implicit none private public :: units_initialize public :: units_open, units_open_unf integer(kint) :: nunits contains subroutine units_initialize implicit none nunits = 10 ...
! Copyright (C) 2015-2017, Simone Marsili ! All rights reserved. ! License: BSD 3 clause module units use kinds implicit none private public :: units_initialize public :: units_open, units_open_unf integer(kint) :: nunits contains subroutine units_initialize implicit none nunits = 10 ...
bsd-3-clause
FORTRAN
4c543f0083a83488045ddb81a7e69c3d8576d919
fix variable name conflict with module name
laurensdeprez/RMPCDMD,laurensdeprez/RMPCDMD,pdebuyl-lab/RMPCDMD,pdebuyl/RMPCDMD,pdebuyl-lab/RMPCDMD,pdebuyl/RMPCDMD
test/test_cell_system_0.f90
test/test_cell_system_0.f90
program try_all use cell_system use hilbert use tester implicit none type(cell_system_t) :: solvent_cells type(tester_t) :: test integer, parameter :: N = 1000000 double precision, target, allocatable :: pos1(:, :), pos2(:, :) double precision, pointer :: pos(:,:), pos_old(:,:), pos_pointer(:,:) ...
program try_all use cell_system use hilbert use tester implicit none type(cell_system_t) :: solvent_cells type(tester_t) :: tester integer, parameter :: N = 1000000 double precision, target, allocatable :: pos1(:, :), pos2(:, :) double precision, pointer :: pos(:,:), pos_old(:,:), pos_pointer(:,:) ...
bsd-3-clause
FORTRAN
851e2f8e9bbb3c91ea276241dce08cdfe5edab14
add cross relation between test files
Try2Code/codegraph,Try2Code/codegraph
test/test.f90
test/test.f90
MODULE A USE module_B ! IMPLICIT NONE PRIVATE PUBLIC :: construct, destruct PUBLIC :: transfer PUBLIC :: allocate_int_state INTERFACE xfer_var MODULE PROCEDURE xfer_var_r2 MODULE PROCEDURE xfer_var_r3 MODULE PROCEDURE xfer_var_r4 MODULE PROCEDURE xfer_var_i2 END INTERFACE INTERFACE xfer_idx MODULE PROCED...
MODULE A ! ! IMPLICIT NONE PRIVATE PUBLIC :: construct, destruct PUBLIC :: transfer PUBLIC :: allocate_int_state INTERFACE xfer_var MODULE PROCEDURE xfer_var_r2 MODULE PROCEDURE xfer_var_r3 MODULE PROCEDURE xfer_var_r4 MODULE PROCEDURE xfer_var_i2 END INTERFACE INTERFACE xfer_idx MODULE PROCEDURE xfer_idx...
bsd-3-clause
FORTRAN
9379e7b393622ca6b41f643de39868298f3e69e3
Update mc.f
MikeXL/bayes
src/mc.f
src/mc.f
C sketch C metropolis hasting monte carlo C hamiltonian monte carlo C not really gonna use it, consider there are C MCMCpack and STAN C rather for fun and jot down thoughts C C arXiv:1808.08490v2 C C23456789 subroutine metrop() end subroutine metrop subroutine ham() e...
C sketch C metropolis hasting monte carlo C hamiltonian monte carlo C not really gonna use it, consider there are C MCMCpack and STAN C rather for fun and jot down thoughts C23456789 subroutine metrop() end subroutine metrop subroutine ham() end subroutine ham
mit
FORTRAN
8a9c1401e98055506820b7c12f85a0d0a3980811
Fix the string conversion function
chemfiles/chemfiles,Luthaf/Chemharp,Luthaf/Chemharp,chemfiles/chemfiles,chemfiles/chemfiles,lscalfi/chemfiles,lscalfi/chemfiles,Luthaf/Chemharp,chemfiles/chemfiles,lscalfi/chemfiles,lscalfi/chemfiles
bindings/fortran/strings.f90
bindings/fortran/strings.f90
module strings use iso_c_binding implicit none contains !** Convert a C string to a Fortran string function c_to_f_str(c_string) result(f_string) implicit none type(c_ptr), target, intent(in) :: c_string character(len=1024), pointer :: tmp character(len=1024) ...
module strings use iso_c_binding implicit none contains !** Convert a C string to a Fortran string function c_to_f_str(c_string) result(f_string) implicit none type(c_ptr), target, intent(in) :: c_string character(len=1024), pointer :: tmp character(len=1024) ...
bsd-3-clause
FORTRAN
1970462ded51ac19a79cd08557468c61200d931d
fix syntax error
rboman/progs,rboman/progs,rboman/progs,rboman/progs,rboman/progs,rboman/progs,rboman/progs,rboman/progs,rboman/progs,rboman/progs
sandbox/fortranc/f_routines.f90
sandbox/fortranc/f_routines.f90
subroutine froutine() implicit none print *, 'in froutine()' end
subroutine froutine(int i, double d) implicit none print *, 'in froutine()' end
apache-2.0
FORTRAN
9a23f173250e312d9d383b25a487fbdaced4b618
Add string representation of boolean / logical values
kramer314/fortran-lib
src/string.f90
src/string.f90
module string use globvars, only: dp, dp_format, int_format implicit none private public str_num interface str_num ! Get string representation of numbers module procedure str_dp_real module procedure str_int end interface str_num contains function str_dp_real(num, fmt) result(val) ...
module string use globvars, only: dp, dp_format, int_format implicit none private public str_num interface str_num ! Get string representation of numbers module procedure str_dp_real module procedure str_int end interface str_num contains function str_dp_real(num, fmt) result(val) ...
mit
FORTRAN
ccaf06f589ee09fff250c764679df1a188572e01
Update reference for fusion6 test case
clementval/claw-compiler,clementval/claw-compiler
test/loops/fusion6/reference.f90
test/loops/fusion6/reference.f90
PROGRAM loop_fusion CALL clawloop ( ) END PROGRAM loop_fusion SUBROUTINE clawloop ( ) INTEGER :: i INTEGER :: j INTEGER :: k !$claw loop-fusion group(i) DO i = 1 , 5 , 1 DO j = 1 , 4 , 1 DO k = 1 , 2 , 1 PRINT * ,"First loop body:" , i , j END DO END DO END DO DO j = 1 , 4 , 1 !$claw loop-fus...
PROGRAM loop_fusion CALL clawloop ( ) END PROGRAM loop_fusion SUBROUTINE clawloop ( ) INTEGER :: i INTEGER :: j INTEGER :: k !$claw loop-fusion group(i) DO i = 1 , 5 , 1 DO j = 1 , 4 , 1 DO k = 1 , 2 , 1 PRINT * ,"First loop body:" , i , j END DO END DO END DO DO j = 1 , 4 , 1 !$claw loop-fusion...
bsd-2-clause
FORTRAN
f6bc9940935b52c44a31f5e79cbf68d8109acd75
Add h variable.
ihuston/pyflation,ihuston/pyflation
rk4fortran/rk4fortran.f90
rk4fortran/rk4fortran.f90
subroutine rk4stepks(x, y, h, out_vector, n,m,p, in_out_vec) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m,p real(8) :: x, h real(8) :: y(n,m) real(8) :: out_vector(n+m-1) real(8) :: in_ou...
subroutine rk4stepks(x, y, out_vector, n,m,p, in_out_vec) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m,p real(8) :: x real(8) :: y(n,m) real(8) :: out_vector(n+m-1) real(8) :: in_out_vec(...
bsd-3-clause
FORTRAN
fadb6d01944e95e8dfd3daaf7042ba17ec663820
Update missing reference
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction/abstraction27/reference_gpu.f90
test/claw/abstraction/abstraction27/reference_gpu.f90
MODULE mo_column CONTAINS SUBROUTINE compute_column ( nz , q , t , nproma ) INTEGER , INTENT(IN) :: nz REAL , INTENT(INOUT) :: t ( : , : ) REAL , INTENT(INOUT) :: q ( : , : ) INTEGER :: k REAL :: c INTEGER , INTENT(IN) :: nproma INTEGER :: proma !$acc data present(t,q) !$acc parallel private(k,proma,...
MODULE mo_column CONTAINS SUBROUTINE compute_column ( nz , q , t , nproma ) INTEGER , INTENT(IN) :: nz REAL , INTENT(INOUT) :: t ( : , : ) REAL , INTENT(INOUT) :: q ( : , : ) INTEGER :: k REAL :: c INTEGER , INTENT(IN) :: nproma INTEGER :: proma !$acc data present(t,q,nproma,nz) !$acc parallel privat...
bsd-2-clause
FORTRAN
938deb5023b54f8a5fb1cce95db1245cad072298
Use array notation without lower and upper bounds
clementval/claw-compiler,clementval/claw-compiler
test/loops/array1/original_code.f90
test/loops/array1/original_code.f90
! Simple program to test the to-loop directive PROGRAM VECTOR_LOOP CALL claw CALL claw_transformed END ! Before the transformation SUBROUTINE claw INTEGER :: j INTEGER, DIMENSION(0:10) :: vec1 DO j = 0, 10 vec1(j) = j END DO !$claw array-transform vec1(:) = vec1(:) + 10 PRINT*,vec1 END SUBROU...
! Simple program to test the to-loop directive PROGRAM VECTOR_LOOP CALL claw END ! Before the transformation SUBROUTINE claw INTEGER :: j INTEGER :: i = 10 INTEGER, DIMENSION(0:10) :: vec1 DO j = 0, i vec1(j) = j END DO !$claw array-transform vec1(0:i) = vec1(0:i) + 10 PRINT*,vec1 END SUBROUT...
bsd-2-clause
FORTRAN
1589e6fc1a4f831b5133e1a8fac4817789dc7f9e
print something in fortran example.
cournape/Bento,abadger/Bento,cournape/Bento,cournape/Bento,abadger/Bento,cournape/Bento,abadger/Bento,abadger/Bento
examples/fortran/src/bar.f
examples/fortran/src/bar.f
program foo write(*,*)"Hello from fortran" end
program foo end
bsd-3-clause
FORTRAN
3ee250e2a77dd3369b266af9056114bac16321a6
Update reference for array4 test case
clementval/claw-compiler,clementval/claw-compiler
test/openacc/array4/reference.f90
test/openacc/array4/reference.f90
PROGRAM array4_test CALL claw_test ( ) END PROGRAM array4_test SUBROUTINE claw_test ( ) INTEGER :: vec1 ( 0 : 10 ) INTEGER :: vec2 ( 0 : 10 ) INTEGER :: vec3 ( 0 : 10 ) INTEGER :: claw_induction_0 vec1 ( 0 : 10 ) = 0 vec2 ( 0 : 10 ) = 100 PRINT * , vec1 PRINT * , vec2 DO claw_induction_0 = 0 , 10 vec1...
PROGRAM array4_test CALL claw_test ( ) END PROGRAM array4_test SUBROUTINE claw_test ( ) INTEGER :: vec1 ( 0 : 10 ) INTEGER :: vec2 ( 0 : 10 ) INTEGER :: vec3 ( 0 : 10 ) INTEGER :: claw_induction_0 vec1 ( 0 : 10 ) = 0 vec2 ( 0 : 10 ) = 100 PRINT * , vec1 PRINT * , vec2 DO claw_induction_0 = 0 , 10 vec1 ( ...
bsd-2-clause
FORTRAN
fe2de16642b6da977aa5d6343c39e3af92bb2546
Correct definition of MurmurHash2 and pass the length argument correctly.
hande-qmc/hande,hande-qmc/hande,hande-qmc/hande,ruthfranklin/hande,hande-qmc/hande,hande-qmc/hande
lib/local/hash.f90
lib/local/hash.f90
module hashing ! Provide interfaces and wrappers to hashing procedures that are written in C++. ! Warning: only working with i0 as a 32-bit or 64-bit integer. implicit none interface ! Interfaces to hashing algorithms written in C. function MurmurHash2(key, N, seed) result(hash) bind(c, name='MurmurHash2') ...
module hashing ! Provide interfaces and wrappers to hashing procedures that are written in C++. ! Warning: only working with i0 as a 32-bit or 64-bit integer. use const implicit none interface ! Interfaces to hashing algorithms written in C. function MurmurHash2(key, N, seed) result(hash) bind(c, name='Mur...
lgpl-2.1
FORTRAN
417677e7ded54e6a8244ca7bc282e5b740a75e53
Update reference for fusion7 test case
clementval/claw-compiler,clementval/claw-compiler
test/loops/fusion7/reference.f90
test/loops/fusion7/reference.f90
PROGRAM loop_fusion CALL clawloop ( ) END PROGRAM loop_fusion SUBROUTINE clawloop ( ) INTEGER :: i !$claw loop-fusion target(cpu) DO i = 1 , 10 , 1 PRINT * ,"First loop body:" , i END DO !$claw loop-fusion target(cpu) DO i = 1 , 10 , 1 PRINT * ,"Second loop body:" , i END DO DO i = 1 , 10 , 1 PRINT *...
PROGRAM loop_fusion CALL clawloop ( ) END PROGRAM loop_fusion SUBROUTINE clawloop ( ) INTEGER :: i !$claw loop-fusion target(cpu) DO i = 1 , 10 , 1 PRINT * ,"First loop body:" , i END DO !$claw loop-fusion target(cpu) DO i = 1 , 10 , 1 PRINT * ,"Second loop body:" , i END DO DO i = 1 , 10 , 1 PRINT * ,"...
bsd-2-clause
FORTRAN
76d8ca87543a260cb409f0ab2d98e9c9bd3c359d
Remove unused import of "pi"
certik/dftatom,certik/dftatom,certik/dftatom,certik/dftatom
tests/well/well_nonrel.f90
tests/well/well_nonrel.f90
program well use special, only: spherical_bessel_jn_zeros use dftatom implicit none ! For potential well, we need to set Z=0: integer, parameter :: Z = 0 ! Mesh parameters: real(dp), parameter :: r_min = 1e-7_dp, r_max = 10, a = 2.7e6_dp integer, parameter :: NN = 5000 real(dp), parameter :: c = 137.035999037_dp, eps...
program well use constants, only: pi use special, only: spherical_bessel_jn_zeros use dftatom implicit none ! For potential well, we need to set Z=0: integer, parameter :: Z = 0 ! Mesh parameters: real(dp), parameter :: r_min = 1e-7_dp, r_max = 10, a = 2.7e6_dp integer, parameter :: NN = 5000 real(dp), parameter :: c...
mit
FORTRAN
18ef8d4a80f38deefd37c831c2b6fd75533b1ee1
Correct syntax
jungerstein/plasmaPhyLib,jungerstein/plasmaPhyLib
calculus/sphericalcalculus.f90
calculus/sphericalcalculus.f90
! vim : tw=72 ts=2 sw=2 ! sphericalcalculus.f90 ! Implements for 3D vector calculus in spherical coordinates. ! Coded by jungerstein. ! Except for the licence, it is kind to contact me ! if the codes are involved in your original research. module sphericalcalculus use sphericalvec3d implicit none type neighbo...
! vim : tw=72 ts=2 sw=2 ! sphericalcalculus.f90 ! Implements for 3D vector calculus in spherical coordinates. ! Coded by jungerstein. ! Except for the licence, it is kind to contact me ! if the codes are involved in your original research. module sphericalcalculus use sphericalvec3d implicit none type neighbo...
apache-2.0
FORTRAN
2b2803480467c2a2835b60ecc7f77772e69adc24
Create savedata.f90
openmichigan/PSNM,openmichigan/PSNM,openmichigan/PSNM,openmichigan/PSNM,openmichigan/PSNM
Brusselator/savedata.f90
Brusselator/savedata.f90
SUBROUTINE savedata(Nx,Ny,Nz,plotnum,name,field,u,v,decomp) !-------------------------------------------------------------------- ! ! ! PURPOSE ! ! This subroutine saves a three dimensional real array in binary ! format ! ! INPUT ! ! .. Scalars .. ! Nx = number of modes in x - power of 2 for FFT ! N...
bsd-2-clause
FORTRAN
a99285cc15f3653fc00f622db1b86d8288a33092
Update test case
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction/abstraction35/mo_column.f90
test/claw/abstraction/abstraction35/mo_column.f90
! ! This file is released under terms of BSD license ! See LICENSE file for more information ! MODULE mo_column IMPLICIT NONE CONTAINS ! Compute only one column SUBROUTINE compute_column(nz, q, t, z) IMPLICIT NONE INTEGER, INTENT(IN) :: nz ! Size of the array field REAL, INTENT(INOUT) :: t(:) ...
! ! This file is released under terms of BSD license ! See LICENSE file for more information ! MODULE mo_column IMPLICIT NONE CONTAINS ! Compute only one column SUBROUTINE compute_column(nz, q, t, z) IMPLICIT NONE INTEGER, INTENT(IN) :: nz ! Size of the array field REAL, INTENT(INOUT) :: t(:) ...
bsd-2-clause
FORTRAN
609607d412a42918d464a3c64916b9fc703d7dd3
Add Day 3 code jam: user-defined f2008 collectives
rouson/UCY-parallel-fortran
src/code-jams/fortran-2008-test-my-message.f90
src/code-jams/fortran-2008-test-my-message.f90
program main !! Unit test for my_message implicit none character(len=128) :: input[*] associate(me=>this_image()) !! Define a local alias for the image number broadcast_preface: block !! We can roll our own collective subroutines if we are using a compiler that supports !! Fortran 2008 co...
bsd-3-clause
FORTRAN
2c59e08a2deb831f542adcd74a3ba9b9abb93a45
fix comments in deb64.f
alzwded/school_ssi
deb64.f
deb64.f
SUBROUTINE DEB64(T64, NT64, T) IMPLICIT NONE C Input INTEGER NT64 INTEGER*1 T64(NT64) C Output INTEGER*1 T(NT64 / 2) C Externals INTEGER*1 FROMAB EXTERNAL FROMAB, RNGMAT C Common INTEGER*1 H INTEGER MAGIC1, MAGIC2 COMMON /KEY/ MAGIC1, MAGIC2, H...
SUBROUTINE DEB64(T64, NT64, T) IMPLICIT NONE C Input INTEGER NT64 INTEGER*1 T64(NT64) C Output INTEGER*1 T(NT64 / 2) C Externals INTEGER*1 FROMAB EXTERNAL FROMAB, RNGMAT C Common INTEGER*1 H INTEGER MAGIC1, MAGIC2 COMMON /KEY/ MAGIC1, MAGIC2, H...
bsd-2-clause
FORTRAN
f977b1dbd90f0900cbab9dd86c4b79cc2c22a144
Update comments
cphyc/n-body,cphyc/n-body
constants.f90
constants.f90
module constants use mpi implicit none private integer, parameter :: xp = selected_real_kind(8) integer, parameter :: MPI_REAL_XP = MPI_DOUBLE_PRECISION real(kind = xp), parameter :: pi = 4.0_xp*atan(1.0_xp) real(kind = xp), parameter :: G = 1._xp integer, parameter...
module constants use mpi implicit none private integer, parameter :: xp = selected_real_kind(8) integer, parameter :: MPI_REAL_XP = MPI_DOUBLE_PRECISION real(kind = xp), parameter :: pi = 4.0_xp*atan(1.0_xp) real(kind = xp), parameter :: G = 1._xp integer, parameter...
mit
FORTRAN
52dee6dc444ded8e8c1eca18d691462d08e78f3c
Fix var order in call to write_dump
cphyc/n-body,cphyc/n-body
main.f90
main.f90
program n_body use io_tools use constants use physics implicit none real(kind = xp), dimension(:), allocatable :: m real(kind = xp), dimension(:, :), allocatable :: r, v, a real(kind = xp) :: t = 0._xp, dt, Ec, Ep, E integer :: iter = 0 integer :: dump_freq = 1 integer :: maxiter = 10000 !...
program n_body use io_tools use constants use physics implicit none real(kind = xp), dimension(:), allocatable :: m real(kind = xp), dimension(:, :), allocatable :: r, v, a real(kind = xp) :: t = 0._xp, dt, Ec, Ep, E integer :: iter = 0 integer :: dump_freq = 1 integer :: maxiter = 10000 !...
mit
FORTRAN
0bb7ce121f99ce2a7741f9adf2e476c7294806bd
test particle sorting
pdebuyl/RMPCDMD,laurensdeprez/RMPCDMD,laurensdeprez/RMPCDMD,pdebuyl/RMPCDMD,pdebuyl-lab/RMPCDMD,pdebuyl-lab/RMPCDMD
test/test_cell_system_0.f90
test/test_cell_system_0.f90
program try_all use cell_system use hilbert use tester implicit none type(cell_system_t) :: solvent_cells type(tester_t) :: tester integer, parameter :: N = 1000000 double precision, target, allocatable :: pos1(:, :), pos2(:, :) double precision, pointer :: pos(:,:), pos_old(:,:), pos_pointer(:,:) ...
program try_all use cell_system use hilbert use tester implicit none type(cell_system_t) :: solvent_cells type(tester_t) :: tester integer, parameter :: N = 2000 double precision, target :: pos1(3, N), pos2(3, N) double precision, pointer :: pos(:,:), pos_old(:,:), pos_pointer(:,:) integer :: i, ...
bsd-3-clause
FORTRAN
a7638e458dcb774baaecc2605c7139988f18f52f
Complete v_HT for deHoffman-Teller frame.
jungerstein/plasmaPhyLib,jungerstein/plasmaPhyLib
analysis/discont/velocityHT.f90
analysis/discont/velocityHT.f90
! vim : tw=72 ts=2 sw=2 ! velocityHT.f90 ! Finds the velocity of deHoffman-Teller frame. ! Coded by jungerstein. ! Except for the licence, it is kind and proper to contact me ! if the codes are involved in your original research. ! ! EXTERNAL LIBRARY ! * mkl ! OTHERWISE ! 1. Can be slightly modified to use general l...
! vim : tw=72 ts=2 sw=2 ! velocityHT.f90 ! Finds the velocity of deHoffman-Teller frame. ! Coded by jungerstein. ! Except for the licence, it is kind and proper to contact me ! if the codes are involved in your original research. ! ! EXTERNAL LIBRARY ! * mkl ! OTHERWISE ! 1. Can be slightly modified to use general l...
apache-2.0
FORTRAN
f8b4f81a988885ae3ba509f00c50a49fba143311
Use okl instead of ofl until fix
jkozdon/occa,tcew/OCCA,tcew/OCCA,tcew/OCCA2,li12242/OCCA2,libocca/occa,tcew/OCCA,lcw/occa,jkozdon/occa,jkozdon/occa,libocca/occa,tcew/OCCA2,lcw/occa,tcew/OCCA2,tcew/OCCA2,jkozdon/occa,li12242/OCCA2,tcew/OCCA,lcw/occa,li12242/OCCA2,lcw/occa,tcew/OCCA,libocca/occa,li12242/OCCA2,tcew/OCCA2,li12242/OCCA2,li12242/OCCA2,libo...
examples/addVectors/main.f90
examples/addVectors/main.f90
program main use occa implicit none integer :: alloc_err integer(4) :: i, entries = 5 integer(4) :: platformID = 0, deviceID = 0, dims character(len=1024) :: Serial_Info = "mode = Serial" character(len=1024) :: OpenMP_Info = "mode = OpenMP , schedule = compact, chunk = 10" character(len=1024) :...
program main use occa implicit none integer :: alloc_err integer(4) :: i, entries = 5 integer(4) :: platformID = 0, deviceID = 0, dims character(len=1024) :: Serial_Info = "mode = Serial" character(len=1024) :: OpenMP_Info = "mode = OpenMP , schedule = compact, chunk = 10" character(len=1024) :...
mit
FORTRAN
d47e1591dc988cc0fe7ed46087455c32a3bded9d
Update waver.f95
chtheodoro/habfuzz
habfuzz/waver.f95
habfuzz/waver.f95
subroutine waver use fdeclarations !Defuzzification using the weighted average method implicit none do i=1,z hs(i)=max(high(i),good(i),moderate(i),poor(i),bad(i)) if (hs(i)>0) then if (bad(i)<=0) then xbad(i)=0 else if (bad(i)>0 .and. bad(i)<=1)then xbad(i)=0.5 else xbad(i)=0 end if if (poor(i)<=0) ...
subroutine waver use fdeclarations !Defuzzification using the weighted average method implicit none do i=1,z hs(i)=max(high(i),good(i),moderate(i),poor(i),bad(i)) if (hs(i)>0) then if (bad(i)<=0) then xbad(i)=0 else if (bad(i)>0 .and. bad(i)<=1)then xbad(i)=0.5 else xbad(i)=0 end if if (poor(i)<=0) ...
apache-2.0
FORTRAN
41a6d433f3af9c32a8da68ace13c813f1c96d195
Send y as argument for derivs.
ihuston/pyflation,ihuston/pyflation
rk4fortran/rk4fortran.f90
rk4fortran/rk4fortran.f90
subroutine rk4stepks(x, y, h, yout, n, m, derivs) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m real(8) :: x, h real(8) :: y(0:n-1,0:m-1) real(8) :: yout(0:n-1,0:m-1) real(8) :: derivs e...
subroutine rk4stepks(x, y, h, yout, n, m, derivs) ! Do one step of the classical 4th order Runge Kutta method, ! starting from y at x with time step h and derivatives given by derivs implicit none integer :: n,m real(8) :: x, h real(8) :: y(0:n-1,0:m-1) real(8) :: yout(0:n-1,0:m-1) real(8) :: derivs e...
bsd-3-clause
FORTRAN
085c9aaa11ef8460dc21a0b0eca52503f5c4efb5
Fix name
rekka/intro-fortran-2016,rekka/intro-fortran-2016
lec8/arrayops.f90
lec8/arrayops.f90
program arrayops implicit none integer :: i, j integer, parameter :: M = 5 real, dimension(M) :: x real :: s, t ! initialize the array do i=1, M x(i) = i end do ! sum s = 0. do i=1,M s = s + x(i) end do write(*,*)"sum = ",s ! average (mean) ...
program sort implicit none integer :: i, j integer, parameter :: M = 5 real, dimension(M) :: x real :: s, t ! initialize the array do i=1, M x(i) = i end do ! sum s = 0. do i=1,M s = s + x(i) end do write(*,*)"sum = ",s ! average (mean) writ...
mit
FORTRAN
3604031645c691f8590752b5aac84ab1d2bccdaf
Fix kmp/Rgas (missing exposant)
M2-AAIS/BAD
mod_constants.f90
mod_constants.f90
! Module that exposes the integrator that transforms the state_in to thet state_out module mod_constants implicit none integer, parameter, public :: x_precision = selected_real_kind(15) integer, parameter, public :: n_cell = 256 integer, parameter, public :: n_iterations = 1000 real(kind = x_precision), pa...
! Module that exposes the integrator that transforms the state_in to thet state_out module mod_constants implicit none integer, parameter, public :: x_precision = selected_real_kind(15) integer, parameter, public :: n_cell = 256 integer, parameter, public :: n_iterations = 1000 real(kind = x_precision), pa...
mit
FORTRAN
63f078f54411a58e62960fee26b4983895c6f2ee
Add cdf_error in status.f90
quimbp/cosmo,quimbp/cosmo
src/lib/status.f90
src/lib/status.f90
module module_status use netcdf integer :: STATUS_ERROR = 0 character(len=180) :: STATUS_TEXT = "" contains ! ... ! ==================================================================== ! ==================================================================== ! ... subroutine check_statu...
module module_status integer :: STATUS_ERROR = 0 character(len=180) :: STATUS_TEXT = "" contains ! ... ! ==================================================================== ! ==================================================================== ! ... subroutine check_status() if (STA...
mit
FORTRAN
a78d9777a1b317d5ac78d62749b3539736507e36
Fix two mistakes
cphyc/n-body,cphyc/n-body
constants.f90
constants.f90
module constants use mpi implicit none private integer, parameter :: xp = selected_real_kind(8) integer, parameter :: MPI_REAL_XP = MPI_DOUBLE_PRECISION real(xp), parameter :: pi = 4.0_xp*atan(1.0_xp) real(xp), parameter :: G = 1._xp integer, parameter :: npoints = 2**10 real(xp), pa...
module constants use mpi implicit none private integer, parameter :: xp = selected_real_kind(8) integer, parameter :: MPI_REAL_XP = MPI_DOUBLE_PRECISION real(xp), parameter :: pi = 4.0_xp*atan(1.0_xp) real(xp), parameter :: G = 1._xp integer, parameter :: npoints = 2**10 real(xp), pa...
mit
FORTRAN
96f172008a52e3d99c0e9ccac74a694e9f227645
Update reference for fusion9 test case
clementval/claw-compiler,clementval/claw-compiler
test/loops/fusion9/reference.f90
test/loops/fusion9/reference.f90
PROGRAM test INTEGER :: i LOGICAL :: ldo ldo = .TRUE. DO i = 1 , 10 , 1 PRINT * ,"Loop body #1" PRINT * ,"Loop body #2" END DO IF ( ldo ) THEN PRINT * ,"I did" END IF END PROGRAM test
PROGRAM test INTEGER :: i LOGICAL :: ldo ldo = .TRUE. DO i = 1 , 10 , 1 PRINT * ,"Loop body #1" PRINT * ,"Loop body #2" END DO IF ( ldo ) THEN PRINT * ,"I did" END IF END PROGRAM test
bsd-2-clause
FORTRAN
654eac7a1bfc3c299dcc5edd818e889f40544816
Update reference
clementval/claw-compiler,clementval/claw-compiler
test/openacc/primitive2/reference.f90
test/openacc/primitive2/reference.f90
PROGRAM test_primitive USE openacc INTEGER :: i INTEGER :: nd nd = acc_get_num_devices ( acc_device_nvidia ) !$acc parallel DO i = 1 , 10 , 1 PRINT * , i END DO !$acc end parallel !$claw omp do DO i = 1 , 10 , 1 PRINT * , i END DO !$claw omp end do END PROGRAM test_primitive
PROGRAM test_primitive USE openacc INTEGER :: i INTEGER :: nd nd = acc_get_num_devices ( 4 ) !$acc parallel DO i = 1 , 10 , 1 PRINT * , i END DO !$acc end parallel !$claw omp do DO i = 1 , 10 , 1 PRINT * , i END DO !$claw omp end do END PROGRAM test_primitive
bsd-2-clause
FORTRAN
1c7eefdb22d6f854624d3f14f9d409469ede3354
increment version number in the main module
milancurcic/datetime-fortran
src/lib/datetime.f90
src/lib/datetime.f90
! ! datetime-fortran - A Fortran library for date and time manipulation ! Copyright (c) 2013-2016, Wavebit Scientific LLC ! All rights reserved. ! ! Licensed under the BSD-3 clause license. See LICENSE for details. ! module datetime_module !======================================================================= ! ! Ve...
! ! datetime-fortran - A Fortran library for date and time manipulation ! Copyright (c) 2013-2016, Wavebit Scientific LLC ! All rights reserved. ! ! Licensed under the BSD-3 clause license. See LICENSE for details. ! module datetime_module !======================================================================= ! ! Ve...
bsd-3-clause
FORTRAN
22f6f5f1bfe7767260b282fe1ec8ab5bbd1d1a36
Add error tests in fortran
Luthaf/Chemharp,chemfiles/chemfiles,lscalfi/chemfiles,chemfiles/chemfiles,lscalfi/chemfiles,lscalfi/chemfiles,lscalfi/chemfiles,Luthaf/Chemharp,chemfiles/chemfiles,chemfiles/chemfiles,Luthaf/Chemharp
bindings/fortran/tests/chrp_errors.f90
bindings/fortran/tests/chrp_errors.f90
program cell_test use chemharp use testing implicit none integer(kind=kind(CHRP_LOG_LEVEL)) :: level integer :: status logical :: fexist character(len=1024) :: error error = chrp_strerror(int(0, 4)) call check((trim(error) == "Operation was sucessfull"), "chrp_strerror") error...
bsd-3-clause
FORTRAN
229604cf954d91d22ea5cfb6b9d41618596e5f8c
Add string utility test
NCAR/icar,gutmann/icar,NCAR/icar,NCAR/icar,gutmann/icar,gutmann/icar
tests/test_string.f90
tests/test_string.f90
program main use string, only : get_double, get_real, get_integer, str use iso_fortran_env, only : real32, real64, int32 implicit none ! Enumerate the test-result array indices: enum, bind(C) enumerator :: get_double_, get_real_, get_integer_, str_d_, str_r_, str_i_ end enum logical :: test_passed(g...
mit
FORTRAN
f9fc0cfc131596bb7e3e5624156f8d62e33907ae
add a comment
zingale/hydro1d
gravity.f90
gravity.f90
subroutine gravity(U, g) use datatypes_module use grid_module use variables_module use params_module, only : grav, gravity_monopole use constants_module implicit none type(gridedgevar_t), intent(in) :: U type(gridedgevar_t), intent(out) :: g type(grid_t) :: grid integer :: i real (kind=dp_t) ...
subroutine gravity(U, g) use datatypes_module use grid_module use variables_module use params_module, only : grav, gravity_monopole use constants_module implicit none type(gridedgevar_t), intent(in) :: U type(gridedgevar_t), intent(out) :: g type(grid_t) :: grid integer :: i real (kind=dp_t) ...
bsd-3-clause
FORTRAN
fbf30749cde140431c97243cd0ca641947e50b22
Fix a typo in eps comparison
certik/fortran-utils
tests/special/test_besseli.f90
tests/special/test_besseli.f90
program test_besseli use types, only: dp use constants, only: i_ use utils, only: assert use special, only: besseli implicit none ! check a few value against the ones computed with SciPy: integer :: i real(dp), parameter :: eps = 1d-14 real(dp), parameter :: ordersReal(7) = [0.000000000000000_dp, & ...
program test_besseli use types, only: dp use constants, only: i_ use utils, only: assert use special, only: besseli implicit none ! check a few value against the ones computed with SciPy: integer :: i real(dp), parameter :: eps = 1d-14 real(dp), parameter :: ordersReal(7) = [0.000000000000000_dp, & ...
mit
FORTRAN
54c6fa4dedddd34ef6578b2590c5c6ff02b162a7
Add cpu reference
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction1/reference_cpu.f90
test/claw/abstraction1/reference_cpu.f90
MODULE mo_column CONTAINS SUBROUTINE compute_column ( nz , q , t , nproma ) INTEGER , INTENT(IN) :: nz REAL , INTENT(INOUT) :: t ( : , : ) REAL , INTENT(INOUT) :: q ( : , : ) INTEGER :: k REAL :: c INTEGER , INTENT(IN) :: nproma INTEGER :: proma c = 5.345 DO k = 1 , nz , 1 DO proma = 1 , nproma ...
bsd-2-clause
FORTRAN
9184bc6b03618964839a603bf201d0227b6d0fb3
Change introspective cell list params to make it harder to break
eddiejessup/ciabatta
Lib/cell_list/intro_shared.f90
Lib/cell_list/intro_shared.f90
module cell_list_shared use utils implicit none integer, allocatable :: inters(:, :), intersi(:) integer, parameter :: m_max = 100 ! maximum number of possible interaction particles integer, parameter :: inters_max = 200 contains subroutine initialise_inters(n) integer, intent(in) :: n ...
module cell_list_shared use utils implicit none integer, allocatable :: inters(:, :), intersi(:) integer, parameter :: m_max = 100 integer, parameter :: inters_max = 10 contains subroutine initialise_inters(n) integer, intent(in) :: n if (allocated(inters)) deallocate(inters) if (al...
bsd-3-clause
FORTRAN
423eb8bcf291337b646a1c6c021c7abf20413f9a
fix typo
robertodr/autocmake,miroi/autocmake,miroi/autocmake,robertodr/autocmake,scisoft/autocmake,coderefinery/autocmake,scisoft/autocmake,coderefinery/autocmake
test/fc_mpi/src/example.f90
test/fc_mpi/src/example.f90
program example use mpi implicit none integer :: ierr, rank, num_ranks logical :: test_ok call MPI_INIT(ierr) call MPI_COMM_RANK(MPI_COMM_WORLD, rank, ierr) call MPI_COMM_SIZE(MPI_COMM_WORLD, num_ranks, ierr) call MPI_FINALIZE(ierr) test_ok = (num_ranks == 2 .and. (rank == 0 .or. rank ==...
program example use mpi implicit none integer :: ierr, rank, num_ranks logical :: test_ok call MPI_INIT(ierr) call MPI_COMM_RANK(MPI_COMM_WORLD, rank, ierr) call MPI_COMM_SIZE(MPI_COMM_WORLD, num_ranks, ierr) call MPI_FINALIZE(ierr) test_ok = (num_ranks == 2. and. (rank == 0 .or. rank ==...
bsd-3-clause
FORTRAN
e0de22b6b0145b25c4f15d10f6428ff491f76c32
Update ref with do stmt reordering
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction2/reference_gpu.f90
test/claw/abstraction2/reference_gpu.f90
MODULE mo_column CONTAINS SUBROUTINE compute_column ( nz , q , t , nx , ny ) INTEGER , INTENT(IN) :: nz REAL , INTENT(INOUT) :: t ( : , : , : ) REAL , INTENT(INOUT) :: q ( : , : , : ) INTEGER :: k REAL :: c REAL :: d INTEGER , INTENT(IN) :: nx INTEGER :: i INTEGER , INTENT(IN) :: ny INTEGER :: j ...
MODULE mo_column CONTAINS SUBROUTINE compute_column ( nz , q , t , nx , ny ) INTEGER , INTENT(IN) :: nz REAL , INTENT(INOUT) :: t ( : , : , : ) REAL , INTENT(INOUT) :: q ( : , : , : ) INTEGER :: k REAL :: c REAL :: d INTEGER , INTENT(IN) :: nx INTEGER :: i INTEGER , INTENT(IN) :: ny INTEGER :: j ...
bsd-2-clause
FORTRAN
16546f492a3be84189590bbe3ea379039f6bd847
fix block delimiter
kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-playground,kkirstein/proglang-p...
Fortran/Benchmark/perfect_number.f95
Fortran/Benchmark/perfect_number.f95
! perfect_number.f95 ! Calculate Perfect numbers ! ! vim: set ft=fortran sw=2 ts=2 : module perfect_number implicit none save contains pure logical function is_perfect (n) implicit none integer, intent( in ) :: n integer :: i, s, limit s = 0 limit = int(sqrt(real(n))) do i = 1, (n-1)...
! perfect_number.f95 ! Calculate Perfect numbers ! ! vim: set ft=fortran sw=2 ts=2 : module perfect_number implicit none save contains pure logical function is_perfect (n) implicit none integer, intent( in ) :: n integer :: i, s, limit s = 0 limit = int(sqrt(real(n))) do i = 1, (n-1)...
mit
FORTRAN
afb4180eaac2031eb39135a9d93b7fede0b7dc4d
Create sysexit.f
AeroDME/octo-spork,AeroDME/octo-spork,AeroDME/octo-spork
sysexit.f
sysexit.f
************************************************************************ * SYSEXIT * D. Everhart ************************************************************************ * The MIT License (MIT) * * Copyright (c) 2016 Daniel Everhart * * Permission is hereby granted, free of charge, to any person obtaining * a copy of...
mit
FORTRAN
405481ee2f6b929b1db2497407e401b8ab1feb8b
Add example source code
sstaehler/fortran_travis
hello_world.f90
hello_world.f90
program hello_world print *, 'Hello world!' end program
mit
FORTRAN
aaf4148cf8966416e276855af6ceae1cc9dbc1fe
add the Qadv in the output
M2-AAIS/BAD
mod_output.f90
mod_output.f90
! Module that provides a way to dump the state module mod_output use mod_constants use mod_read_parameters implicit none private public :: snapshot contains ! Save a snapshot of state (s) at iteration, time subroutine snapshot (s, iteration, time, unit) use mod_variables implicit none ...
! Module that provides a way to dump the state module mod_output use mod_constants use mod_read_parameters implicit none private public :: snapshot contains ! Save a snapshot of state (s) at iteration, time subroutine snapshot (s, iteration, time, unit) use mod_variables implicit none ...
mit
FORTRAN
db4221f2f77780a75df6b236e39734309a99aa2f
Fix typo in comment in team-number.f90
sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays,sourceryinstitute/opencoarrays
src/tests/unit/teams/team-number.f90
src/tests/unit/teams/team-number.f90
! BSD 3-Clause License ! ! Copyright (c) 2016, Sourcery Institute ! All rights reserved. ! ! Redistribution and use in source and binary forms, with or without ! modification, are permitted provided that the following conditions are met: ! ! * Redistributions of source code must retain the above copyright notice, this ...
! BSD 3-Clause License ! ! Copyright (c) 2016, Sourcery Institute ! All rights reserved. ! ! Redistribution and use in source and binary forms, with or without ! modification, are permitted provided that the following conditions are met: ! ! * Redistributions of source code must retain the above copyright notice, this ...
bsd-3-clause
FORTRAN
31d32016f72f2de69dd7b252ae0cb916c9df48be
fix self test
scienceopen/CVutils
DemoLineclip.f90
DemoLineclip.f90
program test use, intrinsic:: ieee_arithmetic use lineclip,only:wp, Ccohensutherland, cohensutherland use assert implicit none call test_lineclip() call test_loop() contains subroutine test_loop() integer, parameter :: Np=2 real(wp), dimension(Np) :: length, x1,x2,y1,y2 real...
program test use lineclip,only:wp, Ccohensutherland, cohensutherland use assert implicit none call test_lineclip() call test_loop() contains subroutine test_loop() integer, parameter :: Np=2 real(wp), dimension(Np) :: length, x1,x2,y1,y2 real(wp),parameter :: xmins(Np)=[1.,2.],y...
mit
FORTRAN
c89d5e239fd172ef1af966acff82123ca30baf6c
Update ref
clementval/claw-compiler,clementval/claw-compiler
test/claw/sca/sca43/reference_main_omp.f90
test/claw/sca/sca43/reference_main_omp.f90
PROGRAM test_abstraction1 USE mo_column , ONLY: compute_point INTEGER , PARAMETER :: nproma = 20 REAL :: q ( 1 : 20 ) REAL :: t ( 1 : 20 ) REAL :: w ( 1 : 20 ) INTEGER :: i INTEGER :: k DO i = 1 , 20 , 1 t ( i ) = 0.5 * i END DO !$omp target data map(alloc:t) !$omp target update to(t) q = compute_point ( t...
PROGRAM test_abstraction1 USE mo_column , ONLY: compute_point INTEGER , PARAMETER :: nproma = 20 REAL :: q ( 1 : 20 ) REAL :: t ( 1 : 20 ) REAL :: w ( 1 : 20 ) INTEGER :: i INTEGER :: k DO i = 1 , 20 , 1 t ( i ) = 0.5 * i END DO !$omp target data map(alloc:t) !$omp target update to(t) q = compute_point ( t...
bsd-2-clause
FORTRAN
e5fa962ce1989d8ae1872998253fb66253c2b89d
Move renorm.f to selci_renorm.f to avoid name conflicts in ar.
rangsimanketkaew/NWChem
src/selci/selci_renorm.f
src/selci/selci_renorm.f
subroutine selci_renorm(n,a,ia,anorm) * * $Id: selci_renorm.f,v 1.1 2003-04-08 00:04:29 windus Exp $ * implicit double precision (a-h,o-z) dimension a(*) c aa = 0.0d0 do 10 i = 1,1+(n-1)*ia,ia aa = aa + a(i)*a(i) 10 continue anorm = sqrt(aa) if (anorm.ne.0.0d0) then...
mit
FORTRAN
178a75796d234d8353cea13fcb2236e27dfd0854
Update reference for ignore1 test case
clementval/claw-compiler,clementval/claw-compiler
test/driver/ignore1/reference.f90
test/driver/ignore1/reference.f90
PROGRAM testignore !$claw remove PRINT*,'These lines' PRINT*,'are ignored' PRINT*,'by the CLAW compiler' PRINT*,'but kept in the final transformed code' PRINT*,'with the remove directives.' !$claw end remove END PROGRAM testignore
PROGRAM testignore !$claw remove PRINT*,'These lines' PRINT*,'are ignored' PRINT*,'by the CLAW compiler' PRINT*,'but kept in the final transformed code' PRINT*,'with the remove directives.' !$claw end remove END PROGRAM testignore
bsd-2-clause
FORTRAN
d55847c89705c6170a0b29668058f8fb56e8d850
Add lift calculation
goriccardo/bem2dlib
clnaca00xx.f90
clnaca00xx.f90
subroutine clBemNACA00xx(Nup, alpha, chord, t, cl) IMPLICIT NONE integer, intent(IN) :: Nup integer :: Nelem integer, parameter :: Nfreq = 1 integer :: NWake real(kind=8), intent(IN) :: chord, t real(kind=8), intent(OUT) :: cl ! Vector of nodes global coordinates (x,y) ...
bsd-3-clause
FORTRAN
5f54323c07812f42cd8768acf8bd82f6eee02c1d
Update cpu ref
clementval/claw-compiler,clementval/claw-compiler
test/claw/abstraction/abstraction32/reference_main_cpu.f90
test/claw/abstraction/abstraction32/reference_main_cpu.f90
PROGRAM test_abstraction4 USE mo_column , ONLY: compute REAL :: q ( 1 : 20 , 1 : 60 ) REAL :: t ( 1 : 20 , 1 : 60 ) REAL :: z ( 1 : 20 ) INTEGER :: nproma INTEGER :: nz INTEGER :: p nproma = 20 nz = 60 z = 10.0 DO p = 1 , nproma , 1 q ( p , 1 ) = 0.0 END DO CALL compute ( nz , q ( : , 1 : 60 ) , t ( : ,...
PROGRAM test_abstraction4 USE mo_column , ONLY: compute REAL :: q ( 1 : 20 , 1 : 60 ) REAL :: t ( 1 : 20 , 1 : 60 ) REAL :: z ( 1 : 20 ) INTEGER :: nproma INTEGER :: nz INTEGER :: p nproma = 20 nz = 60 z = 10.0 DO p = 1 , nproma , 1 q ( p , 1 ) = 0.0 END DO !$ACC data copyin(q,t) copyout(q,t) CALL compu...
bsd-2-clause
FORTRAN
75245dfef722c593863074d85378504e93acab37
remove print statement.
SixTrack/SixTrack,SixTrack/SixTrack,SixTrack/SixTrack,SixTrack/SixTrack,SixTrack/SixTrack,SixTrack/SixTrack
source/include/mul4v05.f90
source/include/mul4v05.f90
! start include/mul4v05.f90 yv1j = (bbiv(1,i) + bbiv(2,i)*xlvj) + aaiv(2,i)*zlvj yv2j = (aaiv(1,i) - bbiv(2,i)*zlvj) + aaiv(2,i)*xlvj if(curveff .and. abs(dki(ix,3)) > pieni) then !check for length and that flag is set if (abs(dki(ix,1)) > pieni) then ! Effect from the horizontal bend yv1j = yv1j - bbiv(2,i) * (s...
! start include/mul4v05.f90 print *, "aaaaaa1", aaiv(1,i), yv2j yv1j = (bbiv(1,i) + bbiv(2,i)*xlvj) + aaiv(2,i)*zlvj yv2j = (aaiv(1,i) - bbiv(2,i)*zlvj) + aaiv(2,i)*xlvj if(curveff .and. abs(dki(ix,3)) > pieni) then !check for length and that flag is set if (abs(dki(ix,1)) > pieni) then ! Effect from the horizontal b...
lgpl-2.1
FORTRAN
da9ba41e226010596e3ad0c21009e9b47af82000
Add BMI_FAILURE and BMI_SUCCESS parameters
csdms/bmi-f90
bmi/bmi_params.f90
bmi/bmi_params.f90
module bmi_params integer, parameter :: BMI_VAR_TYPE_UNKNOWN = 0 integer, parameter :: BMI_VAR_TYPE_CHAR = 1 integer, parameter :: BMI_VAR_TYPE_UNSIGNED_CHAR = 2 integer, parameter :: BMI_VAR_TYPE_INT = 3 integer, parameter :: BMI_VAR_TYPE_LONG = 4 integer, parameter :: BMI_VAR_TYPE_UNSIGNED_IN...
module bmi_params integer, parameter :: BMI_VAR_TYPE_UNKNOWN = 0 integer, parameter :: BMI_VAR_TYPE_CHAR = 1 integer, parameter :: BMI_VAR_TYPE_UNSIGNED_CHAR = 2 integer, parameter :: BMI_VAR_TYPE_INT = 3 integer, parameter :: BMI_VAR_TYPE_LONG = 4 integer, parameter :: BMI_VAR_TYPE_UNSIGNED_IN...
mit
FORTRAN