-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
cf5be6a
commit 53c3873
Showing
10 changed files
with
138 additions
and
216 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,5 +3,5 @@ module capi | |
use capi__version | ||
use capi__eis | ||
use capi__kinetics | ||
|
||
use capi__core | ||
end module |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
module capi__core | ||
use iso_c_binding, only: c_double, c_size_t | ||
use ecx__core, only: nm2eV, kTe | ||
implicit none | ||
|
||
contains | ||
|
||
pure subroutine capi_nm2eV(lambda, E, n)bind(C, name="ecx_core_nm2eV") | ||
!! Convert wavelength to energy | ||
|
||
integer(c_size_t), intent(in), value :: n | ||
!! Size of lambda and E. | ||
real(c_double), intent(in) :: lambda(n) | ||
!! Wavelength in nm. | ||
real(c_double), intent(out) :: E(n) | ||
!! Energy in eV. | ||
E = nm2eV(lambda) | ||
|
||
end subroutine | ||
|
||
pure subroutine capi_kTe(T, kTe_, n)bind(C, name="ecx_core_kTe") | ||
!! Compute the thermal voltage. | ||
|
||
integer(c_size_t), intent(in), value :: n | ||
!! Size of T and kTe. | ||
real(c_double), intent(in) :: T(n) | ||
!! Temperature in °C. | ||
real(c_double), intent(out) :: kTe_(n) | ||
!! Thermal voltage in V. | ||
|
||
kTe_ = kTe(T) | ||
|
||
end subroutine | ||
|
||
end module |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.