Skip to main content
`Ctrl`+`K`

# SNESLoad

Loads a `SNES` that has been stored in `PETSCVIEWERBINARY` with `SNESView()`.

## Synopsis

    #include "petscsnes.h"
    PetscErrorCode SNESLoad(SNES snes, PetscViewer viewer)

Collective

## Input Parameters

- snes - the newly loaded `SNES`, this needs to have been created with `SNESCreate()` or some related function before a call to `SNESLoad()`.

- viewer - binary file viewer, obtained from `PetscViewerBinaryOpen()`

## Note

The `SNESType` is determined by the data in the file, any type set into the `SNES` before this call is ignored.

## See Also

SNES: Nonlinear Solvers, `SNES`, `PetscViewer`, `SNESCreate()`, `SNESType`, `PetscViewerBinaryOpen()`, `SNESView()`, `MatLoad()`, `VecLoad()`

## Level

intermediate

## Location

src/snes/interface/snes.c

Index of all SNES routines
Table of Contents for all manual pages
Index of all manual pages