用符号做照片的网站,ps设计网站步骤,网站建设推荐华网天下,装修公司最怕三种人常量函数#xff0c;幂函数#xff0c;指数函数#xff0c;对数函数#xff0c;三角函数和反三角函数成为基本初等函数。基本初等函数经过有限四则运算和符合运算得到的函数称为初等函数。 1. 常量函数
表达式#xff1a; #xff08;其中 c 是常数#xff09;参数的意… 常量函数幂函数指数函数对数函数三角函数和反三角函数成为基本初等函数。基本初等函数经过有限四则运算和符合运算得到的函数称为初等函数。 1. 常量函数
表达式 其中 c 是常数参数的意思 是一个固定的常数。定义域c值域 奇偶性 偶函数单调性 不单调周期性 周期性周期为任意值manim示例 from manim import * class FunctionC1(Scene): def construct(self): a1MathTex(constant Function).shift(3.5*UP) self.add(a1)title Title().shift(3.4*UP) self.add(title) # Create axes and shift them down ax Axes().add_coordinates().shift(0.2*DOWN) # Plot the constant function f(x) 1 curve ax.plot(lambda x: 1, colorDARK_BLUE) label MathTex(rf(x) 1 \\ c1).next_to([-3,1.5,0], buff0.1).set_color(DARK_BLUE)# Add a label to the curve #label MathTex(f(x) 1).next_to(curve, UR, buff0.2).set_color(DARK_BLUE).shift(2*LEFT) # Add the axes and the curve to the scene self.add(ax, curve, label) 2. 幂函数
表达式 其中 n为常数参数的意思 n是幂的指数。定义域 n为正整数x (−∞,∞)n为负整数 x0值域 n为偶数[0,∞)n为奇数 (−∞,∞)n为负数 (0,∞)当 x0奇偶性 偶函数当 n为偶数奇函数当 n 为奇数单调性 当 n0 时单调递增n为奇数时可在 x0 区间内非单调当 n0 时在 x0 区间单调递减。周期性 非周期性
示例
from manim import * class FunctionPow(Scene): def construct(self): # Title for the plot title Title(Power Functions) self.add(title) # Create axes ax Axes().add_coordinates().shift(0.2*DOWN) #ax.add_coordinate_labels() # 添加坐标标签 # Plot the functions with appropriate ranges curve1 ax.plot(lambda x: x**(-2), colorDARK_BLUE, x_range[0.1, 2.3]) # x 0 curve2 ax.plot(lambda x: x**0.5, colorYELLOW, x_range[0, 2.3]) # x 0 curve3 ax.plot(lambda x: x**1, colorGREEN, x_range[-2.4, 2.3]) curve4 ax.plot(lambda x: x**3, colorORANGE, x_range[-1.5, 1.2]) # Add labels to the curves label1 MathTex(rf(x) x^{-2}).next_to([2,0.5,0], buff0.1).set_color(DARK_BLUE) label2 MathTex(rg(x) x^{0.5}).next_to(curve2, UR, buff0.1).set_color(YELLOW) label3 MathTex(rh(x) x).next_to(curve3, UR, buff0.1).set_color(GREEN) label4 MathTex(ri(x) x^3).next_to(curve4, DL, buff0.1).set_color(ORANGE) # Add everything to the scene self.add(ax, curve1, curve2, curve3, curve4, label1, label2, label3, label4) 3. 指数函数
表达式 其中 a0,a≠1参数的意思 a是基数x是指数。定义域 x(−∞,∞)值域 (0,∞)奇偶性 非奇偶函数单调性 a1时单调递增0a1时单调递减周期性 非周期性 from manim import *
import math as maclass FunctionExponential(Scene): def construct(self): # Title for the plot title Title(Exponential Function) self.add(title) # Create axes ax Axes(x_range[-1,9],y_range[-1,9],x_length12,y_length6).add_coordinates().shift(0.2*DOWN) #ax.add_coordinate_labels() # 添加坐标标签 # Plot the functions with appropriate ranges curve1 ax.plot(lambda x: 0.5**x, colorDARK_BLUE, x_range[-5, 5]) # 1 a 0 curve2 ax.plot(lambda x: 1.5**x, colorYELLOW, x_range[-5, 2.7]) # a1 curve3 ax.plot(lambda x: ma.exp(x), colorPINK, x_range[-5, 2.7]) # a1 # Add labels to the curves label1 MathTex(rf(x) 0.5^{x} \\ a0.5,0a1).next_to([1.5,-1,0], buff0.1).set_color(DARK_BLUE) label2 MathTex(rg(x) 1.5^{x} \\ a2,a1).next_to(curve2, UR, buff0.1).set_color(YELLOW) label3 MathTex(rg(x) e^{x} \\ a2,a1).next_to([-2,2,0]).set_color(PINK) # Add everything to the scene self.add(ax, curve1, curve2,curve3, label1, label2,label3) 4. 对数函数
表达式其中 a0,a≠1参数的意思 a是底数x 是对数的真数。定义域 x(0,∞)值域 f(x)(−∞,∞)奇偶性 非奇偶函数单调性 单调递增周期性 非周期性 from manim import *
import math as ma class FunctionLogarithm(Scene): def construct(self): # Title for the plot title Title(Logarithmic Functions) self.add(title) # Create axes ax Axes(x_range[0.01, 9], y_range[-3, 3], x_length10, y_length5).add_coordinates().shift(0.2*DOWN) # Plot the functions with appropriate ranges curve1 ax.plot(lambda x: ma.log(x, 0.5), colorDARK_BLUE, x_range[0.01, 6]) # a 1 curve2 ax.plot(lambda x: ma.log(x, 2), colorYELLOW, x_range[0.01, 8]) # a 2 curve3 ax.plot(lambda x: ma.log(x), colorPINK, x_range[0.01, 8]) # a e # Add labels to the curves label1 MathTex(rf(x) \log_{0.5}{x} \\ a0.5, 0a1).next_to([2.5, -2, 0], buff0.1).set_color(DARK_BLUE) label2 MathTex(rg(x) \log_{2}{x} \\ a2).next_to(curve3, UR, buff0.1).set_color(YELLOW) label3 MathTex(rh(x) \log{x} \\ ae).next_to([2.5,0.5, 0], buff0.1).set_color(PINK) # Add everything to the scene self.add(ax, curve1, curve2, curve3, label1, label2, label3) 5. 三角函数
表达式 正弦函数 f(x)sinxf(x)sinx余弦函数 f(x)cosxf(x)cosx正切函数 f(x)tanxf(x)tanx参数的意思 xx 是角度通常以弧度为单位。定义域 sin(x)和 cos(x) x(−∞,∞)tan(x)值域 sin(x)和 cos(x) [−1,1][−1,1]tan(x) (−∞,∞)奇偶性 sinx 奇函数cosx 偶函数tanx 奇函数单调性 sinx 在 (2kπ,(2k1)π) 上单调递增cosx 在 (2kπ,(2k1)π)上单调递减tanx 在每个周期内单调递增周期性 sin(x)和 cos(x) 周期 2πtanx 周期 ππ from manim import *
import numpy as np class FunctionTrigonometric(Scene): def construct(self): # Title for the plot title Title(Trigonometric Functions) self.add(title) # Create axes ax Axes(x_range[-6, 6], y_range[-2, 2], x_length12, y_length6).add_coordinates().shift(0.2*DOWN) # Plot the functions with appropriate ranges curve1 ax.plot(np.sin, colorDARK_BLUE, x_range[-6, 4]) # Sin function curve2 ax.plot(np.cos, colorYELLOW, x_range[-6, 5]) # Cos function curve3 ax.plot(np.tan, colorPINK, x_range[-1.19, 1]) # Tan function # Add labels to the curves label1 MathTex(rf(x) \sin{x}).next_to(curve1, DR, buff0.1).set_color(DARK_BLUE) label2 MathTex(rg(x) \cos{x}).next_to(curve2, UR, buff0.1).set_color(YELLOW) label3 MathTex(rh(x) \tan{x}).next_to(curve3, UR, buff0.1).set_color(PINK) # Add everything to the scene self.add(ax, curve1, curve2, curve3, label1, label2, label3) 6. 反三角函数
表达式 arcsin(x)arccos(x)arctan(x)参数的意思 x是三角函数的值。定义域 arcsin(x) [−1,1]arccos(x [−1,1]arctan(x) (−∞,∞)值域 arcsin(x)arccos(x)arctan(x) 奇偶性 arcsinx 奇函数arccosx 非奇偶函数arctanx 奇函数单调性 arcsinx 单调递增arccosx 单调递减arctanx 单调递增周期性 非周期性 from manim import *
import numpy as np
import mathclass FunctionInverseTrigonometric(Scene): def construct(self): # Title for the plot title Title(Inverse Trigonometric Functions) self.add(title) # Create axes ax Axes(x_range[-7.5, 7.5], y_range[-5, 5], x_length12, y_length6).add_coordinates().shift(0.2*DOWN) # Plot the functions with appropriate ranges curve1 ax.plot(np.arcsin, colorDARK_BLUE, x_range[-1, 1]) # Inverse Sin function curve2 ax.plot(math.acos, colorYELLOW, x_range[-1, 1]) # Inverse Cos function curve3 ax.plot(np.arctan, colorPINK, x_range[-10, 4]) # Inverse Tan function # Add labels to the curves label1 MathTex(rf(x) \arcsin{x}).next_to(curve1, UR3*UP, buff0.1).set_color(DARK_BLUE) label2 MathTex(rg(x) \arccos{x}).next_to(curve2, DR5*DOWN, buff0.1).set_color(YELLOW) label3 MathTex(rh(x) \arctan(x)).next_to(curve3, UR, buff0.1).set_color(PINK) # Add everything to the scene self.add(ax, curve1, curve2, curve3, label1, label2, label3)