- Home /

# how to use time on lerp

hi everyone, iàm trying to undestand how to make my lerp start faster like an impulse, the slow it overtime, iàm using this now

```
float t = currentLerpTime / lerpTime;
t = Mathf.Sin(t * Mathf.PI * 0.5f);
```

but doesnàt work as expected.. what i missing?

thank's you in advance

**Answer** by jenci1990
·
Nov 28, 2018 at 03:01 PM

This is a sinusoidal easing timing, but there are some other useful easing math. Try these:

```
//Sinusoidal (same as yours)
t = Mathf.Sin(t * Mathf.PI / 2f);
//Quadratic
t = t * (2 - t);
//Cubic
t = t * t * t + 1;
//Exponential
t = t == 1f ? 1f : 1f - Mathf.Pow(2f, -10f * t);
//Circular
t = Mathf.Sqrt(1f - (--t * t));
```

If these one not working, you make a mistake elsewhere.

**Answer** by UnityCoach
·
Nov 28, 2018 at 07:09 PM

You may want to use an AnimationCurve.

```
[SerializeField] AnimationCurve timeWarpCurve;
float t = timeWarpCurve.Evaluate(Time.time);
t = Mathf.Sin(t * Mathf.PI * 0.5f);
```

### Your answer

### Welcome to Unity Answers

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.

### Follow this Question

### Related Questions

Trying to lerp in different states in a switch statement 0 Answers

Jump with mathf.lerp problem 2 Answers

Mathf.Lerp not working 2 Answers

Lerping & OnCollisionEnter - how do i lerp without update?? 1 Answer