-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* format data from bempp-cl to take up less space * start working on batched assembly * workin on batched assembly * Working on batched assembly * clippy * Use rayon in assembly * move memory assignment, evaluation of basis functions out of function * assemble the batches before moving on to next colour (!) * start planning out singular assembly * formatting * add example for timing assembly * cty * update parallel grid * batch the singular terms too * only make raw output once * run tests with --release on CI too
- Loading branch information
Showing
13 changed files
with
1,015 additions
and
1,051 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,3 +29,4 @@ approx = "0.5" | |
itertools = "0.10" | ||
mpi = { version = "0.6.*", optional = true } | ||
num = "0.4" | ||
rayon = "1.7" |
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,44 @@ | ||
use bempp_bem::assembly::{assemble_batched, BoundaryOperator, PDEType}; | ||
use bempp_bem::function_space::SerialFunctionSpace; | ||
use bempp_element::element::create_element; | ||
use bempp_grid::shapes::regular_sphere; | ||
use bempp_tools::arrays::Array2D; | ||
use bempp_traits::bem::DofMap; | ||
use bempp_traits::bem::FunctionSpace; | ||
use bempp_traits::cell::ReferenceCellType; | ||
use bempp_traits::element::{Continuity, ElementFamily}; | ||
use num::complex::Complex; | ||
use std::time::Instant; | ||
|
||
fn main() { | ||
for i in 0..5 { | ||
let now = Instant::now(); | ||
let grid = regular_sphere(i); | ||
let element = create_element( | ||
ElementFamily::Lagrange, | ||
ReferenceCellType::Triangle, | ||
0, | ||
Continuity::Discontinuous, | ||
); | ||
|
||
let space = SerialFunctionSpace::new(&grid, &element); | ||
let mut matrix = Array2D::<Complex<f64>>::new(( | ||
space.dofmap().global_size(), | ||
space.dofmap().global_size(), | ||
)); | ||
|
||
assemble_batched( | ||
&mut matrix, | ||
BoundaryOperator::SingleLayer, | ||
PDEType::Helmholtz(5.0), | ||
&space, | ||
&space, | ||
); | ||
|
||
println!( | ||
"{} {}", | ||
space.dofmap().global_size(), | ||
now.elapsed().as_millis() | ||
) | ||
} | ||
} |
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.