Last active
February 23, 2022 15:26
-
-
Save codistwa/08a1a67955791d751bd8126bed91855a to your computer and use it in GitHub Desktop.
Course source code: https://codistwa.com/guides/functions-in-math. More courses on https://codistwa.com
This file contains hidden or 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
# ============================================================ | |
# Definition of fonction | |
# ============================================================ | |
def area(x): | |
return 2 * x | |
print(area(4)) | |
x = np.linspace(-6,6) | |
f = x*2 | |
plt.plot(x,f,label='f') | |
plt.axis([0,6,0,6]) | |
plt.grid() | |
plt.legend() | |
plt.title('Function',fontsize=12) | |
plt.savefig('function', bbox_inches='tight') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment