高等数学基础(牛顿/莱布尼茨公式)

news2025/5/21 6:10:26

牛顿/莱布尼茨公式主要是为定积分的计算提供了高效的方法, 其主要含义在于求积分的函数( f ( x ) f(x) f(x))连续时候总是存在一条积分面积的函数( F ( x ) F(x) F(x))与之对应, 牛顿莱布尼茨公式吧微分和积分联系了起来, 提供了这种高效计算积分面积的方法

参考视频理解: https://www.bilibili.com/video/BV1qo4y1G7Da/

积分上限的函数及其导数

设函数 f ( x ) f(x) f(x)在区间 [ a , b ] [a, b] [a,b]上连续, 对于任意点 x ∈ [ a , b ] x \in [a, b] x[a,b], 函数 f ( x ) f(x) f(x) [ a , x ] [a, x] [a,x]上仍然连续, 定积分 ∫ a x f ( x ) d x \int_a^xf(x)dx axf(x)dx一定存在. 此处的 x x x即表示积分上限, 又表示积分变量, 因为积分值和变量名字无关, 又可以表示为 ∫ a x f ( t ) d t \int_a^xf(t)dt axf(t)dt

如果上限 x x x在区间 [ a , b ] [a,b] [a,b]上任意变动, 对于每一个给定的 x x x都有一个确定的值积分值与之对应, 所以在 [ a , b ] [a,b] [a,b]上定义一个函数, 记做 ϕ ( x ) \phi(x) ϕ(x), 那么 ϕ ( x ) = ∫ a x f ( t ) d t \phi(x)=\int_a^xf(t)dt ϕ(x)=axf(t)dt, a ≤ x ≤ b a \le x \le b axb

函数 ϕ ( x ) \phi(x) ϕ(x)是积分上限 x x x的函数, 也称为 f ( t ) f(t) f(t)的变上限积分, ϕ ( x ) \phi(x) ϕ(x)具有下面的性质

连续就可导, 导数等于原函数

如果函数 f ( x ) f(x) f(x)在区间 [ a , b ] [a, b] [a,b]上连续, 则积分上限函数 ϕ ( x ) = ∫ a x f ( t ) d t \phi(x)=\int_a^xf(t)dt ϕ(x)=axf(t)dt可导
ϕ ′ ( x ) = d d x ∫ a x f ( t ) d t = f ( x ) \phi'(x)=\frac{d}{dx}\int_a^xf(t)dt=f(x) ϕ(x)=dxdaxf(t)dt=f(x), a ≤ x ≤ b a \le x \le b axb

比如:
d d x ( ∫ a x s i n 2 t d t ) = s i n 2 x \frac{d}{dx}(\int_a^xsin^2tdt) = sin^2x dxd(axsin2tdt)=sin2x

原函数存在定理

如果函数 f ( x ) f(x) f(x) [ a , b ] [a, b] [a,b]上连续, 则函数 ϕ ( x ) = ∫ a x f ( t ) d t \phi(x)=\int_a^xf(t)dt ϕ(x)=axf(t)dt就是 f ( x ) f(x) f(x) [ a , b ] [a, b] [a,b]上的一个原函数

牛顿莱布尼茨公式

设函数 f ( x ) f(x) f(x)在区间 [ a , b ] [a, b] [a,b]上连续, F ( x ) F(x) F(x) f ( x ) f(x) f(x) [ a , b ] [a, b] [a,b]上的原函数, 则 ∫ a b f ( x ) d x = F ( b ) − F ( a ) \int_a^bf(x)dx = F(b) - F(a) abf(x)dx=F(b)F(a)

一个连续函数在区间上的定积分等于它的任意一个原函数在区间上的增量

牛顿莱布尼茨公式几何解释

积分是在确定函数的导数的基础上, 通过一定的数学方法对原函数进行求解的过程. 积分的基本思想是通过微分的"无限求和"进行的. 微分是对原函数求导过程, 于是又可以讲积分看成微分逆向过程

