Omni Calculator logo

Sigmoid Calculator

    σ(x)=11+e−x\LARGE \sigma(x) = \frac{1}{1 + e^{-x}}

(x)

σ(x)

Sigmoid chart

Did we solve your problem today?

Check out 48 similar coordinate geometry calculators 📈

Distance

Slope

Vector

Build your calculator with Builder

Add as preferred on Google

This sigmoid calculator computes the value of the sigmoid function for any numeric input. You may encounter this function in areas such as statistics, probability, logistic regression, and machine learning. It is useful for working with real numbers, whether positive, negative, or zero, and maps them to a value between 0 and 1. The results change smoothly as the input changes, producing the characteristic S-shaped curve associated with sigmoid functions.

The sigmoid function turns any unrestricted numerical value into a bounded output. For example, in machine learning, a model may use it to produce a probability score (likelihood that something is true or otherwise) in the appropriate context.

You can use this sigmoid calculator to evaluate sigmoid values quickly without manually working through the exponential calculations.

In the following, we will take a look at:

  • How the sigmoid function works;
  • Fields in which the sigmoid function is used;
  • How we can calculate the sigmoid function; and
  • What the sigmoid graph tells us.

What is the sigmoid function?

A sigmoid function converts any real number into a value between 0 and 1. The term “sigmoid” refers to the graph’s S-like shape.

In this function, for relatively large values, the graph changes very little, but for smaller values, it changes more rapidly.

This function is especially useful in fields like statistics, probability, and artificial intelligence because it transforms values from an unbounded range into the interval 0 to 1.

There are several variations of this function, but the most well-known sigmoid function is called the logistic sigmoid function. It is defined as:

σ(x)=1/(1+e−x)\large \sigma(x) = 1 / (1 + e^{-x})

Where ee is also known as Euler’s number, which is approximately 2.71828.

Example:
Using the formula for the logistic sigmoid function, if we want to find the value of σ(2)\sigma(2), we can evaluate σ(x)\sigma(x) with x=2x = 2, as follows:

σ(2)=1/(1+e−2)\sigma(2) = 1/(1 + e^{-2})

To simplify further, first find the value of e−2e^{-2}. This will be approximately 0.1353. Substituting this into σ(2)\sigma(2), we get:

σ(2)=1/(1+0.1353)\sigma(2) = 1/(1 + 0.1353)

Thus:
σ(2)≈0.8808\sigma(2) \approx 0.8808

Therefore, an input of 2 results in an output of approximately 0.8808.

However, if the value of xx is negative, the output of the function will be closer to 0.

Example:
Evaluating σ(x)\sigma(x) with x=−2x = -2, we get:

σ(−2)=1/(1+e2)\sigma(-2) = 1/(1 + e^2)

Thus:
σ(−2)=0.1192σ(-2) = 0.1192

Based on both results, we can see that in the logistic sigmoid function, if the input is negative, the output approaches 0, and if the input is positive, the output approaches 1. But for any finite input, the function will never produce an output that is equal to 0 or 1.

💡 A value of 0 is always mapped to 0.5.

  • σ(0) = 1/(1 + e⁰) = 1/2 = 0.5

Therefore, the function equals its midpoint when the input is 0.

You might want to try our cycloid calculator. It allows you to calculate the necessary parameters required to generate a cycloid.

The sigmoid formula: How to use the sigmoid calculator

The sigmoid calculator saves you from repeatedly calculating exponential values by hand.

Simply enter the value of xx, and the calculator evaluates:

1/(1+e−x)\large 1 / (1+e^{-x})

For example, if your input is x=1.5x = 1.5, the calculation is:

σ(1.5)=1/(1+e−1.5)\large \sigma(1.5)=1 / (1+e^{-1.5})

Since:

e−1.5≈0.22313\large e^{-1.5}\approx0.22313

We get:

σ(1.5)=1/(1+0.22313)\sigma(1.5)=1 / (1+0.22313)

Therefore:

σ(1.5)≈0.8176\sigma(1.5)\approx0.8176

So the calculator gives a sigmoid value of approximately 0.8176.

This can be particularly helpful when you are testing several inputs or working with large values that would be inconvenient to calculate manually.

Sigmoid curve

If you plot the sigmoid function, you get a smooth S-shaped curve.

As xx tends to −∞-\infty, the curve approaches 0. As xx increases, it begins to rise more noticeably as it approaches x=0x=0. The curve is steepest around the middle and passes through y=0.5y=0.5 when x=0x=0. After that, it gradually flattens as it approaches 1.

The curve never actually reaches either 0 or 1. Instead, those values act as horizontal asymptotes.

Mathematically:

lim⁡x→−∞σ(x)=0\large \lim_{x\to-\infty}\sigma(x)=0

and:

lim⁡x→∞σ(x)=1\large \lim_{x\to\infty}\sigma(x)=1

This explains why extremely large positive inputs give results that appear to be 1 when rounded, while extremely large negative inputs can appear to be 0.

Try out our catenary curve calculator, which generates the graph of the catenary function.

Important properties of the sigmoid function

The sigmoid function has several properties worth noting:

  • Its output is bounded. The result is always greater than 0 and less than 1. This is one of the main reasons the function is useful when a model requires a limited output.

  • It is strictly increasing. As xx increases, the sigmoid value also increases. The curve never turns or drops.

  • Its midpoint is 0.5, so when x=0x = 0, the output is exactly 0.5.

  • It is symmetric around its midpoint in a very particular way. Rather than being symmetric in the usual sense, the function satisfies:

    σ(−x)=1−σ(x)\sigma(-x)=1-\sigma(x)

    This means the sigmoid values for xx and −x-x always add up to 1.

  • Its slope is greatest around zero. The curve is relatively flat at both ends and changes most rapidly around the center.

Together, these properties explain much of the sigmoid function’s behavior, which is particularly useful in modeling and classification.

You might also want to check out our tangent calculator, which helps you find the tangent of any angle.

Why is the sigmoid function useful?

The function maps unrestricted real-valued inputs to restricted values between 0 and 1.

Any output from a sigmoid function can be interpreted as a probability, but only when the model and context justify that interpretation. Applying the function to a model output that produces an unrestricted value gives a probability estimate within the model’s constraints. A score of 0.6 might represent a 60% probability of the event occurring based on that model.

It is important to note that the conversion of a model output to a sigmoid function value does not automatically create a meaningful probability. You can interpret the function as a probability only if the model and its context support that interpretation.

FAQs

What is the sigmoid of 0?

The sigmoid of zero is exactly 0.5. This follows directly from the formula:

σ(x) = 1 / (1 + e^(-x))

     = 1 / (1 + e^(0))

     = 1 / 2

     = 0.5

Therefore, zero is the midpoint of the standard sigmoid curve.

What is the range of the sigmoid function?

The sigmoid function ranges between 0 and 1. This comes directly from its formula:

σ(x) = 1 / (1 + e^(-x))

The exponential function e^(-x) is always positive. Therefore, the denominator (1 + e^(-x)) is always greater than 1.

And because you are dividing 1 by a number greater than 1, the result must be greater than 0 but less than 1.

This gives the function its characteristic bounded output without requiring an artificial cutoff.

What is the difference between sigmoid and tanh?

Although sigmoid and tanh both have S-shaped curves, their output ranges differ. The sigmoid function outputs values between 0 and 1, while tanh outputs values between -1 and 1.

The sigmoid function is typically referred to as the probability function and is commonly used for binary classification.

On the other hand, tanh is also used as an activation function in artificial neural networks.