-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from FluidNumerics/bugfix/issue-12
[WIP] Bugfix/issue 12
- Loading branch information
Showing
45 changed files
with
657 additions
and
236 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 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
Empty file.
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,31 @@ | ||
program gaussian_scalar_multivar | ||
|
||
use FEQParse | ||
|
||
implicit none | ||
type(EquationParser) :: f | ||
character(LEN=1),dimension(2) :: independentVars | ||
character(LEN=30) :: eqChar | ||
real :: x(2) | ||
|
||
! Specify the independent variables | ||
independentVars = (/'x', 'a'/) | ||
|
||
! Specify an equation string that we want to evaluate | ||
eqChar = 'f = \exp( -(x^2) ) - a' | ||
! eqChar = 'f = \exp( -(x^2) - a )' | ||
! eqChar = 'f = (x - a)^2 )' | ||
|
||
! Create the EquationParser object | ||
f = EquationParser(eqChar,independentVars) | ||
|
||
! Evaluate the equation | ||
x(1) = 1.0 | ||
x(2) = 1.0 | ||
print*, f % evaluate(x) | ||
print*, exp(-1.0) -1.0 | ||
|
||
! Clean up memory | ||
call f % Destruct() | ||
|
||
end program gaussian_scalar_multivar |
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.