设函数 y = f ( x ) y=f(x) y=f(x), 吧区间 [ a , b ] [a, b] [a,b]分为4份, 整体等于部分之和, f ( b ) − f ( a ) = ∑ Δ y f(b)-f(a)=\sum \Delta y f(b)f(a)=Δy,继续细分入图二表示, 间隔为 d x dx dx, 对应的 Δ y \Delta y Δy变为了 d y dy dy, 所以 f ( b ) − f ( a ) = ∑ d y f(b) - f(a) = \sum dy f(b)f(a)=dy, 从细分可知 d y = f ′ ( x ) d x dy = f'(x)dx dy=f(x)dx, f ( b ) − f ( a ) = ∑ f ′ ( x ) d x f(b) - f(a) = \sum f'(x)dx f(b)f(a)=f(x)dx

import numpy as np
import matplotlib.pyplot as plt


# 设置中文字体
plt.rcParams['font.sans-serif']=['Hiragino Sans GB'] # 修改字体
plt.rcParams['axes.unicode_minus'] = False # 正常显示负号



def func(x):
    return -0.8 * (x - 3.8)**2 + 7

# Define the interval [a, b]
a = 1.0
b = 5.0

# --- Plot 1 ---
n_plot1 = 4  # 4份
x_pts_plot1 = np.linspace(a, b, n_plot1 + 1)
y_pts_plot1 = func(x_pts_plot1)

x_curve = np.linspace(a, b, 200) # Smooth curve
y_curve = func(x_curve)

fig1, ax1 = plt.subplots(figsize=(8, 6))

# Plot the smooth curve
ax1.plot(x_curve, y_curve, 'k-')

# Plot the points on the curve
ax1.plot(x_pts_plot1, y_pts_plot1, 'ko', markersize=5)

# Set up axes (spines)
ax1.spines['left'].set_position('zero')
ax1.spines['bottom'].set_position('zero')
ax1.spines['right'].set_color('none')
ax1.spines['top'].set_color('none')
ax1.xaxis.set_ticks_position('bottom')
ax1.yaxis.set_ticks_position('left')

# Set plot limits (do this before placing arrows at ends of axes)
xlim1 = (-1, b + 2.5)
ylim1 = (-1, func(3.8) + 2.5) # func(3.8) is the peak
ax1.set_xlim(xlim1)
ax1.set_ylim(ylim1)

# Arrows for axes
ax1.plot(xlim1[1], 0, ">k", clip_on=False, markersize=7) # x-axis arrow
ax1.plot(0, ylim1[1], "^k", clip_on=False, markersize=7) # y-axis arrow

# Labels for axes
ax1.set_xlabel('x', loc='right', fontsize=14)
ax1.set_ylabel('y', loc='top', rotation=0, fontsize=14, labelpad=-20) # Adjust labelpad for y

# Origin 'O'
ax1.text(-0.2, -0.25, 'O', fontsize=14, ha='right', va='top')

# Vertical lines from x-axis to f(a) and f(b)
ax1.plot([a, a], [0, func(a)], 'k-')
ax1.plot([b, b], [0, func(b)], 'k-')

# X-axis ticks and labels
ax1.set_xticks([]) # Remove default ticks
ax1.text(a, -0.15, 'a', ha='center', va='top', fontsize=12)
ax1.text(b, -0.15, 'b', ha='center', va='top', fontsize=12)

# Plot points on x-axis for divisions and Δx labels
delta_x_val = (b - a) / n_plot1
for i in range(n_plot1):
    ax1.plot(x_pts_plot1[i], 0, 'ko', markersize=3)
    ax1.text(a + i * delta_x_val + delta_x_val / 2, -0.15, 'Δx', ha='center', va='top', fontsize=11)
ax1.plot(x_pts_plot1[n_plot1], 0, 'ko', markersize=3) # Last point 'b'

# Y-axis: remove default ticks
ax1.set_yticks([])

# Labels for f(a) and f(b)
ax1.text(a - 0.1, func(a) + 0.1, 'f(a)', ha='right', va='bottom', fontsize=12)
ax1.text(b + 0.05, func(b) + 0.1, 'f(b)', ha='left', va='bottom', fontsize=12)

# Horizontal line from (a, f(a)) to (b, f(a))
ax1.plot([a, b], [func(a), func(a)], 'k-')

# Step-like structure
for i in range(n_plot1):
    ax1.plot([x_pts_plot1[i], x_pts_plot1[i+1]], [y_pts_plot1[i], y_pts_plot1[i]], 'k-') # Horizontal
    ax1.plot([x_pts_plot1[i+1], x_pts_plot1[i+1]], [y_pts_plot1[i], y_pts_plot1[i+1]], 'k-') # Vertical

# Δy label (near the second step, as in image)
idx_delta_y = 1
x_mid_delta_y = x_pts_plot1[idx_delta_y+1] + 0.15
y_mid_delta_y = (y_pts_plot1[idx_delta_y] + y_pts_plot1[idx_delta_y+1]) / 2
ax1.text(x_mid_delta_y, y_mid_delta_y, 'Δy', ha='left', va='center', fontsize=12)

# Text annotations within the plot
text1_plot1 = "把区间[a,b]均分成4份,"
text2_plot1 = "整体等于部分之和, 所以 $f(b)-f(a) = \\Sigma \\Delta y$"
ax1.text(0.22, 0.92, text1_plot1, transform=ax1.transAxes, fontsize=12, ha='left', va='top')
ax1.text(0.22, 0.84, text2_plot1, transform=ax1.transAxes, fontsize=12, ha='left', va='top')

# Equation label on the right
y_center_sum_label_plot1 = (func(a) + func(b)) / 2
ax1.text(b + 0.2, y_center_sum_label_plot1, '$f(b)-f(a) = \\Sigma \\Delta y$', ha='left', va='center', fontsize=12)

plt.title("(a)") # Optional title for clarity
plt.show()


# --- Plot 2 ---
n_plot2 = 20  # "均分到最细" (many divisions)
x_pts_plot2 = np.linspace(a, b, n_plot2 + 1)
y_pts_plot2 = func(x_pts_plot2)

fig2, ax2 = plt.subplots(figsize=(8, 6))

# Plot the smooth curve (as a guide, points will be dominant)
ax2.plot(x_curve, y_curve, 'k-', alpha=0.5) # Lighter or thinner if needed

# Plot the many points on the curve
ax2.plot(x_pts_plot2, y_pts_plot2, 'ko', markersize=3) # Smaller dots

# Set up axes (spines)
ax2.spines['left'].set_position('zero')
ax2.spines['bottom'].set_position('zero')
ax2.spines['right'].set_color('none')
ax2.spines['top'].set_color('none')
ax2.xaxis.set_ticks_position('bottom')
ax2.yaxis.set_ticks_position('left')

# Set plot limits
xlim2 = (-1, b + 2.8) # Slightly more space for label on right
ylim2 = (-1, func(3.8) + 2.8)
ax2.set_xlim(xlim2)
ax2.set_ylim(ylim2)

# Arrows for axes
ax2.plot(xlim2[1], 0, ">k", clip_on=False, markersize=7)
ax2.plot(0, ylim2[1], "^k", clip_on=False, markersize=7)

# Labels for axes
ax2.set_xlabel('x', loc='right', fontsize=14)
ax2.set_ylabel('y', loc='top', rotation=0, fontsize=14, labelpad=-20)

# Origin 'O'
ax2.text(-0.2, -0.25, 'O', fontsize=14, ha='right', va='top')

# Vertical lines from x-axis to f(a) and f(b)
ax2.plot([a, a], [0, func(a)], 'k-')
ax2.plot([b, b], [0, func(b)], 'k-')

# X-axis ticks and labels 'a', 'b'
ax2.set_xticks([])
ax2.text(a, -0.15, 'a', ha='center', va='top', fontsize=12)
ax2.text(b, -0.15, 'b', ha='center', va='top', fontsize=12)

# dx representation on x-axis (many small dots)
for x_val in x_pts_plot2:
    ax2.plot(x_val, 0, 'ko', markersize=2)

# Label for 'dx' below the x-axis (first interval)
dx_val_plot2 = (b-a)/n_plot2
ax2.text(a + dx_val_plot2 / 2, -0.15, 'dx', ha='center', va='top', fontsize=11)

# Labels for f(a) and f(b)
ax2.text(a - 0.1, func(a) + 0.1, 'f(a)', ha='right', va='bottom', fontsize=12)
ax2.text(b + 0.05, func(b) + 0.1, 'f(b)', ha='left', va='bottom', fontsize=12)

# Horizontal line from (a, f(a)) to (b, f(a))
ax2.plot([a, b], [func(a), func(a)], 'k-')

# Text annotations within the plot
text1_plot2 = "把区间[a,b]均分到最细,"
text2_plot2 = "即间隔为dx, 对应的Δy也变成了dy"
text3_plot2 = "所以 $f(b)-f(a) = \\Sigma dy$"
ax2.text(0.22, 0.92, text1_plot2, transform=ax2.transAxes, fontsize=12, ha='left', va='top')
ax2.text(0.22, 0.84, text2_plot2, transform=ax2.transAxes, fontsize=12, ha='left', va='top')
ax2.text(0.22, 0.76, text3_plot2, transform=ax2.transAxes, fontsize=12, ha='left', va='top')

# Equation label on the right
y_center_sum_label_plot2 = (func(a) + func(b)) / 2
ax2.text(b + 0.2, y_center_sum_label_plot2, '$f(b)-f(a) = \\Sigma dy$', ha='left', va='center', fontsize=12)

plt.title("(b)") # Optional title
plt.show()

在这里插入图片描述
在这里插入图片描述
通俗的表示牛顿莱布尼茨公式的意义
∫ a b f ( x ) d x = f ( ξ ) ( b − a ) = F ′ ( ξ ) ( b − a ) = F ( b ) − F ( a ) \int_a^bf(x)dx=f(\xi)(b-a)=F'(\xi)(b-a)=F(b)-F(a) abf(x)dx=f(ξ)(ba)=F(ξ)(ba)=F(b)F(a)
积分中值定理: ∫ a b f ( x ) d x = f ( ξ ) ( b − a ) \int_a^bf(x)dx=f(\xi)(b-a) abf(x)dx=f(ξ)(ba)
微分中值定理: F ′ ( ξ ) ( b − a ) = F ( b ) − F ( a ) F'(\xi)(b-a)=F(b)-F(a) F(ξ)(ba)=F(b)F(a)

