Intermediate

Sine Function Calculator — y = A·sin(Bx + C) + D

Enter the four parameters of a general sine function — amplitude A, angular frequency B, phase C and vertical shift D — plus any x-value, and instantly see the function value, period, frequency and phase shift.
Vertical stretch factor (height of each peak)
Controls period: period = 2π / |B| (B ≠ 0)
Horizontal shift inside the sine: y = A·sin(Bx + C) + D
Moves the whole wave up or down
x-value at which to compute y = A·sin(Bx + C) + D
y at x
0

A · sin(B·x + C) + D evaluated at the given x

y = A · sin(Bx + C) + D
0
Amplitude |A|
1
Period 2π / |B|
6.2832 rad
Frequency 1/period
0.159155 Hz
Phase shift −C/B
-0 rad (-0°)
Vertical shift D
0
Maximum y
1
Minimum y
-1
y = A · sin(Bx + C) + D — amplitude and phase shift visualised
Step by step
  1. 1

    Inner argument B·x + C

    1 × 0 + 0 = 0
  2. 2

    sin(B·x + C)

    sin(0) = 0
  3. 3

    Multiply by amplitude A

    1 × 0 = 0
  4. 4

    Add vertical shift D → y

    0 + 0 = 0
Results are estimates for general information only and are not professional advice — always verify important results independently before relying on them. Read the full disclaimer.
Quick answer

How does this calculator work?

y = A·sin(Bx + C) + D. Amplitude = |A|, period = 2π/|B|, phase shift = −C/B rad, midline = D. Enter any x to get y. Max value = D + |A|, min = D − |A|. Sine is always periodic and bounded; changing B is the fastest way to adjust frequency.

Formula
y = A · sin(B·x + C) + D • Period = 2π/|B| • Phase shift = −C/B
How this is calculated

The general sine function y = A · sin(Bx + C) + D has four independently adjustable parameters. Amplitude A scales the height of each peak — the wave oscillates between D − |A| and D + |A|, never crossing outside those bounds. Angular frequency B controls how quickly the wave repeats: one full cycle spans 2π/|B| radians (or 360°/|B| in degree-based contexts). A larger |B| compresses the wave horizontally, giving a higher frequency.

Phase C shifts the wave horizontally — the whole pattern moves left or right by −C/B radians. A positive C shifts the graph to the left; negative C shifts it right. Vertical shift D translates the entire wave up or down, setting the midline of oscillation at y = D instead of y = 0.

The function is evaluated at the specified x using the exact formula A × Math.sin(B × x + C) + D. Because the wave is periodic, the same output y recurs every 2π/|B| units along the x-axis. The animated waveform shows the shape scaled to the amplitude and phase you have entered.

Frequently asked questions

The period is 2π divided by the absolute value of B: period = 2π / |B|. For B = 1 the period is 2π ≈ 6.283; for B = 2 it halves to π ≈ 3.142. The amplitude A and shifts C, D have no effect on the period.

Phase shift = −C/B moves the entire wave left (if positive) or right (if negative) along the x-axis. For example, y = sin(x − π/2) has phase shift +π/2 ≈ 1.571, so the whole sine curve shifts right by that amount. It is equivalent to a delay (or advance) in the waveform.

The maximum is D + |A| (when sin = +1) and the minimum is D − |A| (when sin = −1). The amplitude |A| is the distance from the midline y = D to either peak. If A is negative, the wave is reflected vertically but the extremes are the same.

APA

TG we-Calculate Editorial Team. (2026). Sine Function Calculator — y = A·sin(Bx + C) + D [Online calculator]. TG we-Calculate. https://we-calculate.com/calculator/sine-function-calculator

Chicago

TG we-Calculate Editorial Team. "Sine Function Calculator — y = A·sin(Bx + C) + D." TG we-Calculate. 2026. https://we-calculate.com/calculator/sine-function-calculator.

IEEE

TG we-Calculate Editorial Team, "Sine Function Calculator — y = A·sin(Bx + C) + D," TG we-Calculate, 2026. [Online]. Available: https://we-calculate.com/calculator/sine-function-calculator

BibTeX

@misc{wecalculate_sine_function_calculator, title = {Sine Function Calculator — y = A·sin(Bx + C) + D}, author = {{TG we-Calculate Editorial Team}}, howpublished = {\url{https://we-calculate.com/calculator/sine-function-calculator}}, year = {2026}, note = {TG we-Calculate} }

Did this calculator help you?