Skip to content

NVDIV/CubicEquation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 

Repository files navigation

Cubic Equation Solver

This C program solves cubic equations of the form ( ax^3 + bx^2 + cx + d = 0 ). Developed during my programming course, the program computes the roots, which may be real or complex.

Features

  • Input coefficients ( a ), ( b ), and ( c ) for the cubic equation.
  • Calculate and display the roots of the equation.
  • Handle cases for distinct real roots, repeated roots, and complex roots.

Technologies Used

  • C programming language

Getting Started

To compile and run the program, follow these steps:

  1. Clone the ropository:
git clone https://github.com/NVDIV/CubicEquation.git
  1. Navigate to the project directory:
cd CubicEquation
  1. Compile the program:
gcc -o cubic cubic.c
  1. Run the program:
./cubic

How to Use

Enter the coefficients π‘Ž, 𝑏 and 𝑐 when prompted. The program will calculate and display the roots of the cubic equation..

Contact

If you’d like to reach out, feel free to connect with me:

Thanks for visiting!

About

This repository contains a C program that solves cubic equations of the form π‘Ž (π‘₯^3) + 𝑏 (π‘₯^2) + 𝑐 π‘₯ + 𝑑 = 0. The program computes the roots, which can be real or complex, using the method of Cardano.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages