Skip to content

Commit

Permalink
Merge pull request #180 from marcfehling/warnings
Browse files Browse the repository at this point in the history
Fix warnings.
  • Loading branch information
masterleinad authored Jun 24, 2024
2 parents ba95fcc + b69cb53 commit 07d5b89
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ class Initialcondition : public Function<2>
{}
// Returns the intitial values.
virtual double value(const Point<2> &p,
const unsigned int component =0) const;
const unsigned int component =0) const override;
};

/** A class to apply the boundary (Dirichlet) condition at the left edge.
Expand Down
10 changes: 5 additions & 5 deletions nonlinear-heat_transfer_with_AD_NOX/source/boundary_values.cc
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@
* @param p A point (2D)
* @return Value at the boundary
*/
double Boundary_values_left::value(const Point<2> &p, const unsigned int) const
double Boundary_values_left::value(const Point<2> & /*p*/, const unsigned int /*comp*/) const
{

nonlinear_heat nlheat;
double total_time = nlheat.tot_time;
return 100;

/**
* To linearly ramp the temperature at the left end to 100 over the
* entire time span, use the below line. See step-23 as to how the time
* variable can be used.
*/
// this->get_time() * 100.0/total_time;
// nonlinear_heat nlheat;
// double total_time = nlheat.tot_time;
// return this->get_time() * 100.0/total_time;
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @param comp component
* @return
*/
double Initialcondition::value(const Point<2> &p, const unsigned int comp) const
double Initialcondition::value(const Point<2> & /*p*/, const unsigned int /*comp*/) const
{
/**
* In the current case, we asume that the initial conditions are zero everywhere.
Expand Down
14 changes: 1 addition & 13 deletions parallel_in_time/src/Utilities.cc
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

int procID = 0;

#ifdef USE_MPI
// The shared variables

static std::string s_pout_filename ;
Expand All @@ -26,7 +27,6 @@ static std::ofstream s_pout ;
static bool s_pout_init = false ;
static bool s_pout_open = false ;

#ifdef USE_MPI
// in parallel, compute the filename give the basename
//[NOTE: dont call this before MPI is initialized.]
static void setFileName()
Expand All @@ -49,18 +49,6 @@ static void openFile()
// to try again later than to make believe it succeeded
s_pout_open = (bool)s_pout ;
}

#else
// in serial, filename is always cout
static void setFileName()
{
s_pout_filename = "cout" ;
}

// in serial, this does absolutely nothing
static void openFile()
{
}
#endif

std::ostream& pout()
Expand Down

0 comments on commit 07d5b89

Please sign in to comment.