Last active
April 25, 2016 04:20
-
-
Save dangpzanco/51cf23d7b7bcba354427e2c5f6fc558f to your computer and use it in GitHub Desktop.
Duas respostas para a mesma integral
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using PyPlot | |
PyPlot.close("all") | |
## { MATLAB CODE | |
x = linspace(-pi/3,pi/3,100); | |
int1 = 0.25*sec(x).^4 - tan(x).^2 + log(abs(cos(x))); | |
int2 = 0.25*tan(x).^4 - 0.5*tan(x).^2 - log(abs(sec(x))); | |
plot(x,int1,x,int2) | |
C = sum(int1-int2)/length(x) # 0.25 | |
## MATLAB CODE } | |
print(C) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment