================================================================================
NAMA MAHASISWA : MUHAMMAD FAQIH
NIM : 220605110069
MATA KULIAH : KALKULUS
DOSEN PENGAMPU : Prof. Dr. Suhartono, M.Kom
JURUSAN : TEKNIK INFORMATIKA
UNIVERSITAS : UIN MAULANA MALIK IBRAHIM MALANG
================================================================================
LATIHAN INTEGRAL
Fungsi yang diintegrasikan dapat memiliki variabel atau parameter tambahan di luar variabel integrasi. Untuk mengevaluasi integral tertentu, Kita perlu menentukan nilai untuk variabel tambahan tersebut.
Misalnya, fungsi yang sangat penting dalam statistik dan fisika adalah Gaussian, yang memiliki grafik berbentuk lonceng:
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
##
## Attaching package: 'mosaicCalc'
## The following object is masked from 'package:stats':
##
## D
gaussian <-
makeFun((1/sqrt(2*pi*sigma^2)) *
exp( -(x-mean)^2/(2*sigma^2)) ~ x,
mean=2, sigma=2.5)
slice_plot(gaussian(x) ~ x, domain(x = -5:10)) %>%
slice_plot(gaussian(x, mean=0, sigma=1) ~ x, color="blue")
erf <- antiD(gaussian(x, mean=m, sigma=s) ~ x)
erf
## function (x, C = 0, m, s)
## {
## F <- makeF(gaussian(x, mean = m, sigma = s))
## evalFun(F, x = x, m = m, s = s, .const = C)
## }
## <environment: 0x000001dd345941d8>
erf(x = 1, m=0, s=1) - erf(x = 0, m=0, s=1)
## [1] 0.3413447