ROL: Explicitly uses GlobalOrdinal=int with Tpetra, doesn't need to
Created by: mhoemmen
@trilinos/rol
Line 292 of rol/example/PDE-OPT/TOOLS/assembler.hpp
(in Trilinos develop) explicitly calls Tpetra::createOneToOne<int,int>
. This forces use of GlobalOrdinal = int
. See #74 (closed) for why we don't want this.
The line is easy to fix: just do this:
myUniqueStateMap_ = Tpetra::createOneToOne (myOverlapStateMap_);
That is, let createOneToOne
deduce its template parameters on its own. It can do so by looking at the input argument.
There are a few other places in the file that force this constraint, e.g., line 231:
Teuchos::Array<int> myGlobalIds;
(replace int
with GO
and define GO
as Tpetra::Map<>::global_ordinal_type
).