Thyra Package Browser (Single Doxygen Collection) Version of the Day
DefaultSerialDenseLinearOpWithSolveFactory_UnitTests.cpp
Go to the documentation of this file.
00001 
00002 #include "Thyra_DefaultSerialDenseLinearOpWithSolveFactory.hpp"
00003 #include "Thyra_LinearOpWithSolveFactoryHelpers.hpp"
00004 #include "Thyra_DefaultSpmdVectorSpace.hpp"
00005 #include "Thyra_DefaultLinearOpSource.hpp"
00006 #include "Thyra_MultiVectorStdOps.hpp"
00007 #include "Thyra_LinearOpTester.hpp"
00008 #include "Thyra_LinearOpWithSolveTester.hpp"
00009 
00010 #include "Thyra_LinearOpWithSolveFactoryExamples.hpp"
00011 
00012 #include "OperatorSolveHelpers.hpp"
00013 
00014 #include "Teuchos_UnitTestHarness.hpp"
00015 #include "Thyra_UnitTestHelpers.hpp"
00016 
00017 
00018 namespace Thyra {
00019 
00020 
00021 //
00022 // Helper code and declarations
00023 //
00024 
00025 
00026 using Teuchos::as;
00027 using Teuchos::null;
00028 using Teuchos::inOutArg;
00029 
00030 
00031 //
00032 // Unit Tests
00033 //
00034 
00035 
00036 TEUCHOS_UNIT_TEST_TEMPLATE_1_DECL( DefaultSerialDenseLinearOpWithSolveFactory,
00037   LinearOpWithSolveFactoryExamples, Scalar )
00038 {
00039 
00040   const Ordinal dim = 4;
00041 
00042   const RCP<const VectorSpaceBase<Scalar> > vs =
00043     defaultSpmdVectorSpace<Scalar>(dim);
00044 
00045   const RCP<const MultiVectorBase<Scalar> > A =
00046     createNonsingularMultiVector(vs);
00047 
00048   const RCP<const LinearOpWithSolveFactoryBase<Scalar> > lowsFactory =
00049     defaultSerialDenseLinearOpWithSolveFactory<Scalar>();
00050 
00051   nonExternallyPreconditionedLinearSolveUseCases<Scalar>(*A, *lowsFactory,
00052     true, out);
00053 
00054   // Just get it to compile!
00055   bool runPrecTest = false;
00056   if (runPrecTest) {
00057     const Ptr<const PreconditionerFactoryBase<Scalar> > pfb_ptr;
00058     externallyPreconditionedLinearSolveUseCases<Scalar>(
00059       *A, *lowsFactory, *pfb_ptr, false, true, out);
00060   }
00061 
00062 }
00063 
00064 THYRA_UNIT_TEST_TEMPLATE_1_INSTANT_SCALAR_TYPES( DefaultSerialDenseLinearOpWithSolveFactory,
00065   LinearOpWithSolveFactoryExamples )
00066 
00067 
00068 } // namespace Thyra
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines