Dosen Pengampu : Prof .Dr.Suhartono, M.Kom
Lembaga : Universitas Islam Negeri Maulana Malik Ibrahim Malang
Fakultas : Sains dan Teknologi
Jurusan : Teknik Informatika
Kelas : (C) Kalkulus
NIM : 230605110080
library(mosaicCalc)
## Loading required package: mosaic
## Registered S3 method overwritten by 'mosaic':
## method from
## fortify.SpatialPolygonsDataFrame ggplot2
##
## The 'mosaic' package masks several functions from core packages in order to add
## additional features. The original behavior of these functions should not be affected by this.
##
## Attaching package: 'mosaic'
## The following objects are masked from 'package:dplyr':
##
## count, do, tally
## The following object is masked from 'package:Matrix':
##
## mean
## The following object is masked from 'package:ggplot2':
##
## stat
## The following objects are masked from 'package:stats':
##
## binom.test, cor, cor.test, cov, fivenum, IQR, median, prop.test,
## quantile, sd, t.test, var
## The following objects are masked from 'package:base':
##
## max, mean, min, prod, range, sample, sum
## Loading required package: mosaicCore
##
## Attaching package: 'mosaicCore'
## The following objects are masked from 'package:dplyr':
##
## count, tally
## The legacy packages maptools, rgdal, and rgeos, underpinning the sp package,
## which was just loaded, will retire in October 2023.
## Please refer to R-spatial evolution reports for details, especially
## https://r-spatial.org/r/2023/05/15/evolution4.html.
## It may be desirable to make the sf package available;
## package maintainers should consider adding sf to Suggests:.
## The sp package is now running under evolution status 2
## (status 2 uses the sf package in place of rgdal)
##
## Attaching package: 'mosaicCalc'
## The following object is masked from 'package:stats':
##
## D
Selamat datang di artikel ini! Artikel yang akan membahas tentang zero finding.
Zero finding atau pencarian akar adalah proses untuk menemukan nilai dari suatu variabel yang membuat suatu fungsi menjadi nol. Dalam matematika, ini sering kali dikenal sebagai mencari akar atau solusi dari suatu persamaan. Secara umum, tujuan dari zero finding adalah untuk menemukan nilai-nilai di mana suatu fungsi mencapai nilai nol.
Contoh umum dari zero finding adalah mencari akar dari fungsi kuadrat. Misalkan terdapat fungsi kuadrat umum yaitu f(x) = ax^2 + bx + c. Akar dari fungsi ini dapat ditemukan dengan mengaturnya menjadi f(x)= 0 dan menyelesaikan persamaan kuadrat tersebut untuk x.
Contoh: Untuk f(x)= x^2 − 4, diatur f(x) = 0 dan mencari nilai x yang membuat persamaan tersebut benar. x^2 − 4 = 0 x^2 = 4 x = ±2
Jadi, akar dari fungsi f(x) = x^2 − 4 adalah x = 2 dan x = −2.
library(ggplot2)
x <- seq(-4, 4, by = 0.1)
y <- x^2 - 4
plot(x, y, type = "l", col = "blue", lwd = 2, xlab = "x", ylab = "f(x)", main = "Grafik f(x) = x^2 - 4")
points(c(2, -2), c(0, 0), col = "red", pch = 16)
abline(v = c(2, -2), col = "green", lty = 2)
text(2, 0.5, "x = 2", col = "red")
text(-2, 0.5, "x = -2", col = "red")
Metode pencarian akar dapat bervariasi, dan beberapa metode umum melibatkan pendekatan berulang untuk mendekati nilai-nilai di mana fungsi mencapai nol. Salah satu metode yang umum digunakan adalah metode Newton-Raphson. Metode ini melibatkan pendekatan iteratif untuk mendekati akar suatu fungsi.
Harap dicatat bahwa mencari akar suatu fungsi bisa menjadi tugas yang kompleks tergantung pada sifat fungsi tersebut, dan beberapa fungsi mungkin tidak memiliki akar yang dapat ditemukan secara analitis. Oleh karena itu, metode numerik sering digunakan untuk mendekati solusi numerik.