ok, here is what I want to do:

I am writing a brand new PC which needs some other PETSc objects like a Vec (for unit partition).

We have a text based user file format in which the user can create arbitrary Petsc's Vec or Mat.

Then, I would like the user to give the prefix of these Vec or Mat as a parameter for the new PC that we would like to configure completely via the "petsc options database".

So in our PCApply_XXX we would like to retrieve some specific options which will simply give the Vec prefix to retreive.

Thanks,

Eric


On 2023-01-13 15:39, Matthew Knepley wrote:
On Fri, Jan 13, 2023 at 4:24 AM Eric Chamberland <eric.chamberl...@giref.ulaval.ca> wrote:

    Hi,

    Is it possible with PETSc's API to query an objet by it's name?

    Is there a "global" database with all PETScObject created?


No, we do not store that information. What would the use case be? Maybe there is another way to do it.

  Thanks,

    Matt

    Thanks,

    Eric

-- Eric Chamberland, ing., M. Ing
    Professionnel de recherche
    GIREF/Université Laval
    (418) 656-2131 poste 41 22 42



--
What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>

--
Eric Chamberland, ing., M. Ing
Professionnel de recherche
GIREF/Université Laval
(418) 656-2131 poste 41 22 42

Reply via email to