小试牛刀

  1. ∫ 0 π 2 ( 2 c o s x + s i n x − 1 ) d x \int_0^{\frac{\pi}{2}}(2cosx+sinx-1)dx 02π(2cosx+sinx1)dx
    解: = [ 2 s i n x − c o s x − x ] 0 π 2 = 3 − π 2 =[2sinx - cosx - x]_0^{\frac{\pi}{2}}=3-\frac{\pi}{2} =[2sinxcosxx]02π=32π

  2. f ( x ) = { 2 x , 0 ≤ x ≤ 1 5 , 1 < x ≤ 2 f(x)=\begin{cases} 2x, 0 \le x \le 1\\ 5, 1 \lt x \le 2 \end{cases} f(x)={2x,0x15,1<x2, 求 ∫ 0 2 f ( x ) d x \int_0^2f(x)dx 02f(x)dx
    解: = ∫ 0 1 2 x d x + ∫ 1 2 5 d x = x 2 ∣ 0 1 + 5 x ∣ 1 2 = 1 + 5 = 6 =\int_0^12xdx+\int_1^25dx=x^2|_0^1+5x|_1^2 = 1 + 5 = 6 =012xdx+125dx=x201+5x12=1+5=6

Python求定积分

机器解定积分思想

牛顿莱布尼茨公式 ∫ a b f ( x ) d x = F ( b ) − F ( a ) \int_a^bf(x)dx = F(b) - F(a) abf(x)dx=F(b)F(a)求定积分的值, 不论在理论还是实际都具有重要的作用, 但是不能解决所有问题, 例如被积函数的原函数很难用初等函数表达, 或者原函数表达式过于复杂, 导致了这种方式的局限性, 机器积分求解过程可以分为下面几个步骤, 根据 ∫ a b f ( x ) d x = lim ⁡ λ → 0 ∑ i = 1 n f ( ξ i ) Δ x i \int_a^bf(x)dx=\lim_{\lambda \to 0}\sum_{i=1}^nf(\xi_i)\Delta x_i abf(x)dx=limλ0i=1nf(ξi)Δxi

  1. 分割, a = x 0 < x 1 < x 2 < . . . < x n = b a = x_0 < x_1 < x_2 <... <x_n = b a=x0<x1<x2<...<xn=b
  2. 近似, Δ S i ≈ f ( x i i ) Δ x i \Delta S_i \approx f(xi_i)\Delta x_i ΔSif(xii)Δxi, ξ i ∈ [ x i − 1 , x i ] \xi_i \in [x_{i-1}, x_i] ξi[xi1,xi], Δ x i = x i − x i − 1 , i = 1 , 2 , . . . , n \Delta x_i = x_i - x_{i-1}, i=1,2,...,n Δxi=xixi1,i=1,2,...,n
  3. 求和, ∑ i = 1 n f ( ξ i ) Δ x i \sum_{i=1}^nf(\xi_i)\Delta x_i i=1nf(ξi)Δxi
  4. 求极限, lim ⁡ λ → 0 ∑ i = 1 n f ( ξ i ) Δ x i \lim_{\lambda \to 0} \sum_{i=1}^nf(\xi_i)\Delta x_i limλ0i=1nf(ξi)Δxi

求解过程为计算机求解提供思路, 将求解区间分为 n n n份, 步长为 b − a n \frac{b-a}{n} nba, 循环 n n n次求解 n n n个小梯形的面积之和就是定积分近似解

牛刀小试

编写程序求 ∫ 0 2 x 2 d x \int_0^2x^2dx 02x2dx

import numpy as np
from scipy.integrate import dblquad

def func(x):
    # np.exp 为 e 的指定次幂
    return x ** 2


def trape(func, n, a, b):
    """
    :param func: 原函数
    :param n: 分为多少份计算
    :param a: 积分下限
    :param b: 积分上限
    :return:
    """
    # 计算步长
    h = (b - a) / n
    sum = 0
    for i in range(1, n + 1):
        x0 = a + (i - 1) * h # 计算第i个梯形的底边x0
        x1 = a + i * h  # 计算第i个梯形的顶边x1
        # 计算梯形面积 (底边(y=f(x0)) + 顶边y=f(x1)) * h /2
        sum += (func(x0) + func(x1)) * h / 2

    return sum



print(trape(func, 2, 0, 3))
# 10.125
print(trape(func, 20, 0, 3))
# 9.01125
print(trape(func, 200, 0, 3))
# 9.0001125
print(trape(func, 2000, 0, 3))
# 9.000001125000004
print(trape(func, 20000, 0, 3))
# 9.000000011250007
print(trape(func, 200000, 0, 3))
# 9.000000000112504

函数介绍

quad

入参

  • func: 积分函数
  • a: 积分下限
  • b: 积分上限

出参

  • 积分值
  • 误差
dblquad

入参

  • func: 积分函数
  • a: x的下限
  • b: x的上限
  • gfun: 变量y的下限
  • hfun: 变量y的上限

出参

  • 积分值
  • 误差

题目列表

  1. ∫ 0 3 c o s 2 ( e x ) d x \int_0^3cos^2(e^x)dx 03cos2(ex)dx
import numpy as np
from scipy.integrate import quad


def func(x):
    # np.exp 为 e 的指定次幂
    return np.cos(np.e ** x) ** 2


print(quad(func, 0, 3))

"""output:
积分值, 误差
(1.296467785724373, 1.3977970832667816e-09)
"""
  1. ∫ ∫ x y e − x 2 − y 2 d x d y \int\int_x^y e^{-x^2-y^2}dxdy xyex2y2dxdy, 其中 D = { ( x , y ) ∣ 0 ≤ x ≤ 10 , 0 ≤ y ≤ 10 } D=\{(x, y)| 0\le x \le 10, 0 \le y \le 10\} D={(x,y)∣0x10,0y10}
import numpy as np
from scipy.integrate import dblquad


def func(x, y):
    # np.exp 为 e 的指定次幂
    return np.exp(-x** 2 - y ** 2)

x_a = 0
x_b = 10
y_a = 0
y_b = 10

print(dblquad(func, x_a, x_b, lambda y: y_a, lambda y: y_b))

"""output:
积分值, 误差
(0.7853981633974476, 1.3753098510206357e-08)
"""

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/2380503.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

2025年渗透测试面试题总结-华顺信安[实习]安全服务工程师(题目+回答)

网络安全领域各种资源&#xff0c;学习文档&#xff0c;以及工具分享、前沿信息分享、POC、EXP分享。不定期分享各种好玩的项目及好用的工具&#xff0c;欢迎关注。 目录 华顺信安[实习]安全服务工程师 1. 自我介绍 2. 红蓝队经验 3. Shiro漏洞知识体系 4. APP渗透测试方法…

掌握Git:版本控制与高效协作指南

一、初始Git 提出问题&#xff1a;无论是在工作还是学习&#xff0c;我们在编写各种文档的时候&#xff0c;更改失误&#xff0c;失误后恢复到原来版本&#xff0c;不得不复制出一个副本。 每个版本由各自的内容&#xff0c;但最终只有一个报告需要被我们使用。 但在此之前的…

VsCode和AI的前端使用体验:分别使用了Copilot、通义灵码、iflyCode和Trae

1、前言 大杂烩~每次开发一行代码&#xff0c;各个AI争先恐后抢着提供帮助 备注&#xff1a;四款插件都需要先去官网注册账号&#xff0c;安装好之后有个账号验证。 2、插件详解 2.1、AI分析的答案 GitHub Copilot 定位&#xff1a;老牌 AI 代码补全工具&#xff0c;深度集成…

交叉熵损失函数,KL散度, Focal loss

目录 交叉熵损失函数&#xff08;Cross-Entropy Loss&#xff09; 二分类交叉熵 多分类交叉熵 KL散度&#xff08;Kullback-Leibler Divergence) 交叉熵损失函数和KL散度总结 Focal loss Focal loss 和 交叉熵损失函数 的区别 交叉熵损失函数&#xff08;Cross-Entropy…

【Part 3 Unity VR眼镜端播放器开发与优化】第一节|基于Unity的360°全景视频播放实现方案

《VR 360全景视频开发》专栏 将带你深入探索从全景视频制作到Unity眼镜端应用开发的全流程技术。专栏内容涵盖安卓原生VR播放器开发、Unity VR视频渲染与手势交互、360全景视频制作与优化&#xff0c;以及高分辨率视频性能优化等实战技巧。 &#x1f4dd; 希望通过这个专栏&am…

IDEA连接github(上传项目)

【前提&#xff1a;菜鸟学习的记录过程&#xff0c;如果有不足之处&#xff0c;还请各位大佬大神们指教&#xff08;感谢&#xff09;】 1.先配置好git环境。 没配置的小伙伴可以看上一篇文章教程。 安装git&#xff0c;2.49.0版本-CSDN博客 2.在idea设置git 打开IDEA设置-…

重构研发效能:项目管理引领软件工厂迈向智能化

1.项目管理智能化&#xff0c;激活软件工厂新引擎 在高速发展的软件开发时代&#xff0c;企业如何高效管理多个项目、协调团队合作、优化资源配置&#xff0c;已成为推动技术进步的关键。尤其是在多任务、多项目并行的复杂环境下&#xff0c;智能项目组合管理工具正成为软件工…

Vue3 中使用 provide/inject 实现跨层级组件传值失败的原因及解决方案

1、基础用法 父组件&#xff1a; <script setup> import { ref, provide } from vue; import ChildComponent from ./ChildComponent.vue; const parentData ref(初始数据); // 提供数据 provide(parentData, parentData); </script>子组件&#xff1a; <sc…

小白的进阶之路系列之二----人工智能从初步到精通pytorch中分类神经网络问题详解

什么是分类问题? 分类问题涉及到预测某物是一种还是另一种。 例如,你可能想要: 问题类型具体内容例子二元分类目标可以是两个选项之一,例如yes或no根据健康参数预测某人是否患有心脏病。多类分类目标可以是两个以上选项之一判断一张照片是食物、人还是狗。多标签分类目标…

Vue3——Pinia

目录 什么是 Pinia&#xff1f; 为什么选择 Pinia&#xff1f; 基本使用 安装pinia 配置pinia 定义store 使用 持久化插件 什么是 Pinia&#xff1f; Pinia 是一个轻量级的状态管理库&#xff0c;专为 Vue 3 设计。它提供了类似 Vuex 的功能&#xff0c;但 API 更加简…

02 基本介绍及Pod基础排错

01 yaml文件里的字段错误 # 多打了一个i导致的报错 [rootmaster01 yaml]# cat 01-pod.yaml apiVersion: v1 kind: Pod metadata:name: likexy spec:contaiiners:- name: aaaimage: registry.cn-hangzhou.aliyuncs.com/yinzhengjie-k8s/apps:v1 [rootmaster01 yaml]# kubectl …

⼆叉搜索树详解

1. ⼆叉搜索树的概念 ⼆叉搜索树⼜称⼆叉排序树&#xff0c;它或者是⼀棵空树&#xff0c;或者是具有以下性质的⼆叉树: • 若它的左⼦树不为空&#xff0c;则左⼦树上所有结点的值都⼩于等于根结点的值 • 若它的右⼦树不为空&#xff0c;则右⼦树上所有结点的值都⼤于等于根结…

如何使用通义灵码提高前端开发效率

工欲善其事&#xff0c;必先利其器。对于前端开发而言&#xff0c;使用VSCode已经能够极大地提高前端的开发效率了。但有了AI加持后&#xff0c;前端开发的效率又更上一层楼了&#xff01; 本文采用的AI是通义灵码插件提供的通义千问大模型&#xff0c;是目前AI性能榜第一梯队…

Android Studio Kotlin 中的方法添加灰色参数提示

在使用 Android Studio 时&#xff0c; 我发现使用 Java 编写方法后在调用方法时&#xff0c; 会自动显示灰色的参数。 但在 Kotlin 中没有显示&#xff0c; 于是找了各种方法最后找到了设置&#xff0c; 并且以本文章记录下来。 博主博客 https://blog.uso6.comhttps://blog.…

TCP协议简介

TCP 协议 TCP&#xff08;Transmission Control Protocol&#xff0c;传输控制协议&#xff09;是互联网协议套件中的核心协议之一&#xff0c;位于传输层。它提供了一种可靠的、面向连接的、基于字节流的数据传输服务。TCP 的主要特点是确保数据在传输过程中不丢失、不重复&a…

Linux学习心得问题整理(二)

day05 Linux基础入门 Linux语法解析 如何理解ssh远程连接?如何使用ssh使用远程连接服务&#xff1f; ssh进也称远程服务终端&#xff0c;常见连接方式可以包括windows和Linux两种方式 首先咱们使用windows窗口进行连接&#xff0c;这里就采用xshell连接工具来给大家做演示吧…

SOC-ESP32S3部分:2-2-VSCode进行编译烧录

飞书文档https://x509p6c8to.feishu.cn/wiki/CTzVw8p4LiaetykurbTciA42nBf?fromScenespaceOverview 无论是使用Window搭建IDF开发环境&#xff0c;还是使用Linux Ubuntu搭建IDF开发环境&#xff0c;我们都建议使用VSCode进行代码编写和编译&#xff0c;VSCode界面友好&#x…

Python虚拟环境再PyCharm中自由切换使用方法

Python开发中的环境隔离是必不可少的步骤,通过使用虚拟环境可以有效地管理不同项目间的依赖,避免包冲突和环境污染。虚拟环境是Python官方提供的一种独立运行环境,每个项目可以拥有自己单独的环境,不同项目之间的环境互不影响。在日常开发中,结合PyCharm这样强大的IDE进行…

使用Mathematica绘制一类矩阵的特征值图像

学习过线性代数的&#xff0c;都知道&#xff1a;矩阵的特征值非常神秘&#xff0c;但却携带着矩阵的重要信息。 今天&#xff0c;我们将展示&#xff1a;一类矩阵&#xff0c;其特征值集体有着很好的分布特征。 modifiedroots[c_List] : Block[{a DiagonalMatrix[ConstantAr…

SpringBoot-6-在IDEA中配置SpringBoot的Web开发测试环境

文章目录 1 环境配置1.1 JDK1.2 Maven安装配置1.2.1 安装1.2.2 配置1.3 Tomcat1.4 IDEA项目配置1.4.1 配置maven1.4.2 配置File Encodings1.4.3 配置Java Compiler1.4.4 配置Tomcat插件2 Web开发环境2.1 项目的POM文件2.2 项目的主启动类2.3 打包为jar或war2.4 访问测试3 附录3…