Commit 9916779a authored by Steffen Schotthöfer's avatar Steffen Schotthöfer
Browse files

some changes

parent 097e3881
Pipeline #143073 passed with stage
in 20 minutes and 33 seconds
...@@ -26,12 +26,13 @@ SOLVER = CSD_PN ...@@ -26,12 +26,13 @@ SOLVER = CSD_PN
% CFL number % CFL number
CFL_NUMBER = 0.7 CFL_NUMBER = 0.7
% Final time for simulation % Final time for simulation
TIME_FINAL = 0.3 TIME_FINAL = 0.1
% Maximal Moment degree % Maximal Moment degree
MAX_MOMENT_SOLVER = 13 MAX_MOMENT_SOLVER = 3
% Reconstruction order % Reconstruction order
RECONS_ORDER = 1 RECONS_ORDER = 1
% %
CLEAN_FLUX_MATRICES = YES
% %
% ---- Boundary Conditions ---- % ---- Boundary Conditions ----
% %
......
...@@ -38,25 +38,20 @@ CSDPNSolver::CSDPNSolver( Config* settings ) : PNSolver( settings ) { ...@@ -38,25 +38,20 @@ CSDPNSolver::CSDPNSolver( Config* settings ) : PNSolver( settings ) {
_dE = ComputeTimeStep( _settings->GetCFL() ); _dE = ComputeTimeStep( _settings->GetCFL() );
_nEnergies = std::ceil( ( maxE - minE ) / _dE ); _nEnergies = std::ceil( ( maxE - minE ) / _dE );
_energies = blaze::linspace( _nEnergies, maxE, minE ); _energies = blaze::linspace( _nEnergies, maxE, minE );
//_angle = _energies;
//
//_sigmaSE = { Matrix( _nEnergies, 0.0 ) };
//_sigmaTE = Vector( _nEnergies, 0.0 );
//
Vector pos_beam = Vector{ 0.5, 0.5 }; Vector pos_beam = Vector{ 0.5, 0.5 };
VectorVector IC( _nCells, Vector( _nSystem ) ); _sol = VectorVector( _nCells, Vector( _nSystem, 0.0 ) );
for( unsigned idx_cell = 0; idx_cell < _nCells; ++idx_cell ) { for( unsigned idx_cell = 0; idx_cell < _nCells; ++idx_cell ) {
double x = _cellMidPoints[idx_cell][0]; double x = _cellMidPoints[idx_cell][0];
double y = _cellMidPoints[idx_cell][1]; double y = _cellMidPoints[idx_cell][1];
const double stddev = .005; const double stddev = .005;
double f = normpdf( x, pos_beam[0], stddev ) * normpdf( y, pos_beam[1], stddev ); double f = normpdf( x, pos_beam[0], stddev ) * normpdf( y, pos_beam[1], stddev );
for( unsigned idx_sys = 0; idx_sys < _nSystem; idx_sys++ ) { for( unsigned idx_sys = 0; idx_sys < _nSystem; idx_sys++ ) {
IC[idx_cell][idx_sys] = f * StarMAPmoments[idx_sys]; // must be VectorVector _sol[idx_cell][idx_sys] = f * StarMAPmoments[idx_sys]; // must be VectorVector
//_sol[idx_cell][idx_sys] = 0;
} }
} }
_sol = IC; _solNew = _sol;
_solNew = IC;
_sigmaS = VectorVector( _nEnergies, Vector( _polyDegreeBasis ) ); _sigmaS = VectorVector( _nEnergies, Vector( _polyDegreeBasis ) );
for( unsigned idx_degree = 0; idx_degree < _polyDegreeBasis; ++idx_degree ) { for( unsigned idx_degree = 0; idx_degree < _polyDegreeBasis; ++idx_degree ) {
...@@ -144,8 +139,8 @@ void CSDPNSolver::FluxUpdate() { ...@@ -144,8 +139,8 @@ void CSDPNSolver::FluxUpdate() {
_AyMinus, _AyMinus,
_AzPlus, _AzPlus,
_AzMinus, _AzMinus,
_sol[idx_cell] / _density[idx_cell], _sol[idx_cell],
_sol[_neighbors[idx_cell][idx_neighbor]] / _density[_neighbors[idx_cell][idx_neighbor]], _sol[_neighbors[idx_cell][idx_neighbor]],
_normals[idx_cell][idx_neighbor] ); _normals[idx_cell][idx_neighbor] );
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment