离散数学-ch1-Introduction

1. Overview

  1. References

Stanford CS103, https://web.stanford.edu/class/cs103

NYU G22.2390-001, https://cvc4.cs.stanford.edu/logic/ • CMU CDM http://www.cs.cmu.edu/~cdm/

• UB CS70 http://inst.eecs.berkeley.edu/~cs70/fa16/
• CMU-CS122 https://www.cs.cmu.edu/~iliano/courses/17F-CMU-CS122/

Stanford CS103, https://web.stanford.edu/class/cs103

• CMU 15-453 https://www.cs.cmu.edu/~fp/courses/flac/
• Columbia, COMS W3261, http://www.cs.columbia.edu/~aho/cs3261/ • IITJodhpur,CS222,http://krchowdhary.com/toc/cs222.html
• 南京大学离散数学课程

  1. To Be Distinguished, You Need To

Take

  • ✓ Lectures

  • ✓ Recitation (Optional)

    Do

  • ✓ 3 Labs

  • ✓ Preliminary Questions

  • ✓ Homework

    Pass
    ✓ Quiz

    ✓ Finalexam

Grading Breakdown

  • Others 20%
  • Lab 20%
  • Quiz 20%
  • Final 40%

Faculty Information

网站

Website:

http://ipads.se.sjtu.edu.cn/courses/cdm

Canvas:

https://oc.sjtu.edu.cn/courses/24410

形式化验证网站:

https://rise4fun.com/Dafny/tutorial

Three Parts of CDM(*)

Part I. Reasoning. (8 ~ 9 Weeks)

How to prove the correctness?

Part II. Computability. (~ 6 Weeks)
Is the problem computable (solvable)?

Part III. Probability. (~1 Weeks)

How does computer solve continuous problem? (Underneath the ML)

Textbooks

《数理逻辑与集合论》第2版 • 石纯一 著,清华大学出版社

John E. Hopcroft, Rajeev Motwani and Jeffrey D. Ullman, Introduction to Automata Theory, Languages, and Computation, Pearson, 2001

移位运算符

左移(<<)

i = i << n ; 相当于 i = i * (2 ^ n )

右移(>>)

i = i >> n ; 相当于 i = i / ( 2 ^ n )

位运算符 与(&)运算符 异或^

&

位操作中的与操作运算符。也就是常说的and操作,双目运算符。
计算的时候按位计算,&两边操作数对应位上全为1时,结果的该位值为1。否则该位值为0
比如0x12&0x23 转为二进制为:B00010010&B00100011,按位计算结果为B00000010,
即结果为0x02

^

两个二进制操作数对应位相同为0,不同为1;

异或交换取值
在这里插入图片描述

void swap(int a, int b)
{
	a ^= b;
	b ^= a; 
	a ^= b;
}

参考:

https://blog.csdn.net/mofeigege/article/details/106304076?ops_request_misc=%257B%2522request%255Fid%2522%253A%2522159995841819725222400123%2522%252C%2522scm%2522%253A%252220140713.130102334…%2522%257D&request_id=159995841819725222400123&biz_id=0&utm_medium=distribute.pc_search_result.none-task-blog-2alltop_click~default-1-106304076.first_rank_ecpm_v3_pc_rank_v2&utm_term=位运算符&spm=1018.2118.3001.4187

https://jingyan.baidu.com/article/a3f121e4919494fc9052bb0f.html

question

Three Parts of CDM CDM:computer Discrete Mathematics? Yes

(Underneath the ML):Machine Learning? Yes

形式化验证举例:

method clone(n: nat) returns (b : nat)
ensures b == n
{
var i := 0;
while i < n
invariant 0 <= i && i <= n
{
i := i + 1;
}
return i; }

本课词汇

1.Propositional 命题

2.semantic 语义的

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值