# TSTrajectorySetUseHistory
Use `TSHistory` in `TSTrajectory` 
## Synopsis
```
#include "petscts.h"  
PetscErrorCode TSTrajectorySetUseHistory(TSTrajectory tj, PetscBool flg)
```
Collective on tj


## Input Parameters

- ***tj -*** the `TSTrajectory` context
- ***flg -*** `PETSC_TRUE` to save, `PETSC_FALSE` to disable



## Options Database Key

- ***-ts_trajectory_use_history -*** have it use `TSHistory`





## See Also
 [](chapter_ts), `TSTrajectory`, `TSTrajectoryCreate()`, `TSTrajectoryDestroy()`, `TSTrajectorySetUp()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/trajectory/interface/traj.c.html#TSTrajectorySetUseHistory">src/ts/trajectory/interface/traj.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/ts/trajectory/interface/traj.c)


[Index of all TS routines](index.md)  
[Table of Contents for all manual pages](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
