... | @@ -56,7 +56,12 @@ link current_b current_a |
... | @@ -56,7 +56,12 @@ link current_b current_a |
|
const eF 0.5 MeV
|
|
const eF 0.5 MeV
|
|
const kF 1 1/fm
|
|
const kF 1 1/fm
|
|
```
|
|
```
|
|
According to our experience, three types of variables (`real`, `complex`, `vector`) are sufficient and cover more than 90% of applications. The variables can be stored either in double or float precision.
|
|
According to our experience, three types of variables (`real`, `complex`, `vector`) are sufficient and cover more than 90% of applications.
|
|
|
|
|
|
|
|
Binary files store data as row arrays called `datablocks`:
|
|
|
|

|
|
|
|
|
|
|
|
The variables can be stored either in double or float precision.
|
|
|
|
|
|
| type | float | double |
|
|
| type | float | double |
|
|
|-----------|----------|-----------|
|
|
|-----------|----------|-----------|
|
... | @@ -64,26 +69,32 @@ According to our experience, three types of variables (`real`, `complex`, `vecto |
... | @@ -64,26 +69,32 @@ According to our experience, three types of variables (`real`, `complex`, `vecto |
|
| complex | `complex8` | `complex`, `complex16` |
|
|
| complex | `complex8` | `complex`, `complex16` |
|
|
| vector | `vector4` | `vector`, `vector8` |
|
|
| vector | `vector4` | `vector`, `vector8` |
|
|
|
|
|
|
However, we have implemented single-precision (`float` in C notation) types denoted as `real4`, `complex8`, and `vector4`. To be consistent with the notation, one can use `real8`, `complex16` or `vector8` exchangeable for `real`, `complex`, `vector`.
|
|
The size of the `datablock` depends on the variable type and the data dimensionality, and is computed according formula (result in bytes B):
|
|
|
|
`blocksize=blocklength*sizeB`
|
|
|
|
|
|
|
|
The `blocklength` depends on the data dimensionality (`datadim`)
|
|
|
|
|datadim | blocklength|
|
|
|
|
| -------| -----------|
|
|
|
|
|1 | `nx`|
|
|
|
|
|2 | `nx*ny`|
|
|
|
|
|3 | `nx*ny*nz`|
|
|
|
|
|
|
|
|
The `sizeB` depends on the data type
|
|
|
|
| type | sizeB | comment |
|
|
|
|
| -----| ------| -------|
|
|
|
|
|`real`, `real8` | 8 | `sizeof(double)` |
|
|
|
|
| `real4` | 4 | `sizeof(float)`
|
|
|
|
| `complex`, `complex16` | 16 | =8\*2 double\*(re,im) |
|
|
|
|
| `complex8` | 8 | =4\*2 float\*(re,im) |
|
|
|
|
| `vector(d)`, `vector8(d)` |8\*d| d-vector dimensionality, d=1,2,3(default) |
|
|
|
|
| `vector4(d)` |4\*d| d-vector dimensionality, d=1,2,3(default) |
|
|
|
|
|
|
Binary files store data as row arrays called `datablocks`:
|
|
Note that for vector variables, we use the following storage pattern:
|
|

|
|

|
|
|
|
|
|
The size of `datablock` depends on the variable type and the data dimensionality.
|
|
|
|
* *real*/*real8*: `blocksize=blocklength*8 Bytes`
|
|
|
|
* *real4*: `blocksize=blocklength*4 Bytes`
|
|
|
|
* *complex*/*complex16*: `blocksize=blocklength*16 Bytes`
|
|
|
|
* *complex8*: `blocksize=blocklength*8 Bytes`
|
|
|
|
* *vector*/*vector8*: `blocksize=blocklength*3*8 Bytes`
|
|
|
|
* *vector4*: `blocksize=blocklength*3*4 Bytes`
|
|
|
|
|
|
|
|
where `blocklength` is
|
|
|
|
* for datadim=3: `blocklength=nx*ny*nz`
|
|
|
|
* for datadim=2: `blocklength=nx*ny`
|
|
|
|
* for datadim=1: `blocklength=nx`
|
|
|
|
|
|
|
|
Note that for vector variables, we use the following storage pattern:
|
|
However, we have implemented single-precision (`float` in C notation) types denoted as `real4`, `complex8`, and `vector4`. To be consistent with the notation, one can use `real8`, `complex16` or `vector8` exchangeable for `real`, `complex`, `vector`.
|
|

|
|
|
|
|
|
|
|
To compute time associated with a given `icycle`, we use the formula
|
|
To compute time associated with a given `icycle`, we use the formula
|
|
```
|
|
```
|
... | | ... | |