TSSetTime — PETSc 3.23.0 documentation

Skip to main content
`Ctrl`+`K`

# TSSetTime

Allows one to reset the time.

## Synopsis

    #include "petscts.h"
    PetscErrorCode TSSetTime(TS ts, PetscReal t)

Logically Collective

## Input Parameters

- ts - the `TS` context obtained from `TSCreate()`

- t - the time

## See Also

TS: Scalable ODE and DAE Solvers, `TS`, `TSGetTime()`, `TSSetMaxSteps()`

## Level

intermediate

## Location

src/ts/interface/ts.c

## Examples

src/ts/tutorials/ex40.c
src/tao/unconstrained/tutorials/spectraladjointassimilation.c
src/ts/tutorials/ex41.c
src/ts/utils/dmplexlandau/tutorials/ex2.c
src/ts/utils/dmplexlandau/tutorials/ex1.c
src/tao/unconstrained/tutorials/burgers_spectral.c
src/ts/tutorials/ex20opt_p.c
src/ts/tutorials/ex50.c
src/ts/tutorials/ex20opt_ic.c

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