Tempus  Version of the Day
Time Integration
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Tempus_SolutionState_impl.hpp
Go to the documentation of this file.
1 // @HEADER
2 // ****************************************************************************
3 // Tempus: Copyright (2017) Sandia Corporation
4 //
5 // Distributed under BSD 3-clause license (See accompanying file Copyright.txt)
6 // ****************************************************************************
7 // @HEADER
8 
9 #ifndef Tempus_SolutionState_impl_hpp
10 #define Tempus_SolutionState_impl_hpp
11 
12 #include "Thyra_VectorStdOps.hpp"
13 
14 namespace Tempus {
15 
16 
17 template<class Scalar>
19  : x_ (Teuchos::null),
20  x_nc_ (Teuchos::null),
21  xdot_ (Teuchos::null),
22  xdot_nc_ (Teuchos::null),
23  xdotdot_ (Teuchos::null),
24  xdotdot_nc_ (Teuchos::null),
25  stepperState_ (Teuchos::null),
26  stepperState_nc_(Teuchos::null),
27  physicsState_ (Teuchos::null),
28  physicsState_nc_(Teuchos::null)
29 {
30  metaData_nc_ = Teuchos::rcp(new SolutionStateMetaData<Scalar>());
32  stepperState_nc_ = Teuchos::rcp(new StepperState<Scalar>("Default"));
34  physicsState_nc_ = Teuchos::rcp(new PhysicsState<Scalar> ());
36 }
37 
38 
39 #ifndef TEMPUS_HIDE_DEPRECATED_CODE
40 template<class Scalar>
42  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& x,
43  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& xdot,
44  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& xdotdot,
45  const Teuchos::RCP<StepperState<Scalar> >& stepperState,
46  const Teuchos::RCP<PhysicsState<Scalar> >& physicsState)
47  : x_ (x),
48  x_nc_ (x),
49  xdot_ (xdot),
50  xdot_nc_ (xdot),
51  xdotdot_ (xdotdot),
52  xdotdot_nc_ (xdotdot),
53  stepperState_ (stepperState),
54  stepperState_nc_(stepperState),
55  physicsState_ (physicsState),
56  physicsState_nc_(physicsState)
57 {
58  metaData_nc_ = Teuchos::rcp(new SolutionStateMetaData<Scalar>());
60  if (stepperState_nc_ == Teuchos::null) {
61  stepperState_nc_ = Teuchos::rcp(new StepperState<Scalar>("Default"));
63  }
64  if (physicsState_nc_ == Teuchos::null) {
65  physicsState_nc_ = Teuchos::rcp(new PhysicsState<Scalar> ());
67  }
68 }
69 
70 template<class Scalar>
72  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& x,
73  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& xdot,
74  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& xdotdot,
75  const Teuchos::RCP<const StepperState<Scalar> >& stepperState,
76  const Teuchos::RCP<const PhysicsState<Scalar> >& physicsState)
77  : x_ (x),
78  x_nc_ (Teuchos::null),
79  xdot_ (xdot),
80  xdot_nc_ (Teuchos::null),
81  xdotdot_ (xdotdot),
82  xdotdot_nc_ (Teuchos::null),
83  stepperState_ (stepperState),
84  stepperState_nc_(Teuchos::null),
85  physicsState_ (physicsState),
86  physicsState_nc_(Teuchos::null)
87 {
88  metaData_nc_ = Teuchos::rcp(new SolutionStateMetaData<Scalar>());
90 
91  using Teuchos::rcp_const_cast;
92  if (stepperState_ == Teuchos::null) {
93  stepperState_ = Teuchos::rcp(new StepperState<Scalar>("Default"));
94  }
95  if (physicsState_ == Teuchos::null) {
96  physicsState_ = Teuchos::rcp(new PhysicsState<Scalar> ());
97  }
98 }
99 #endif
100 
101 
102 template<class Scalar>
104  const Teuchos::RCP<SolutionStateMetaData<Scalar> > metaData,
105  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& x,
106  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& xdot,
107  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& xdotdot,
108  const Teuchos::RCP<StepperState<Scalar> >& stepperState,
109  const Teuchos::RCP<PhysicsState<Scalar> >& physicsState)
110  : metaData_ (metaData),
111  metaData_nc_ (metaData),
112  x_ (x),
113  x_nc_ (x),
114  xdot_ (xdot),
115  xdot_nc_ (xdot),
116  xdotdot_ (xdotdot),
117  xdotdot_nc_ (xdotdot),
118  stepperState_ (stepperState),
119  stepperState_nc_(stepperState),
120  physicsState_ (physicsState),
121  physicsState_nc_(physicsState)
122 {
123  if (stepperState_nc_ == Teuchos::null) {
124  stepperState_nc_ = Teuchos::rcp(new StepperState<Scalar>("Default"));
126  }
127  if (physicsState_nc_ == Teuchos::null) {
128  physicsState_nc_ = Teuchos::rcp(new PhysicsState<Scalar> ());
130  }
131 }
132 
133 template<class Scalar>
135  const Teuchos::RCP<const SolutionStateMetaData<Scalar> > metaData,
136  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& x,
137  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& xdot,
138  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& xdotdot,
139  const Teuchos::RCP<const StepperState<Scalar> >& stepperState,
140  const Teuchos::RCP<const PhysicsState<Scalar> >& physicsState)
141  : metaData_ (metaData),
142  metaData_nc_ (Teuchos::null),
143  x_ (x),
144  x_nc_ (Teuchos::null),
145  xdot_ (xdot),
146  xdot_nc_ (Teuchos::null),
147  xdotdot_ (xdotdot),
148  xdotdot_nc_ (Teuchos::null),
149  stepperState_ (stepperState),
150  stepperState_nc_(Teuchos::null),
151  physicsState_ (physicsState),
152  physicsState_nc_(Teuchos::null)
153 {
154  if (stepperState_ == Teuchos::null) {
155  stepperState_ = Teuchos::rcp(new StepperState<Scalar>("Default"));
156  }
157  if (physicsState_ == Teuchos::null) {
158  physicsState_ = Teuchos::rcp(new PhysicsState<Scalar> ());
159  }
160 }
161 
162 
163 #ifndef TEMPUS_HIDE_DEPRECATED_CODE
164 template<class Scalar>
166  const Teuchos::RCP<const Thyra::ModelEvaluator<Scalar> >& model,
167  const Teuchos::RCP<StepperState<Scalar> >& stepperState,
168  const Teuchos::RCP<PhysicsState<Scalar> >& physicsState)
169 {
170  typedef Thyra::ModelEvaluatorBase MEB;
171  using Teuchos::rcp_const_cast;
172 
173  metaData_nc_ = Teuchos::rcp(new SolutionStateMetaData<Scalar>());
174  metaData_nc_->setSolutionStatus(Status::PASSED);
175  metaData_ = metaData_nc_;
176 
177  MEB::InArgs<Scalar> inArgs = model->getNominalValues();
178 
179  TEUCHOS_TEST_FOR_EXCEPTION(inArgs.supports(MEB::IN_ARG_x) == false,
180  std::logic_error,
181  model->description() << "does not support an x solution vector!");
182 
183  // The solution vector, x, is required (usually).
184  x_nc_ = rcp_const_cast<Thyra::VectorBase<Scalar> > (inArgs.get_x());
185  x_ = x_nc_;
186 
187  // The solution derivative, xdot, can be optional provided, based on
188  // application needs. Here we will base it on "supports" IN_ARG_x_dot.
189  // Depending on the stepper used, a temporary xdot vector may be created
190  // within the Stepper, but not moved to the SolutionState.
191  if (inArgs.supports(MEB::IN_ARG_x_dot)) {
192  xdot_nc_ = rcp_const_cast<Thyra::VectorBase<Scalar> >(inArgs.get_x_dot());
193  xdot_ = xdot_nc_;
194  } else {
195  xdot_nc_ = Teuchos::null;
196  xdot_ = xdot_nc_;
197  }
198 
199  // Similar as xdot.
200  if (inArgs.supports(MEB::IN_ARG_x_dot_dot)) {
201  xdotdot_nc_ =
202  rcp_const_cast<Thyra::VectorBase<Scalar> > (inArgs.get_x_dot_dot());
203  xdotdot_ = xdotdot_nc_;
204  } else {
205  xdotdot_nc_ = Teuchos::null;
206  xdotdot_ = xdotdot_nc_;
207  }
208 
209  if (stepperState == Teuchos::null) {
210  stepperState_nc_ = Teuchos::rcp(new StepperState<Scalar> ()); // Use default
211  stepperState_ = stepperState_nc_;
212  } else {
213  stepperState_nc_ = stepperState;
214  stepperState_ = stepperState;
215  }
216 
217  if (physicsState == Teuchos::null) {
218  physicsState_nc_ = Teuchos::rcp(new PhysicsState<Scalar> ()); // Use default
219  physicsState_ = physicsState_nc_;
220  } else {
221  physicsState_nc_ = physicsState;
222  physicsState_ = physicsState;
223  }
224 }
225 #endif
226 
227 template<class Scalar>
229  :metaData_ (ss_.metaData_),
230  metaData_nc_ (ss_.metaData_nc_),
231  x_ (ss_.x_),
232  x_nc_ (ss_.x_nc_),
233  xdot_ (ss_.xdot_),
234  xdot_nc_ (ss_.xdot_nc_),
235  xdotdot_ (ss_.xdotdot_),
236  xdotdot_nc_ (ss_.xdotdot_nc_),
237  stepperState_ (ss_.stepperState_),
238  stepperState_nc_(ss_.stepperState_nc_),
239  physicsState_ (ss_.physicsState_),
240  physicsState_nc_(ss_.physicsState_nc_)
241 {}
242 
243 
244 template<class Scalar>
245 Teuchos::RCP<SolutionState<Scalar> > SolutionState<Scalar>::clone() const
246 {
247  using Teuchos::RCP;
248 
249  RCP<SolutionStateMetaData<Scalar> > metaData_out;
250  if (!Teuchos::is_null(metaData_)) metaData_out = metaData_->clone();
251 
252  RCP<Thyra::VectorBase<Scalar> > x_out;
253  if (!Teuchos::is_null(x_)) x_out = x_->clone_v();
254 
255  RCP<Thyra::VectorBase<Scalar> > xdot_out;
256  if (!Teuchos::is_null(xdot_)) xdot_out = xdot_->clone_v();
257 
258  RCP<Thyra::VectorBase<Scalar> > xdotdot_out;
259  if (!Teuchos::is_null(xdotdot_)) xdotdot_out = xdotdot_->clone_v();
260 
261  RCP<StepperState<Scalar> > sS_out;
262  if (!Teuchos::is_null(stepperState_)) sS_out=stepperState_->clone();
263 
264  RCP<PhysicsState<Scalar> > pS_out;
265  if (!Teuchos::is_null(physicsState_)) pS_out=physicsState_->clone();
266 
267  RCP<SolutionState<Scalar> > ss_out = Teuchos::rcp(new SolutionState<Scalar> (
268  metaData_out, x_out, xdot_out, xdotdot_out, sS_out, pS_out));
269 
270  return ss_out;
271 }
272 
273 
274 template<class Scalar>
276 copy(const Teuchos::RCP<const SolutionState<Scalar> >& ss)
277 {
278  metaData_nc_->copy(ss->metaData_);
279  this->copySolutionData(ss);
280 }
281 
282 
283 template<class Scalar>
285 copySolutionData(const Teuchos::RCP<const SolutionState<Scalar> >& ss)
286 {
287  if (ss->x_ == Teuchos::null)
288  x_nc_ = Teuchos::null;
289  else {
290  if (x_nc_ == Teuchos::null) {
291  x_nc_ = ss->x_->clone_v();
292  }
293  else
294  Thyra::V_V(x_nc_.ptr(), *(ss->x_));
295  }
296  x_ = x_nc_;
297 
298  if (ss->xdot_ == Teuchos::null)
299  xdot_nc_ = Teuchos::null;
300  else {
301  if (xdot_nc_ == Teuchos::null)
302  xdot_nc_ = ss->xdot_->clone_v();
303  else
304  Thyra::V_V(xdot_nc_.ptr(), *(ss->xdot_));
305  }
306  xdot_ = xdot_nc_;
307 
308  if (ss->xdotdot_ == Teuchos::null)
309  xdotdot_nc_ = Teuchos::null;
310  else {
311  if (xdotdot_nc_ == Teuchos::null)
312  xdotdot_nc_ = ss->xdotdot_->clone_v();
313  else
314  Thyra::V_V(xdotdot_nc_.ptr(), *(ss->xdotdot_));
315  }
316  xdotdot_ = xdotdot_nc_;
317 
318  if (ss->stepperState_ == Teuchos::null)
319  stepperState_nc_ = Teuchos::null;
320  else {
321  if (stepperState_nc_ == Teuchos::null)
322  stepperState_nc_ = ss->stepperState_->clone();
323  else
324  stepperState_nc_->copy(ss->stepperState_);
325  }
326  stepperState_ = stepperState_nc_;
327 
328  if (ss->physicsState_ == Teuchos::null)
329  physicsState_nc_ = Teuchos::null;
330  else {
331  if (physicsState_nc_ == Teuchos::null)
332  physicsState_nc_ = ss->physicsState_->clone();
333  else
334  physicsState_nc_->copy(ss->physicsState_);
335  }
336  physicsState_ = physicsState_nc_;
337 }
338 
339 template<class Scalar>
341 {
342  return (this->metaData_->getTime() < ss.metaData_->getTime());
343 }
344 
345 template<class Scalar>
347 {
348  return (this->metaData_->getTime() <= ss.metaData_->getTime());
349 }
350 
351 template<class Scalar>
352 bool SolutionState<Scalar>::operator< (const Scalar& t) const
353 {
354  return (this->metaData_->getTime() < t);
355 }
356 
357 template<class Scalar>
358 bool SolutionState<Scalar>::operator<= (const Scalar& t) const
359 {
360  return (this->metaData_->getTime() <= t);
361 }
362 
363 template<class Scalar>
365 {
366  return (this->metaData_->getTime() > ss.metaData_->getTime());
367 }
368 
369 template<class Scalar>
371 {
372  return (this->metaData_->getTime() >= ss.metaData_->getTime());
373 }
374 
375 template<class Scalar>
376 bool SolutionState<Scalar>::operator> (const Scalar& t) const
377 {
378  return (this->metaData_->getTime() > t);
379 }
380 
381 template<class Scalar>
382 bool SolutionState<Scalar>::operator>= (const Scalar& t) const
383 {
384  return (this->metaData_->getTime() >= t);
385 }
386 
387 template<class Scalar>
389 {
390  return (this->metaData_->getTime() == ss.metaData_->getTime());
391 }
392 
393 template<class Scalar>
394 bool SolutionState<Scalar>::operator== (const Scalar& t) const
395 {
396  return (this->metaData_->getTime() == t);
397 }
398 
399 template<class Scalar>
401 {
402  std::string name = "Tempus::SolutionState";
403  return (name);
404 }
405 
406 template<class Scalar>
408  Teuchos::FancyOStream &out,
409  const Teuchos::EVerbosityLevel verbLevel) const
410 {
411  if (verbLevel == Teuchos::VERB_EXTREME) {
412  out << description() << "::describe:" << std::endl
413  << "metaData = " << std::endl;
414  metaData_->describe(out,verbLevel);
415  out << "x = " << std::endl;
416  x_->describe(out,verbLevel);
417  if (xdot_ != Teuchos::null) {
418  out << "xdot_ = " << std::endl;
419  xdot_->describe(out,verbLevel);
420  }
421  if (xdotdot_ != Teuchos::null) {
422  out << "xdotdot = " << std::endl;
423  xdotdot_->describe(out,verbLevel);
424  }
425  if (stepperState_ != Teuchos::null) {
426  out << "stepperState = " << std::endl;
427  stepperState_->describe(out,verbLevel);
428  }
429  if (physicsState_ != Teuchos::null) {
430  out << "physicsState = " << std::endl;
431  physicsState_->describe(out,verbLevel);
432  }
433  }
434 }
435 
436 
437 template<class Scalar>
439  const Teuchos::RCP<const SolutionState<Scalar> >& ssIn)
440 {
441  if (!getComputeNorms()) return;
442 
443  auto x = this->getX();
444  this->setXNormL2(Thyra::norm(*x));
445 
446  if (ssIn != Teuchos::null) {
447  auto xIn = ssIn->getX();
448 
449  // dx = x - xIn
450  Teuchos::RCP<Thyra::VectorBase<Scalar> > dx = Thyra::createMember(x->space());
451  Thyra::V_VmV(dx.ptr(), *x, *xIn);
452  Scalar dxNorm = Thyra::norm(*dx);
453  Scalar xInNorm = Thyra::norm(*xIn);
454  this->setDxNormL2Abs(dxNorm);
455  // Compute change, e.g., ||x^n-x^(n-1)||/||x^(n-1)||
456  const Scalar eps = std::numeric_limits<Scalar>::epsilon();
457  const Scalar min = std::numeric_limits<Scalar>::min();
458  if ( xInNorm < min/eps ) { // numerically zero
459  this->setDxNormL2Rel(std::numeric_limits<Scalar>::infinity());
460  } else {
461  //this->setDxNormL2Rel(dxNorm/(xInNorm + eps));
462  this->setDxNormL2Rel(dxNorm/(xInNorm*(1.0 + 1.0e4*eps)));
463  }
464  }
465 }
466 
467 
468 // Nonmember constructors.
469 // ------------------------------------------------------------------------
470 
471 template<class Scalar>
472 Teuchos::RCP<SolutionState<Scalar> > createSolutionStateX(
473  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& x,
474  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& xdot,
475  const Teuchos::RCP<Thyra::VectorBase<Scalar> >& xdotdot)
476 {
477  Teuchos::RCP<SolutionStateMetaData<Scalar> >
478  metaData_nc = Teuchos::rcp(new SolutionStateMetaData<Scalar>());
479 
480  Teuchos::RCP<StepperState<Scalar> >
481  stepperState_nc = Teuchos::rcp(new StepperState<Scalar>("Default"));
482 
483  Teuchos::RCP<PhysicsState<Scalar> >
484  physicsState_nc = Teuchos::rcp(new PhysicsState<Scalar> ());
485 
486  Teuchos::RCP<SolutionState<Scalar> > ss = rcp(new SolutionState<Scalar> (
487  metaData_nc, x, xdot, xdotdot, stepperState_nc, physicsState_nc));
488 
489  return ss;
490 }
491 
492 template<class Scalar>
493 Teuchos::RCP<SolutionState<Scalar> > createSolutionStateX(
494  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& x,
495  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& xdot,
496  const Teuchos::RCP<const Thyra::VectorBase<Scalar> >& xdotdot)
497 {
498  Teuchos::RCP<const SolutionStateMetaData<Scalar> >
499  metaData = Teuchos::rcp(new SolutionStateMetaData<Scalar>());
500 
501  Teuchos::RCP<const StepperState<Scalar> >
502  stepperState = Teuchos::rcp(new StepperState<Scalar>("Default"));
503 
504  Teuchos::RCP<const PhysicsState<Scalar> >
505  physicsState = Teuchos::rcp(new PhysicsState<Scalar> ());
506 
507  Teuchos::RCP<SolutionState<Scalar> > ss = rcp(new SolutionState<Scalar> (
508  metaData, x, xdot, xdotdot, stepperState, physicsState));
509 
510  return ss;
511 }
512 
513 
514 template<class Scalar>
515 Teuchos::RCP<SolutionState<Scalar> > createSolutionStateME(
516  const Teuchos::RCP<const Thyra::ModelEvaluator<Scalar> >& model,
517  const Teuchos::RCP<StepperState<Scalar> >& stepperState,
518  const Teuchos::RCP<PhysicsState<Scalar> >& physicsState)
519 {
520  typedef Thyra::ModelEvaluatorBase MEB;
521  using Teuchos::rcp_const_cast;
522 
523  auto metaData_nc = Teuchos::rcp(new SolutionStateMetaData<Scalar>());
524  metaData_nc->setSolutionStatus(Status::PASSED);
525 
526  MEB::InArgs<Scalar> inArgs = model->getNominalValues();
527 
528  TEUCHOS_TEST_FOR_EXCEPTION(inArgs.supports(MEB::IN_ARG_x) == false,
529  std::logic_error,
530  model->description() << "does not support an x solution vector!");
531 
532  // The solution vector, x, is required (usually).
533  auto x_nc = rcp_const_cast<Thyra::VectorBase<Scalar> > (inArgs.get_x());
534 
535  // The solution derivative, xdot, can be optional provided, based on
536  // application needs. Here we will base it on "supports" IN_ARG_x_dot.
537  // Depending on the stepper used, a temporary xdot vector may be created
538  // within the Stepper, but not moved to the SolutionState.
539  Teuchos::RCP<Thyra::VectorBase<Scalar> > xdot_nc;
540  if (inArgs.supports(MEB::IN_ARG_x_dot)) {
541  xdot_nc = rcp_const_cast<Thyra::VectorBase<Scalar> >(inArgs.get_x_dot());
542  } else {
543  xdot_nc = Teuchos::null;
544  }
545 
546  // Similar as xdot.
547  Teuchos::RCP<Thyra::VectorBase<Scalar> > xdotdot_nc;
548  if (inArgs.supports(MEB::IN_ARG_x_dot_dot)) {
549  xdotdot_nc =
550  rcp_const_cast<Thyra::VectorBase<Scalar> > (inArgs.get_x_dot_dot());
551  } else {
552  xdotdot_nc = Teuchos::null;
553  }
554 
555  Teuchos::RCP<StepperState<Scalar> > stepperState_nc;
556  if (stepperState == Teuchos::null) {
557  stepperState_nc = Teuchos::rcp(new StepperState<Scalar> ()); // Use default
558  } else {
559  stepperState_nc = stepperState;
560  }
561 
562  Teuchos::RCP<PhysicsState<Scalar> > physicsState_nc;
563  if (physicsState == Teuchos::null) {
564  physicsState_nc = Teuchos::rcp(new PhysicsState<Scalar> ()); // Use default
565  } else {
566  physicsState_nc = physicsState;
567  }
568 
569  Teuchos::RCP<SolutionState<Scalar> > ss = rcp(new SolutionState<Scalar> (
570  metaData_nc, x_nc, xdot_nc, xdotdot_nc, stepperState_nc, physicsState_nc));
571 
572  return ss;
573 }
574 
575 } // namespace Tempus
576 #endif // Tempus_SolutionState_impl_hpp
Teuchos::RCP< SolutionState< Scalar > > createSolutionStateX(const Teuchos::RCP< Thyra::VectorBase< Scalar > > &x, const Teuchos::RCP< Thyra::VectorBase< Scalar > > &xdot=Teuchos::null, const Teuchos::RCP< Thyra::VectorBase< Scalar > > &xdotdot=Teuchos::null)
Nonmember constructor from non-const solution vectors, x.
PhysicsState is a simple class to hold information about the physics.
Teuchos::RCP< const SolutionStateMetaData< Scalar > > metaData_
Meta Data for the solution state.
Teuchos::RCP< PhysicsState< Scalar > > physicsState_nc_
Teuchos::RCP< const PhysicsState< Scalar > > physicsState_
PhysicsState for this SolutionState.
StepperState is a simple class to hold state information about the stepper.
bool operator>(const SolutionState< Scalar > &ss) const
Less than comparison for sorting based on time.
Teuchos::RCP< const StepperState< Scalar > > stepperState_
StepperState for this SolutionState.
virtual void copySolutionData(const Teuchos::RCP< const SolutionState< Scalar > > &s)
Deep copy solution data, but keep metaData untouched.
virtual void describe(Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel) const
SolutionState()
Default Constructor – Not meant for immediate adding to SolutionHistory. This constructor does not se...
bool operator>=(const SolutionState< Scalar > &ss) const
Less than comparison for sorting based on time.
Teuchos::RCP< SolutionState< Scalar > > createSolutionStateME(const Teuchos::RCP< const Thyra::ModelEvaluator< Scalar > > &model, const Teuchos::RCP< StepperState< Scalar > > &stepperState=Teuchos::null, const Teuchos::RCP< PhysicsState< Scalar > > &physicsState=Teuchos::null)
Nonmember constructor from Thyra ModelEvaluator.
bool operator==(const SolutionState< Scalar > &ss) const
Equality comparison for matching.
Teuchos::RCP< StepperState< Scalar > > stepperState_nc_
bool operator<=(const SolutionState< Scalar > &ss) const
Less than comparison for sorting based on time.
virtual Teuchos::RCP< SolutionState< Scalar > > clone() const
This is a deep copy constructor.
virtual void computeNorms(const Teuchos::RCP< const SolutionState< Scalar > > &ssIn=Teuchos::null)
Compute the solution norms, and solution change from ssIn, if provided.
bool operator<(const SolutionState< Scalar > &ss) const
Less than comparison for sorting based on time.
virtual std::string description() const
Solution state for integrators and steppers. SolutionState contains the metadata for solutions and th...
Teuchos::RCP< SolutionStateMetaData< Scalar > > metaData_nc_
virtual void copy(const Teuchos::RCP< const SolutionState< Scalar > > &ss)
This is a deep copy.