-
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
20c1391
commit ca5a647
Showing
1 changed file
with
32 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,34 @@ | ||
# forsus | ||
|
||
Pure chemical compounds database and general API. | ||
|
||
`forsus` provides a simple API to read `json` files containing pure component | ||
information and later on use it inside other projects. | ||
|
||
## The basics | ||
Using `forsus` in your Fortran project is relatively simple: | ||
|
||
All the readable parameters are kept on a `Substance` object, from which | ||
they can be later on extracted. | ||
|
||
It keeps a global variable `forsus_dir` with should be the path of your database | ||
file directory. [data/json](data/json) is the directory that the library uses by | ||
default. | ||
|
||
```fortran | ||
use forsus | ||
type(Substance) :: s | ||
! This will use the default path | ||
s = Substance("1-butanol") | ||
! This will use the defined path | ||
forsus_dir = "my/json/files" | ||
s = Substance("1-butanol") | ||
! It is also possible to use a custom path | ||
sus = Substance("1-butanol", path="the/json/is/here") | ||
! Show the critical temperature | ||
print *, sus%critical%critical_temperature%value | ||
``` |