<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Posts on Chen's Blog</title><link>https://NamiChen.github.io/posts/</link><description>Recent content in Posts on Chen's Blog</description><generator>Hugo -- gohugo.io</generator><language>en</language><copyright>This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.</copyright><lastBuildDate>Mon, 07 Jun 2021 00:00:00 +0000</lastBuildDate><atom:link href="https://NamiChen.github.io/posts/index.xml" rel="self" type="application/rss+xml"/><item><title>从此刻开始</title><link>https://NamiChen.github.io/2021/%E4%BB%8E%E6%AD%A4%E5%88%BB%E5%BC%80%E5%A7%8B/</link><pubDate>Mon, 07 Jun 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/%E4%BB%8E%E6%AD%A4%E5%88%BB%E5%BC%80%E5%A7%8B/</guid><description/></item><item><title>国学经典阅读顺序</title><link>https://NamiChen.github.io/2021/chinese-classics-reading-order/</link><pubDate>Wed, 19 May 2021 17:16:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/chinese-classics-reading-order/</guid><description>&lt;p>国学经典阅读顺序，摘自百度文库。&lt;/p></description></item><item><title>经济学常识-缴税</title><link>https://NamiChen.github.io/2021/pay-taxes/</link><pubDate>Fri, 07 May 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/pay-taxes/</guid><description>&lt;p>经济是每个人都躲不开的东西，作为普通人，搞懂一些生活中的经济常识，能帮助我们活得更明白一点，这些知识包括缴税、理财、买房、养老、生育、贷款等等，都是与每个人息息相关的。本篇学习缴税。&lt;/p></description></item><item><title>穿搭整理4-基于Notion的实物管理</title><link>https://NamiChen.github.io/2021/minimalism-and-data-notion-based-management-ideas/</link><pubDate>Mon, 03 May 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/minimalism-and-data-notion-based-management-ideas/</guid><description>和很多人一样，我的整理收纳之旅也是从《砰然心动的人生整理魔法》这本书开始的，但是慢慢的，这件事就变成了一种打发无聊时间和释放压力的手段，甚至</description></item><item><title>Keep手环B2会员版</title><link>https://NamiChen.github.io/2021/keep-bracelet-b2-member-version-review/</link><pubDate>Mon, 26 Apr 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/keep-bracelet-b2-member-version-review/</guid><description>&lt;p>入手渠道：Keep商城&lt;/p>
&lt;p>参考价格：108 元（手环独立售价 99 元 + 首月会员 9 元）&lt;/p></description></item><item><title>2018-2021 研究历史</title><link>https://NamiChen.github.io/2021/2018-2020-research-history/</link><pubDate>Thu, 22 Apr 2021 09:06:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/2018-2020-research-history/</guid><description>本文总结2018年12月到2021年4月的研究工作历史，不包括论文阅读工作。 2018.12 区块链主流共识算法收集了解和分析 IIoT 与区块链结合的场景收集和一些</description></item><item><title>历次和老师讨论的一些问题总结</title><link>https://NamiChen.github.io/2021/summary-of-issues-discussed-with-the-teacher/</link><pubDate>Wed, 21 Apr 2021 11:06:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/summary-of-issues-discussed-with-the-teacher/</guid><description>&lt;p>每周会议摘要及老师提到的一些问题总结。&lt;/p></description></item><item><title>力量训练</title><link>https://NamiChen.github.io/2021/strength-training/</link><pubDate>Mon, 12 Apr 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/strength-training/</guid><description>&lt;p>力量训练的作用、原理，制定和执行计划的注意事项，常见的力量训练动作。。&lt;/p></description></item><item><title>五种减脂运动</title><link>https://NamiChen.github.io/2021/five-types-of-fat-loss-exercises/</link><pubDate>Thu, 08 Apr 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/five-types-of-fat-loss-exercises/</guid><description>&lt;p>流行的五种减脂运动：低强度恒速有氧、空腹有氧、HIIT、减脂力量训练、循环训练。来自书籍《本能减脂》。&lt;/p></description></item><item><title>热身及拉伸</title><link>https://NamiChen.github.io/2021/warm-up-and-stretch/</link><pubDate>Sun, 04 Apr 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/warm-up-and-stretch/</guid><description>&lt;p>介绍热身与拉伸的相关知识，来自书籍《本能减脂》。&lt;/p></description></item><item><title>运动解剖学学习笔记3-四肢</title><link>https://NamiChen.github.io/2021/notes-on-sports-anatomy-4/</link><pubDate>Wed, 31 Mar 2021 21:05:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/notes-on-sports-anatomy-4/</guid><description>&lt;p>这一篇主要认识手臂和腿部的肌肉和骨骼。&lt;/p></description></item><item><title>书藏的生活周刊第 15 期 (20210328)</title><link>https://NamiChen.github.io/2021/life-weekly-15/</link><pubDate>Sun, 28 Mar 2021 14:32:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/life-weekly-15/</guid><description>&lt;p>本周刊目的是记录生活，发现生活中的美好，当前为第十五期。&lt;/p></description></item><item><title>运动解剖学学习笔记2-躯干</title><link>https://NamiChen.github.io/2021/notes-on-sports-anatomy-2/</link><pubDate>Thu, 25 Mar 2021 21:17:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/notes-on-sports-anatomy-2/</guid><description>&lt;p>本篇认识躯干部分的骨骼和肌肉，包括脊柱、骨盆、肩胛骨，以及肩、胸、腹部的肌肉。&lt;/p></description></item><item><title>图片知识一文知</title><link>https://NamiChen.github.io/2021/picture-knowledge/</link><pubDate>Tue, 23 Mar 2021 15:32:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/picture-knowledge/</guid><description>&lt;p>由于博客的原因，每周都需要进行图片处理，所以这里对相关知识做一个总结，包括图片格式、图片压缩的原理、水印、工具、最合适的大小等等。&lt;/p></description></item><item><title>运动解剖学学习笔记1-基础知识</title><link>https://NamiChen.github.io/2021/notes-on-sports-anatomy-1/</link><pubDate>Mon, 22 Mar 2021 20:01:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/notes-on-sports-anatomy-1/</guid><description>&lt;p>Keep的健身时长已经超过了一万六千分钟， 但各种健身的知识还是零零散散的状态，没有什么太大的作用，而且随着软件逐渐变得不好用，也意识到了依赖某个工具并不是太好的选择，最终决定系统的学一次，查漏补缺，然后把所有的知识串起来，基本目标就是不需要软件协助也知道自己应该干什么，以及知道做某件事原理到底是什么。&lt;/p></description></item><item><title>书藏的生活周刊第 14 期 (20210321)</title><link>https://NamiChen.github.io/2021/life-weekly-14/</link><pubDate>Sun, 21 Mar 2021 15:01:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/life-weekly-14/</guid><description>&lt;p>本周刊目的是记录生活，发现生活中的美好，当前为第十四期。&lt;/p></description></item><item><title>网络小说防沉迷之以理解上瘾机制结束</title><link>https://NamiChen.github.io/2021/the-exploration-of-quit-novels-ends-with-understanding-the-mechanism-of-addiction/</link><pubDate>Wed, 17 Mar 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/the-exploration-of-quit-novels-ends-with-understanding-the-mechanism-of-addiction/</guid><description>&lt;p>八年的看小说经历，其实不是想放下就能放下的，身体好似已经形成了本能，一旦闲下来，脑子还没过，手就自己拿起手机打开了小说网站，所以为了进一步的解决这种问题，我打算充分的理解上瘾的生理和心理学机制，从中寻找相关的解决办法。由于查阅到的文献一般用成瘾这个词，但在科普书籍和我们生活中使用上瘾一词则较多，所以本文可能会同时出现两种描述。&lt;/p></description></item><item><title>书藏的生活周刊第 13 期 (20210313)</title><link>https://NamiChen.github.io/2021/life-weekly-13/</link><pubDate>Sat, 13 Mar 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/life-weekly-13/</guid><description>&lt;p>本周刊目的是记录生活，发现生活中的美好，当前为第十三期。&lt;/p></description></item><item><title>硕士论文的格式</title><link>https://NamiChen.github.io/2021/masters-thesis-format/</link><pubDate>Mon, 08 Mar 2021 11:00:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/masters-thesis-format/</guid><description>&lt;p>当一个同学问我论文格式问题时，我欣然应允，当两个、三个同学问我论文格式问题时，我意识到了什么，当预答辩的老师在那里说着“你们不会比对着学校的格式要求一个一个看吗”的时候，我终于恍然大悟，啥，就那个写的不清不楚的东西？所以我打算自己整理一份Word 版论文格式要求，以硕士论文模板为基础，补充一些缺失细节的同时，给出在 Word 中进行这些格式设置的方法。不使用 LaTeX 的原因主要是学校要求最后的提交版本是 doc 或 docx 格式，而 LaTeX 转 word 总不能尽善尽美。&lt;/p>
&lt;p>为了描述方便，我们先声明 word 中几个区域的标准叫法，如下图所示，智能搜索框的作用在于将多步点击简化为一步搜索。&lt;/p>
&lt;p>&lt;figure>&lt;img src="https://NamiChen.github.io/svg/loading.min.svg" data-sizes="auto" data-src="https://picped-1301226557.cos.ap-beijing.myqcloud.com/YJS_20210308_word%e7%95%8c%e9%9d%a2.png" alt="" class="lazyload">&lt;/figure>&lt;/p></description></item><item><title>闲时待办</title><link>https://NamiChen.github.io/2021/to-do-in-free-time/</link><pubDate>Sat, 06 Mar 2021 19:08:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/to-do-in-free-time/</guid><description>&lt;p>未来或闲时可以做的事&lt;/p></description></item><item><title>理想的工作日时间安排</title><link>https://NamiChen.github.io/2021/ideal-daily-schedule/</link><pubDate>Sat, 06 Mar 2021 17:16:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/ideal-daily-schedule/</guid><description>&lt;p>理想的工作日时间安排，可根据此安排灵活调整&lt;/p></description></item><item><title>毕业前的待办</title><link>https://NamiChen.github.io/2021/todo-before-graduate/</link><pubDate>Sat, 06 Mar 2021 08:57:00 +0800</pubDate><guid>https://NamiChen.github.io/2021/todo-before-graduate/</guid><description>&lt;p>整理毕业前要做的事。&lt;/p></description></item><item><title>书藏的生活周刊第 12 期 (20210306)</title><link>https://NamiChen.github.io/2021/life-weekly-12/</link><pubDate>Sat, 06 Mar 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/life-weekly-12/</guid><description>&lt;p>本周刊目的是记录生活，发现生活中的美好，当前为第十二期。&lt;/p></description></item><item><title>网络小说防沉迷之从提高审美能力开始</title><link>https://NamiChen.github.io/2021/the-exploration-of-quit-novels-begins-with-understanding-the-core-of-the-novel/</link><pubDate>Sat, 27 Feb 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/the-exploration-of-quit-novels-begins-with-understanding-the-core-of-the-novel/</guid><description>2020 年，中国的网文用户达到了近 4.7 亿1，阅读网络小说已经成为一种普遍性的社会现象，但这也意味着，任何的影响，在如此巨大的用户数量的扩大下，都会成</description></item><item><title>生活技能-春节习俗记录</title><link>https://NamiChen.github.io/2021/life-skills-spring-festival-customs-record/</link><pubDate>Sat, 20 Feb 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/life-skills-spring-festival-customs-record/</guid><description>最近几年人们总说年味儿越来越淡，我却很少有这种感觉。确实，随着时代发展，本来只会在大年夜吃到的大餐平时想吃就吃，本来过年时令我们激动不已的新</description></item><item><title>科研基础3-伪代码规范</title><link>https://NamiChen.github.io/2021/pseudocode-specification/</link><pubDate>Mon, 18 Jan 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/pseudocode-specification/</guid><description>&lt;p>论文的编辑要插入两段伪代码，这里总结一下伪代码书写用到的 LaTeX 包和书写规范。&lt;/p></description></item><item><title>上瘾</title><link>https://NamiChen.github.io/2021/addicted/</link><pubDate>Thu, 14 Jan 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/addicted/</guid><description>当我们处于压力或无聊的心理状态中的时候，就会想要寻求一些即时的缓解，而这些消遣手段却总是让我们陷入更糟糕的状态。所以，我们需要集中在积极而有</description></item><item><title>健身的理论框架及基础知识</title><link>https://NamiChen.github.io/2021/theoretical-framework-and-basic-knowledge-of-fitness/</link><pubDate>Mon, 11 Jan 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/theoretical-framework-and-basic-knowledge-of-fitness/</guid><description>&lt;p>健这一篇主要来构建健身体系的框架，后续的工作即完善和填充这个框架的细节。&lt;/p></description></item><item><title>子弹笔记详解</title><link>https://NamiChen.github.io/2021/the-bullet-journal-method/</link><pubDate>Sat, 09 Jan 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/the-bullet-journal-method/</guid><description>&lt;p>子弹笔记（Bullet Journal）是一种记笔记的方法，集日程表、任务清单、日记本于一体，用几个简单的符号完成所有的记录，我接触它主要是平常就有在纸上写写画画的习惯，但是因为用的切开的 A4 纸，大多最后都找不到，另外，逐渐的想减少手机使用时间，因此将一些功能迁移到笔记本是必由之路。这篇文章记录子弹笔记的一些基础知识，供之后查阅。&lt;/p></description></item><item><title>《致肥元凶》观影笔记</title><link>https://NamiChen.github.io/2021/the-man-who-make-you-fat/</link><pubDate>Wed, 06 Jan 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/the-man-who-make-you-fat/</guid><description>B站纪录片，《致肥元凶》，2012年。 现代人普遍睡眠不足、工作时间过长，更重要的是，普遍肥胖。肥胖不仅仅是外部看到的那样，内脏脂肪远远比皮下</description></item><item><title>屏幕使用时间的简单思考</title><link>https://NamiChen.github.io/2021/time-management-1/</link><pubDate>Mon, 04 Jan 2021 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2021/time-management-1/</guid><description>最近发现自己整个生活有点混乱，屏幕使用时间过长，眼睛干涩，甚至有黑眼圈和血丝。为了理解这是怎么造成的以及做出针对性的改变，所以想做一个系统性</description></item><item><title>书藏的生活周刊第 11 期 (20201206)</title><link>https://NamiChen.github.io/2020/life-weekly-11/</link><pubDate>Sun, 06 Dec 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-11/</guid><description>&lt;p>本周刊目的是记录生活，发现生活中的美好，当前为第十一期。&lt;/p>
&lt;p>时隔大半年之后，生活周刊系列又重新被我捡起，因为我发现，每周接触的新知识需要一个系统的整理，每周的生活也需要一次记录，下周的计划同样需要列出，这些本来应该在日程类软件中完成，但是却不如简单的文档好用。&lt;/p></description></item><item><title>色彩构成基础知识</title><link>https://NamiChen.github.io/2020/basic-knowledge-of-colorology/</link><pubDate>Wed, 02 Dec 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/basic-knowledge-of-colorology/</guid><description>&lt;p>电影、室内设计、服装搭配等等，色彩在我们的生活中实在是再寻常不过了，学习一些色彩学的基础知识相信在以后的生活中会非常有用。&lt;/p></description></item><item><title>素与练:日常的衣服</title><link>https://NamiChen.github.io/2020/daily-clothes/</link><pubDate>Sun, 29 Nov 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/daily-clothes/</guid><description>宁远，素与练：日常的衣服，北京时代华文书局，2020.10.01，豆瓣 好好穿衣服和好好吃饭、好好走路一样，都是日常中有意识地觉知「生活」这回</description></item><item><title>研究记录15-研究过程中的问题总结</title><link>https://NamiChen.github.io/2020/some-problems-in-research/</link><pubDate>Fri, 20 Nov 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/some-problems-in-research/</guid><description>&lt;p>一些以前理解上出现偏差的地方，这里做校正或完善。研究过程中发现的问题，可作为下一步研究方向的，也总结在这里。&lt;/p></description></item><item><title>hugo开发主题1-内容管理</title><link>https://NamiChen.github.io/2020/hugo-develop-themes-1-content-management/</link><pubDate>Wed, 11 Nov 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/hugo-develop-themes-1-content-management/</guid><description>&lt;p>Hugo 用到最后，终究还是免不了走上自己修改甚至开发主题的道路，本篇首先介绍 Hugo 的内容如何管理。&lt;/p></description></item><item><title>hugo开发主题2-模板</title><link>https://NamiChen.github.io/2020/hugo-develop-themes-2-templates/</link><pubDate>Wed, 11 Nov 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/hugo-develop-themes-2-templates/</guid><description>&lt;p>Hugo 用到最后，终究还是免不了走上自己修改甚至开发主题的道路，本篇介绍 Hugo 的核心之一：模板。&lt;/p></description></item><item><title>新知识学习-手机摄影</title><link>https://NamiChen.github.io/2020/basic-concepts-of-photography/</link><pubDate>Mon, 09 Nov 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/basic-concepts-of-photography/</guid><description>&lt;p>有时候走在路上，突然就想把某个看到的画面记录下来，物品整理的时候，也希望能拍摄一张好的静物照，还有和朋友、家人在一起的时候，比如元宵夜，拍一张黑咕隆咚的照片总归让人不开心，这三点就是我想学习手机摄影的主要原因。因为刚入门，看的书是电子工业出版社的《手机摄影必修课》，本篇先学一些摄影的基本概念。&lt;/p></description></item><item><title>日程规划思考-便签待办清单和日历</title><link>https://NamiChen.github.io/2020/%E6%97%A5%E7%A8%8B%E8%A7%84%E5%88%92%E6%80%9D%E8%80%83-%E4%BE%BF%E7%AD%BE%E5%BE%85%E5%8A%9E%E6%B8%85%E5%8D%95%E5%92%8C%E6%97%A5%E5%8E%86/</link><pubDate>Wed, 28 Oct 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/%E6%97%A5%E7%A8%8B%E8%A7%84%E5%88%92%E6%80%9D%E8%80%83-%E4%BE%BF%E7%AD%BE%E5%BE%85%E5%8A%9E%E6%B8%85%E5%8D%95%E5%92%8C%E6%97%A5%E5%8E%86/</guid><description>&lt;p>少数派看到一篇 &lt;a href="https://sspai.com/post/63222" target="_blank">如何建立大学的信息管理体系？&lt;/a>，其中提到了「想法、清单、日历」的日程规划体系，对我有一定的启发，结合阅读这篇文章的收获，写了一个日程规划体系的简单草稿。时间到 2021年02月，经历了长时间的实践尝试和多次总结，终于完善了我的日程规划体系，可以发布第一版正式的文章了，不过以后可能还会有适应性的调整。&lt;/p></description></item><item><title>计算机基础-实数在计算机中的存储</title><link>https://NamiChen.github.io/2020/storage-of-reals-in-computers/</link><pubDate>Sun, 18 Oct 2020 10:16:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/storage-of-reals-in-computers/</guid><description>&lt;p>最近在智能合约中实现信誉算法，但是 Solidity 不支持浮点数赋值和运算，好在有人写了一个库实现了 IEEE 754 浮点数标准，只不过输入输出都是二进制，所以回过头来仔细理解一下实数在计算机中的存储。&lt;/p></description></item><item><title>Mysql学习补充-临时表与派生表</title><link>https://NamiChen.github.io/2020/mysql-learning-supplement-temporary-table-and-derived-table/</link><pubDate>Tue, 13 Oct 2020 19:15:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-supplement-temporary-table-and-derived-table/</guid><description>&lt;p>区分 MySQL 中临时表与派生表的概念，明确它们的用途。&lt;/p></description></item><item><title>Go实现2048小游戏</title><link>https://NamiChen.github.io/2020/a-cli-implement-of-2048-game-using-go/</link><pubDate>Thu, 08 Oct 2020 19:35:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/a-cli-implement-of-2048-game-using-go/</guid><description>&lt;p>Go 实现一个命令行界面的 2048 游戏，仅涉及 Git 和 Go，用来熟悉基本语言特性。原型项目来自 &lt;a href="https://github.com/chhabraamit/2048">https://github.com/chhabraamit/2048&lt;/a>&lt;/p></description></item><item><title>win10效率优化7-终端和winget</title><link>https://NamiChen.github.io/2020/efficient-use-of-win10-7-windows-terminal-and-winget/</link><pubDate>Wed, 07 Oct 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/efficient-use-of-win10-7-windows-terminal-and-winget/</guid><description>Windows terminal 的安装配置和 winget 的基本使用，主要原因是 Powershell 不好看。 1. Windows terminal 界面友好的终端应用，凡是命令行程序都可以用它启动，可以将 win10 下的 cmd、Powersh</description></item><item><title>算法-时间复杂度和空间复杂度</title><link>https://NamiChen.github.io/2020/algorithm-time-and-space-complexity/</link><pubDate>Fri, 18 Sep 2020 20:37:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/algorithm-time-and-space-complexity/</guid><description>&lt;p>时间和空间复杂度的分析是编制程序的一个基本能力，不过平时基本都是脑子里简单的估计，本篇文章打算回忆一下大 O 表示法和具体的时间复杂度的推导过程。&lt;/p></description></item><item><title>Mysql学习补充-语句执行顺序</title><link>https://NamiChen.github.io/2020/mysql-learning-supplement-statement-execution-order/</link><pubDate>Sun, 13 Sep 2020 16:08:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-supplement-statement-execution-order/</guid><description>&lt;p>这篇文章用来仔细思考 MySQL 查询语句的执行顺序。&lt;/p></description></item><item><title>Mysql学习补充-关系数据理论</title><link>https://NamiChen.github.io/2020/mysql-learning-supplement-relational-data-theory/</link><pubDate>Fri, 11 Sep 2020 19:30:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-supplement-relational-data-theory/</guid><description>&lt;p>MySQL 作为关系数据库，关系数据理论是基础，本文进行补充学习，主要包括关系模型、关系代数和范式的相关知识。&lt;/p></description></item><item><title>抗疫与铁线虫入侵</title><link>https://NamiChen.github.io/2020/anti-epidemic-and-worm-invasion/</link><pubDate>Sat, 05 Sep 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/anti-epidemic-and-worm-invasion/</guid><description>&lt;p>今天的周六电影时间看的是一部韩国电影《铁线虫入侵》。可能电影本身质量不是顶尖，但结合今年的疫情和带给我的感触，看完之后我还是给了它五星。一部电影，要么能带给人们快乐，要么能带给人们反思，对我而言，这部电影做到了第二点。下面就写一写我的感受。&lt;/p></description></item><item><title>区块链学习7-交易池底层实现</title><link>https://NamiChen.github.io/2020/transaction-and-txpool/</link><pubDate>Fri, 04 Sep 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/transaction-and-txpool/</guid><description>&lt;p>起源于老师提出的一个问题：区块链是如何处理同时发起的多个请求的。想了想觉得核心是交易池机制，因此准备看一下交易池的原理和实现。&lt;/p></description></item><item><title>Windows、Linux、Unix和 macOS</title><link>https://NamiChen.github.io/2020/windows-linux-unix-and-macos/</link><pubDate>Wed, 02 Sep 2020 21:15:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/windows-linux-unix-and-macos/</guid><description>&lt;p>目前主流的操作系统就是 Windows、Linux 和 macOS，有时候我们也常听到 Unix。今天查一下资料看一看它们的区别。&lt;/p></description></item><item><title>正则表达式与通配符</title><link>https://NamiChen.github.io/2020/regular-expression-basic-syntax/</link><pubDate>Wed, 02 Sep 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/regular-expression-basic-syntax/</guid><description>&lt;p>正则表达式在字符串处理时使用的非常普遍，这次来学习正则的相关知识，分别结束通配符、正则及它们的区别。&lt;/p></description></item><item><title>算法-字符串类问题</title><link>https://NamiChen.github.io/2020/algorithm-stings/</link><pubDate>Mon, 24 Aug 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-stings/</guid><description>做 Leetcode 每日一题的时候遇到了子串判断类的问题，想起一直没仔细的去看过 KMP 等字符串常用的算法，所以这里学习一下。 1. 重复的子字符串 这就是今天遇到的题目</description></item><item><title>Bash脚本语法2</title><link>https://NamiChen.github.io/2020/bash-script-grammer-2/</link><pubDate>Fri, 21 Aug 2020 17:13:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/bash-script-grammer-2/</guid><description>&lt;p>很多时候都要求能使用 Shell 脚本进行编程，本文是根据阮一峰大神的 &lt;a href="https://wangdoc.com/bash/intro.html" target="_blank">系列教程&lt;/a> 总结的基本知识。&lt;/p></description></item><item><title>计算机网络-HTTP方法</title><link>https://NamiChen.github.io/2020/http-method/</link><pubDate>Thu, 20 Aug 2020 19:38:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/http-method/</guid><description>&lt;p>理解不同的 HTTP 方法的区别，主要参考 &lt;a href="https://tools.ietf.org/html/rfc7231#section-4.3" target="_blank">RFC 7231&lt;/a>&lt;/p></description></item><item><title>Bash脚本语法1</title><link>https://NamiChen.github.io/2020/bash-script-grammer-1/</link><pubDate>Tue, 18 Aug 2020 11:37:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/bash-script-grammer-1/</guid><description>&lt;p>很多时候都要求能使用 Shell 脚本进行编程，本文是根据阮一峰大神的 &lt;a href="https://wangdoc.com/bash/intro.html" target="_blank">系列教程&lt;/a> 总结的基本知识。&lt;/p></description></item><item><title>操作系统6-文件管理</title><link>https://NamiChen.github.io/2020/operate-system-6-file-management/</link><pubDate>Tue, 18 Aug 2020 08:18:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/operate-system-6-file-management/</guid><description>&lt;p>本篇介绍文件管理相关的内容。包括硬盘结构、文件和目录的概念，以及一个文件系统涉及的其它知识。&lt;/p></description></item><item><title>操作系统5-设备管理</title><link>https://NamiChen.github.io/2020/operate-system-5-device-management/</link><pubDate>Mon, 17 Aug 2020 19:25:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/operate-system-5-device-management/</guid><description>&lt;p>本篇介绍设备管理的相关内容。最近发现本科用的教材内容非常陈旧，而且不是那么浅显易懂，于是找了一本国外的教材《操作系统导论》，主要根据这个来学习。&lt;/p></description></item><item><title>Golang深入学习9-调用栈</title><link>https://NamiChen.github.io/2020/golang-deep-learning-9-call-stack/</link><pubDate>Sat, 15 Aug 2020 09:47:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-9-call-stack/</guid><description>&lt;p>本篇介绍如何分析 Go 的调用栈。&lt;/p></description></item><item><title>Golang深入学习8-堆栈与逃逸分析</title><link>https://NamiChen.github.io/2020/golang-deep-learning-8-stack-heap-and-escape-analysis/</link><pubDate>Sat, 15 Aug 2020 08:47:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-8-stack-heap-and-escape-analysis/</guid><description>&lt;p>本篇介绍 Go 的堆栈和逃逸分析。&lt;/p></description></item><item><title>Golang查漏补缺-定义与声明的区别</title><link>https://NamiChen.github.io/2020/golang-supplement-the-difference-between-definition-and-declaration/</link><pubDate>Sat, 15 Aug 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/golang-supplement-the-difference-between-definition-and-declaration/</guid><description>&lt;p>一直都比较纠结这个问题，所以搜了一下答案，记录在这里。&lt;/p></description></item><item><title>操作系统4-存储管理</title><link>https://NamiChen.github.io/2020/operate-system-4-memory-management/</link><pubDate>Thu, 13 Aug 2020 11:04:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/operate-system-4-memory-management/</guid><description>&lt;p>本文介绍操作系统另一个重要功能：存储管理。包括存储管理的基本功能，以及分区、页式、段式与段页式三种存储管理方法的具体细节。&lt;/p></description></item><item><title>操作系统3-进程管理</title><link>https://NamiChen.github.io/2020/operate-system-3-process-management/</link><pubDate>Mon, 10 Aug 2020 08:06:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/operate-system-3-process-management/</guid><description>&lt;p>本文介绍操作系统最重要的一部分功能之一：进程管理，从进程的概念到进程的通信，再到死锁问题，最后结束进程的调度。&lt;/p></description></item><item><title>操作系统2-用户接口</title><link>https://NamiChen.github.io/2020/operate-system-2-user-interface/</link><pubDate>Sun, 09 Aug 2020 17:16:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/operate-system-2-user-interface/</guid><description>&lt;p>本文介绍操作系统的一个重要功能：提供用户接口。&lt;/p></description></item><item><title>操作系统1-概述</title><link>https://NamiChen.github.io/2020/operate-system-1-overview/</link><pubDate>Sun, 09 Aug 2020 10:27:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/operate-system-1-overview/</guid><description>&lt;p>本文介绍操作系统的概念、历史、分类、功能及理解这些功能的必备基础知识。&lt;/p></description></item><item><title>win10效率优化8-自动化</title><link>https://NamiChen.github.io/2020/efficient-use-of-win10-7-automation/</link><pubDate>Sat, 08 Aug 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/efficient-use-of-win10-7-automation/</guid><description>&lt;p>win10 一些重复操作的自动化，主要利用 Powershell 和windows任务计划程序，运行环境为 Windows 10 和 PowerShell 7.1，低版本 PowerShell 可能有中文路径无法识别问题。&lt;/p></description></item><item><title>算法-背包问题</title><link>https://NamiChen.github.io/2020/algorithm-knapsack-problem/</link><pubDate>Thu, 06 Aug 2020 10:22:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/algorithm-knapsack-problem/</guid><description>&lt;p>奇安信的笔试遇到了完全背包问题，结果写的时候按 0-1 背包写的贪心，最后没 AC，因此本篇对所有的背包问题做一次整理。&lt;/p></description></item><item><title>Golang深入学习7-调度器与垃圾回收</title><link>https://NamiChen.github.io/2020/golang-deep-learning-7-scheduler-and-garbage-collection/</link><pubDate>Thu, 30 Jul 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-7-scheduler-and-garbage-collection/</guid><description>&lt;p>调度器和垃圾回收都属于 runtime 的一部分，本文我们介绍 Go 中 runtime 的含义，然后再来分析 Go 的调度器和垃圾回收策略。&lt;/p></description></item><item><title>Golang深入学习6-使用pprof进行性能分析</title><link>https://NamiChen.github.io/2020/golang-deep-learning-6-performance-analysis-pprof/</link><pubDate>Mon, 27 Jul 2020 18:46:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-6-performance-analysis-pprof/</guid><description>&lt;p>pprof 用来做 Go 程序的性能监控，让我们知道在什么地方耗费了多少 CPU、memory。&lt;/p></description></item><item><title>Golang深入学习5-使用dlv调试程序</title><link>https://NamiChen.github.io/2020/golang-deep-learning-5-debug-with-dlv/</link><pubDate>Sun, 26 Jul 2020 09:43:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-5-debug-with-dlv/</guid><description>&lt;p>在C/C++中，使用 GDB 调试程序，但在Go中，看过网上的一些文章后，发现 dlv 是个更好的选择，本文进行介绍。&lt;/p></description></item><item><title>Golang深入学习4-map</title><link>https://NamiChen.github.io/2020/golang-deep-learning-4-map/</link><pubDate>Sat, 25 Jul 2020 09:45:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-4-map/</guid><description>&lt;p>本文关心 map 的底层实现、map 的扩容机制和 map 遍历的随机性。&lt;/p></description></item><item><title>Golang深入学习3-切片</title><link>https://NamiChen.github.io/2020/golang-deep-learning-3-slice/</link><pubDate>Fri, 24 Jul 2020 16:13:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-3-slice/</guid><description>&lt;p>本篇理解切片的底层实现和扩容方式。&lt;/p></description></item><item><title>Golang深入学习2-string</title><link>https://NamiChen.github.io/2020/golang-deep-learning-2-string/</link><pubDate>Fri, 24 Jul 2020 11:19:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-2-string/</guid><description>&lt;p>Go 中字符串虽然作为基本数据类型，但本质依然是字符数组，本篇文章理解 Go 底层 string 类型是如何实现的，以及探讨它与 []byte 之间的关系。&lt;/p></description></item><item><title>Golang深入学习1-uintptr 和 Unsafe.Pointer</title><link>https://NamiChen.github.io/2020/golang-deep-learning-1-uintptr-and-unsafe.pointer/</link><pubDate>Thu, 23 Jul 2020 12:15:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-deep-learning-1-uintptr-and-unsafe.pointer/</guid><description>&lt;p>本篇介绍 Go 中的指针、uintptr 和 unsafe.Pointer 三个概念。&lt;/p></description></item><item><title>算法-分支限界</title><link>https://NamiChen.github.io/2020/algorithm-branch-and-bound/</link><pubDate>Thu, 23 Jul 2020 10:07:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/algorithm-branch-and-bound/</guid><description>&lt;p>分支限界和回溯都是有效搜索解空间树的方法，不同的是，分支限界使用广度优先或最小耗费/最大效益优先的方式。&lt;/p></description></item><item><title>计算机网络-数据链路层</title><link>https://NamiChen.github.io/2020/data-link-layer/</link><pubDate>Sun, 19 Jul 2020 20:25:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/data-link-layer/</guid><description>&lt;p>两台主机间的数据传输，通常不是直达的，而是分成一段一段的链路。两个相邻节点间如何传输数据，是数据链路层关心的事情。&lt;/p></description></item><item><title>计算机网络-物理层</title><link>https://NamiChen.github.io/2020/physical-layer/</link><pubDate>Sun, 19 Jul 2020 20:08:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/physical-layer/</guid><description>&lt;p>物理层是 OSI 体系最下面的一层，涉及的多数是关于传输媒体和数据通信的知识，概念居多，本篇不详细解释，仅分辨物理层的主要任务。&lt;/p>
&lt;p>物理层考虑的问题是如何传输比特流，它要负责向数据链路层屏蔽掉传输媒体和通信手段的差异，从而使上层能专注自己的协议和服务。&lt;/p></description></item><item><title>Nginx说明</title><link>https://NamiChen.github.io/2020/nginx-learning/</link><pubDate>Fri, 17 Jul 2020 18:50:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/nginx-learning/</guid><description>&lt;p>本文学习 Nginx 的相关知识。&lt;/p></description></item><item><title>Mysql学习8-存储过程、触发器和事件</title><link>https://NamiChen.github.io/2020/mysql-learning-8-procedure-trigger-and-event/</link><pubDate>Wed, 15 Jul 2020 17:22:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-8-procedure-trigger-and-event/</guid><description>&lt;p>存储过程是在数据库中定义一些 SQL 语句的集合，可以直接调用这些存储过程来执行已经定义好的 SQL 语句。避免了开发人员重复编写相同 SQL 语句的问题。&lt;/p>
&lt;p>触发器和存储过程相似，都是嵌入到 MySQL 中的一段程序。触发器是由事件来触发某个操作。当数据库执行这些事件时，就会激活触发器来执行相应的操作。&lt;/p>
&lt;p>本篇介绍这两个概念&lt;/p></description></item><item><title>Mysql学习7-视图与索引</title><link>https://NamiChen.github.io/2020/mysql-learning-7-view-and-index/</link><pubDate>Wed, 15 Jul 2020 15:52:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-7-view-and-index/</guid><description>&lt;p>视图在数据库中的作用类似于窗户，用户可以通过这个窗口看到只对自己有用的数据。既保障了数据的安全性，又大大提高了查询效率。&lt;/p>
&lt;p>索引是提高数据库性能的重要方式，用来快速找出数据表中的特定记录。如果在表中查询的列有一个索引，MySQL 能快速到达一个位置去搜寻数据，而不必查看所有数据。&lt;/p>
&lt;p>本文介绍这两个概念。&lt;/p></description></item><item><title>计算机网络-HTTP与HTTPS协议</title><link>https://NamiChen.github.io/2020/http-and-https/</link><pubDate>Thu, 09 Jul 2020 20:43:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/http-and-https/</guid><description>&lt;p>HTTP 和 HTTPS 是最常用的两个协议，本篇对它们进行介绍。&lt;/p></description></item><item><title>计算机网络-TCP和UDP协议</title><link>https://NamiChen.github.io/2020/transmission-control-protocol-and-user-datagram-protocol/</link><pubDate>Tue, 07 Jul 2020 21:16:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/transmission-control-protocol-and-user-datagram-protocol/</guid><description>&lt;p>本篇介绍计算机网络运输层的的 TCP 和 UDP 协议，主要是过一遍，加深理解，以及方便以后查看，毕竟不是每次都带着书。&lt;/p></description></item><item><title>如何避免信息过载</title><link>https://NamiChen.github.io/2020/how-to-avoid-information-overload/</link><pubDate>Thu, 11 Jun 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/how-to-avoid-information-overload/</guid><description>信息过载可能严重影响我们的生活，网上看到了心理与行为信息部的一些建议。 1. 主动浏览，拒绝被动推送 筛选有效的信息源 重点关注政府机关、专业组织等具</description></item><item><title>基于Go语言开发在线论坛9-部署Go Web应用</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-9-deploy-go-web-application/</link><pubDate>Sun, 07 Jun 2020 20:50:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-9-deploy-go-web-application/</guid><description>&lt;p>部署 Go 应用相对简单，因为所有应用代码都被打包成一个二进制文件了（视图模板、静态资源和配置文件等非 Go 代码除外），并且不需要依赖其他库，不需要额外的运行时环境（比如 Java 需要再安装 JVM），也不需要部署额外的 HTTP 服务器。&lt;/p></description></item><item><title>基于Go语言开发在线论坛8-消息、视图和日期时间本地化</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-8-message-view-and-date-time-localizationsingleton-mode/</link><pubDate>Sun, 07 Jun 2020 20:30:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-8-message-view-and-date-time-localizationsingleton-mode/</guid><description>&lt;p>由于之前所有页面和消息文本都是英文的，而我们开发的应用基本都是面向中文用户的，所以需要对项目进行本地化，因此本篇介绍如何在 Go Web 应用中进行国际化和本地化编程，由于项目比较简单，只介绍消息提示、视图模板和日期格式的本地化。&lt;/p></description></item><item><title>基于Go语言开发在线论坛7-通过单例模式获取全局配置</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-7-get-global-configuration-through-singleton-mode/</link><pubDate>Sun, 07 Jun 2020 16:25:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-7-get-global-configuration-through-singleton-mode/</guid><description>&lt;p>本文介绍如何将敏感信息或可变信息通过配置文件进行配置，然后在应用中读取这些配置文件来获取配置信息。&lt;/p></description></item><item><title>基于Go语言开发在线论坛6-日志与错误处理</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-6-log-and-error/</link><pubDate>Sun, 07 Jun 2020 11:03:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-6-log-and-error/</guid><description>&lt;p>到现在为止，我们已经完成了在线论坛项目基本功能的开发，对 Go 语言 Web 编程中如何实现 MVC 架构模式以及 CRUD（数据库增删改查）基本操作有了初步的认识。不过现在所有的日志和错误处理都是杂糅在业务代码中，本篇介绍如何对它们统一进行处理，使得业务代码和日志及错误处理逻辑分离。&lt;/p></description></item><item><title>Golang日志系统</title><link>https://NamiChen.github.io/2020/golang-log-system/</link><pubDate>Sun, 07 Jun 2020 09:48:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-log-system/</guid><description>&lt;p>日志是一个系统必不可少的部分，本篇介绍Golang中的日志系统。&lt;/p></description></item><item><title>基于Go语言开发在线论坛5-创建群组和主题功能实现</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-5-create-thread-and-post/</link><pubDate>Fri, 05 Jun 2020 11:41:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-5-create-thread-and-post/</guid><description>&lt;p>上篇文章基于 Cookie + Session 实现了简单的用户认证功能，用户认证之后，就可以创建群组和主题了，本篇介绍如何创建群组和主题，并将其渲染到前端页面。&lt;/p></description></item><item><title>基于Go语言开发在线论坛4-通过Cookie和Session实现用户认证</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-4-user-authentication/</link><pubDate>Thu, 04 Jun 2020 11:01:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-4-user-authentication/</guid><description>&lt;p>上篇演示了首页路由、处理器、视图模板的实现，接着就要实现群组、主题的增删查改，不过，需要在认证后才能执行这些操作，所以本篇介绍如何实现用户认证相关功能。&lt;/p></description></item><item><title>Golang设置与使用cookie</title><link>https://NamiChen.github.io/2020/golang-set-and-use-cookie/</link><pubDate>Mon, 01 Jun 2020 20:11:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-set-and-use-cookie/</guid><description>&lt;p>关于 Cookie 的使用是 Web 编程中的重要一部分，本篇介绍 Cookie 的基本知识和 Golang 中使用的方法。&lt;/p></description></item><item><title>研究记录14-重新实验及实验流程优化</title><link>https://NamiChen.github.io/2020/experimental-process-optimization-and-performance-test/</link><pubDate>Mon, 01 Jun 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/experimental-process-optimization-and-performance-test/</guid><description>&lt;p>我们对之前的实验流程做了进一步的优化，并且对添加恶意行为检测后的系统进行了进一步的性能测试。&lt;/p></description></item><item><title>Golang模板</title><link>https://NamiChen.github.io/2020/golang-template/</link><pubDate>Fri, 29 May 2020 17:08:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-template/</guid><description>&lt;p>模板就是在写动态页面时不变的部分，服务端程序渲染可变部分生成动态网页，Go 语言提供了 html/template 包来支持模板渲染。&lt;/p></description></item><item><title>Golang使用gorilla、mux包</title><link>https://NamiChen.github.io/2020/golang-use-gorilla/mux-package/</link><pubDate>Fri, 29 May 2020 13:38:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-use-gorilla/mux-package/</guid><description>&lt;p>本文介绍 &lt;a href="https://github.com/gorilla/mux" target="_blank">gorilla/mux&lt;/a> 包的使用。&lt;/p></description></item><item><title>Golang启动HTTP服务器</title><link>https://NamiChen.github.io/2020/golang-start-http-server/</link><pubDate>Fri, 29 May 2020 09:32:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/golang-start-http-server/</guid><description>&lt;p>本文介绍 Golang 如何实现 HTTP 服务端及客户端。&lt;/p></description></item><item><title>基于Go语言开发在线论坛3-访问论坛首页</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-3-visit-forum-homepage/</link><pubDate>Fri, 29 May 2020 09:08:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-3-visit-forum-homepage/</guid><description>&lt;p>前两篇分别介绍了整体设计及数据表的创建、模型类的编写，本篇了解如何在服务端处理用户请求，并启动论坛首页。文章转自学院君的教程，略有改动。&lt;/p></description></item><item><title>Golang密码学算法</title><link>https://NamiChen.github.io/2020/golang-cryptographic-algorithm/</link><pubDate>Thu, 28 May 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/golang-cryptographic-algorithm/</guid><description>&lt;p>在 Go 中，加密是很重要的一部分，本文对此进行介绍。&lt;/p></description></item><item><title>基于Go语言开发在线论坛2-通过模型类与MySQL数据库交互</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-2-interact-with-mysql/</link><pubDate>Wed, 27 May 2020 18:25:20 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-2-interact-with-mysql/</guid><description>&lt;p>在本篇教程中，我们将在 MySQL 中创建一个 &lt;code>chitchat&lt;/code> 数据库作为论坛项目的数据库。我选择了在本地安装 MySQL Server，但也可以基于 Docker 容器运行。转自学院君的教程，略有改动。&lt;/p></description></item><item><title>基于Go语言开发在线论坛1-整体设计与数据模型</title><link>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-1-overall-design-and-data-model/</link><pubDate>Wed, 27 May 2020 18:12:20 +0800</pubDate><guid>https://NamiChen.github.io/2020/development-of-online-forum-based-on-golang-1-overall-design-and-data-model/</guid><description>转自学院君的教程1 ，这里进行复现并深入理解，文章内容可能略有调整。 1. 项目介绍 要完成的是一个简单的在线论坛项目，主要仿照 Google 网上论坛 进行开发，但</description></item><item><title>Golang数据库编程</title><link>https://NamiChen.github.io/2020/golang-interact-with-mysql/</link><pubDate>Tue, 26 May 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/golang-interact-with-mysql/</guid><description>Go 官方提供了database 包，database 包下有 sql/driver。该包用来定义操作数据库的接口，这保证了无论使用哪种数据库，操作方</description></item><item><title>Mysql学习6-操作表中数据</title><link>https://NamiChen.github.io/2020/mysql-learning-6-data-query-language/</link><pubDate>Sun, 24 May 2020 17:03:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-6-data-query-language/</guid><description>&lt;p>本文详细介绍 &lt;strong>对表中数据&lt;/strong> 的增删查改操作。&lt;/p></description></item><item><title>Mysql学习5-约束与运算符</title><link>https://NamiChen.github.io/2020/mysql-learning-5-constraints-and-operators/</link><pubDate>Sun, 24 May 2020 12:10:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-5-constraints-and-operators/</guid><description>&lt;p>约束是一种限制，它通过限制表中的数据，来确保数据的完整性和唯一性。本文介绍 MySQL 的约束和运算符。&lt;/p></description></item><item><title>Mysql学习4-数据表操作</title><link>https://NamiChen.github.io/2020/mysql-learning-4-data-manipulation-language/</link><pubDate>Sun, 24 May 2020 11:25:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-4-data-manipulation-language/</guid><description>&lt;p>介绍数据表的基本操作，主要包括创建数据表、查看数据表结构、修改数据表和删除数据表等。&lt;/p></description></item><item><title>Mysql学习3-数据类型和存储引擎</title><link>https://NamiChen.github.io/2020/mysql-learning-3-data-type-and-storage-engine/</link><pubDate>Sun, 24 May 2020 10:32:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-3-data-type-and-storage-engine/</guid><description>&lt;p>存储引擎决定数据表的类型，数据表的字段则有自己的数据类型。&lt;/p></description></item><item><title>Mysql学习2-数据库操作</title><link>https://NamiChen.github.io/2020/mysql-learning-2-data-definition-language/</link><pubDate>Sun, 24 May 2020 09:17:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-2-data-definition-language/</guid><description>&lt;p>本文介绍对数据库的操作，包括创建、删除、修改等。&lt;/p></description></item><item><title>Mysql学习1-入门</title><link>https://NamiChen.github.io/2020/mysql-learning-1-introduction/</link><pubDate>Sun, 24 May 2020 08:02:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/mysql-learning-1-introduction/</guid><description>&lt;p>本文介绍数据库和 MySQL的基础知识。得庆幸当初数据库课学的还可以，大部分内容看一眼都能想起来，不需要去理解，就是单纯的忘了一些语句写法。&lt;/p></description></item><item><title>JavaScript学习2-基础语法</title><link>https://NamiChen.github.io/2020/javascript-learning-2-basic-syntax/</link><pubDate>Fri, 22 May 2020 17:07:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/javascript-learning-2-basic-syntax/</guid><description>各种语言的基础语法部分都很相似，因此这里简单总结一下 1. 变量与常量 尽管以前使用 var 关键字，但现在更多使用 let 关键字声明变量 1 2 3 4 5 let myName; // 声明 myName =</description></item><item><title>JavaScript学习1-概览</title><link>https://NamiChen.github.io/2020/javascript-learning-1-overview/</link><pubDate>Fri, 22 May 2020 11:50:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/javascript-learning-1-overview/</guid><description>JavaScript 是标准 Web 技术的第三层，负责实现动态的行为，比如实现交互式的地图、2D/3D动画、滚动播放的视频等。 JS 的标准是 ECMAScript，2015</description></item><item><title>Docker-网络</title><link>https://NamiChen.github.io/2020/network/</link><pubDate>Mon, 18 May 2020 17:13:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/network/</guid><description>Docker 允许通过外部访问容器或容器互联的方式来提供网络服务。 1. 外部访问容器 容器中可以运行一些网络应用，要让外部也可以访问这些应用，可以通过 -P 或 -p 参</description></item><item><title>Docker-镜像、容器与仓库</title><link>https://NamiChen.github.io/2020/image-container-and-repository/</link><pubDate>Mon, 18 May 2020 09:00:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/image-container-and-repository/</guid><description>&lt;p>Docker 的三个基本概念是镜像（Image）、容器（Container）和仓库（Repository），理解了这三个概念基本就理解了 Docker。&lt;/p></description></item><item><title>智能合约知识点总结</title><link>https://NamiChen.github.io/2020/summary-of-smart-contract-knowledge-points/</link><pubDate>Mon, 04 May 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/summary-of-smart-contract-knowledge-points/</guid><description>&lt;p>项目进行过程中知识点的总结&lt;/p>
&lt;h2 id="1-字符串比较">1. 字符串比较&lt;/h2>
&lt;p>翻译自：&lt;a href="https://fravoll.github.io/solidity-patterns/string_equality_comparison.html" target="_blank">Fravoll-String Equality Comparison&lt;/a>&lt;/p>
&lt;p>比较两个给定字符串是否相等，是 Solidity 编程中最常见的一种情况，但语言本身并没有提供内置函数用于字符串比较，本文介绍两种可用方法并分析 Gas 消耗情况。&lt;/p>
&lt;h3 id="11-stringutils-库">1.1 StringUtils 库&lt;/h3>
&lt;p>第一种方法是使用 Ethereum 基金会提供的 StringUtils 库，它对每个字符进行成对比较，如果有一个字符对不匹配，则返回false。这种办法可以返回正确的结果，对于短字符串和字符不同发生在字符串前面的情况仅消耗少量 Gas。但是对于相等的字符串和长字符串，这种方法的 Gas 消耗较高，因为必须做很多比较才能得到正确结果。因此，字符串比较的两个可衡量的因素是字符串平均长度和正确率。&lt;/p>
&lt;h3 id="12-哈希函数">1.2 哈希函数&lt;/h3>
&lt;p>作者提出使用哈希函数进行比较，同时检查所提供的字符串的长度，从一开始就剔除长度不匹配的字符串。其步骤如下&lt;/p>
&lt;ol>
&lt;li>检查两个字符串是否有相同长度，通过转换为 &lt;code>bytes&lt;/code> 类型完成，因为 &lt;code>bytes&lt;/code> 类型有内置长度函数。如果相同进入第2步，如果不相同返回结果；&lt;/li>
&lt;li>使用 &lt;code>keccak256()&lt;/code> 函数对两个字符串求哈希，然后比较计算得到的哈希值，从而确定是否相等。&lt;/li>
&lt;/ol>
&lt;p>一个示例代码如下&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;span class="lnt">3
&lt;/span>&lt;span class="lnt">4
&lt;/span>&lt;span class="lnt">5
&lt;/span>&lt;span class="lnt">6
&lt;/span>&lt;span class="lnt">7
&lt;/span>&lt;span class="lnt">8
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="err">#&lt;/span> &lt;span class="err">这&lt;/span>&lt;span class="err">段&lt;/span>&lt;span class="err">代&lt;/span>&lt;span class="err">码&lt;/span>&lt;span class="err">未&lt;/span>&lt;span class="err">经&lt;/span>&lt;span class="err">安&lt;/span>&lt;span class="err">全&lt;/span>&lt;span class="err">审&lt;/span>&lt;span class="err">计&lt;/span>&lt;span class="err">，&lt;/span>&lt;span class="err">使&lt;/span>&lt;span class="err">用&lt;/span>&lt;span class="err">有&lt;/span>&lt;span class="err">风&lt;/span>&lt;span class="err">险&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">hashCompareWithLengthCheck&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">string&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="kt">string&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">internal&lt;/span> &lt;span class="k">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">bool&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">if&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">bytes&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">a&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">length&lt;/span> &lt;span class="o">!=&lt;/span> &lt;span class="kt">bytes&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">length&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="kc">false&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span> &lt;span class="k">else&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="nf">keccak256&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">abi&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">encodePacket&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">a&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="o">==&lt;/span> &lt;span class="nf">keccak256&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">abi&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">encodePacket&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>&lt;code>abi.encodePacket(...) returns (bytes)&lt;/code> 用于对给定参数执行&lt;a href="https://solidity-cn.readthedocs.io/zh/develop/abi-spec.html#abi-packed-mode" target="_blank">紧打包编码&lt;/a>，官方文档中不推荐使用 &lt;code>keccak256(...)&lt;/code> 直接计算哈希，而是使用 &lt;code>keccak256(abi.encodePacked(...))&lt;/code>&lt;/p>
&lt;h3 id="13-gas-消耗分析">1.3 Gas 消耗分析&lt;/h3>
&lt;p>在 Remix 编写代码测试了三种不同情况的字符串比较的 Gas 消耗&lt;/p>
&lt;ol>
&lt;li>比较哈希&lt;/li>
&lt;li>比较每个字符，同时比较字符串长度&lt;/li>
&lt;li>比较哈希，同时比较字符串长度&lt;/li>
&lt;/ol>
&lt;p>结果如下表所示，输入列为输入的待比较字符串，输出列的单位为 Wei&lt;/p>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th align="left">Input A&lt;/th>
&lt;th align="left">Input B&lt;/th>
&lt;th align="right">Hash&lt;/th>
&lt;th align="right">Character + Length&lt;/th>
&lt;th align="right">Hash + Length&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td align="left">abcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="left">abcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">7062&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">abcdefghijklmnopqrstuvwxy&lt;strong>X&lt;/strong>&lt;/td>
&lt;td align="left">abcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">7012&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">&lt;strong>X&lt;/strong>bcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="left">abcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">912&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">a&lt;strong>X&lt;/strong>cdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="left">abcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">1156&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">ab&lt;strong>X&lt;/strong>defghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="left">abcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">1400&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">abcdefghijkl&lt;/td>
&lt;td align="left">abcdefghijklmnopqrstuvwxyz&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">690&lt;/td>
&lt;td align="right">707&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">a&lt;/td>
&lt;td align="left">a&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">962&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">ab&lt;/td>
&lt;td align="left">ab&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">1156&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td align="left">abc&lt;/td>
&lt;td align="left">abc&lt;/td>
&lt;td align="right">1225&lt;/td>
&lt;td align="right">1450&lt;/td>
&lt;td align="right">1261&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;p>可以看出，哈希+字符串长度 的比较方式 Gas 消耗更加稳定，这种方式比较高效。&lt;/p>
&lt;h2 id="2-可见性与getter函数">2. 可见性与Getter函数&lt;/h2>
&lt;p>转自：&lt;a href="https://learnblockchain.cn/docs/solidity/contracts.html#getter" target="_blank">Solidity 0.6.4 中文文档&lt;/a>&lt;/p>
&lt;p>Solidity 有两种函数调用：内部调用（Internal Function Calls）和外部调用（External Function Calls）。前者指直接或递归地调用合约内部函数，不会产生实际的 EVM 调用，因此也被称为「消息嗲用」，后者指从合约外部调用合约中的函数，会产生一个 EVM 调用。&lt;/p>
&lt;h3 id="21-可见性">2.1 可见性&lt;/h3>
&lt;p>因此，函数和状态变量有四种可见性。函数可以指定为 &lt;code>external&lt;/code>，&lt;code>public&lt;/code>，&lt;code>internal&lt;/code> 或 &lt;code>private&lt;/code>，对于状态变量， 默认是 &lt;code>internal&lt;/code> 且不能设置为 &lt;code>external&lt;/code>。&lt;/p>
&lt;ul>
&lt;li>&lt;code>external&lt;/code>：外部函数作为合约接口的一部分，意味着我们可以从其他合约和交易中调用。 一个外部函数 &lt;code>f&lt;/code> 不能从内部调用（即 &lt;code>f&lt;/code> 不起作用，但 &lt;code>this.f()&lt;/code>可以）。 当收到大量数据的时候，外部函数有时候会更有效率，因为数据不会从calldata复制到内存.&lt;/li>
&lt;li>&lt;code>public&lt;/code>：public 函数是合约接口的一部分，可以在内部或通过消息调用。对于 public 状态变量， 会自动生成一个 getter 函数（见下面）。&lt;/li>
&lt;li>&lt;code>internal&lt;/code>：这些函数和状态变量只能是内部访问（即从当前合约内部或从它派生的合约访问），不使用 &lt;code>this&lt;/code> 调用。&lt;/li>
&lt;li>&lt;code>private&lt;/code>：private 函数和状态变量仅在当前定义它们的合约中使用，并且不能被派生合约使用。&lt;/li>
&lt;/ul>
&lt;blockquote>
&lt;p>合约中的所有内容对外部观察者都是可见的。设置一些 &lt;code>private&lt;/code> 类型只能阻止其他合约访问和修改这些信息， 但是对于区块链外的整个世界它仍然是可见的。&lt;/p>
&lt;/blockquote>
&lt;p>可见性标识符的定义位置，对于状态变量来说是在类型后面，对于函数是在参数列表和返回关键字中间，如下例&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;span class="lnt">3
&lt;/span>&lt;span class="lnt">4
&lt;/span>&lt;span class="lnt">5
&lt;/span>&lt;span class="lnt">6
&lt;/span>&lt;span class="lnt">7
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">&amp;gt;=&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">4&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">16&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">C&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">f&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">private&lt;/span> &lt;span class="kr">pure&lt;/span> &lt;span class="k">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span> &lt;span class="k">return&lt;/span> &lt;span class="n">a&lt;/span> &lt;span class="o">+&lt;/span> &lt;span class="mi">1&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">setData&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">internal&lt;/span> &lt;span class="p">{&lt;/span> &lt;span class="n">data&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>在下面的例子中，&lt;code>D&lt;/code> 可以调用 &lt;code>c.getData（）&lt;/code> 来获取状态存储中 &lt;code>data&lt;/code> 的值，但不能调用 &lt;code>f&lt;/code> 。 合约 &lt;code>E&lt;/code> 继承自 &lt;code>C&lt;/code> ，因此可以调用 &lt;code>compute&lt;/code>。&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;span class="lnt">11
&lt;/span>&lt;span class="lnt">12
&lt;/span>&lt;span class="lnt">13
&lt;/span>&lt;span class="lnt">14
&lt;/span>&lt;span class="lnt">15
&lt;/span>&lt;span class="lnt">16
&lt;/span>&lt;span class="lnt">17
&lt;/span>&lt;span class="lnt">18
&lt;/span>&lt;span class="lnt">19
&lt;/span>&lt;span class="lnt">20
&lt;/span>&lt;span class="lnt">21
&lt;/span>&lt;span class="lnt">22
&lt;/span>&lt;span class="lnt">23
&lt;/span>&lt;span class="lnt">24
&lt;/span>&lt;span class="lnt">25
&lt;/span>&lt;span class="lnt">26
&lt;/span>&lt;span class="lnt">27
&lt;/span>&lt;span class="lnt">28
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">&amp;gt;=&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">4&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">C&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="kr">private&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">f&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">private&lt;/span> &lt;span class="k">returns&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span> &lt;span class="k">return&lt;/span> &lt;span class="n">a&lt;/span> &lt;span class="o">+&lt;/span> &lt;span class="mi">1&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">setData&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span> &lt;span class="n">data&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">getData&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="k">returns&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span> &lt;span class="k">return&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">compute&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="kt">uint&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">internal&lt;/span> &lt;span class="k">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span> &lt;span class="k">return&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="o">+&lt;/span>&lt;span class="n">b&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="c1">// 下面代码编译错误
&lt;/span>&lt;span class="c1">&lt;/span>&lt;span class="kd">contract&lt;/span> &lt;span class="n">D&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">readData&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="n">C&lt;/span> &lt;span class="n">c&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="k">new&lt;/span> &lt;span class="n">C&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="n">local&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">c&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">f&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="c1">// 错误：成员 `f` 不可见
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="n">c&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">setData&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">3&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="n">local&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">c&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">getData&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="n">local&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">c&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">compute&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">3&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="mi">5&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="c1">// 错误：成员 `compute` 不可见
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">E&lt;/span> &lt;span class="kr">is&lt;/span> &lt;span class="n">C&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">g&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="n">C&lt;/span> &lt;span class="n">c&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="k">new&lt;/span> &lt;span class="n">C&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="n">val&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">compute&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">3&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="mi">5&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="c1">// 访问内部成员（从继承合约访问父合约成员）
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;h3 id="22-getter-函数">2.2 Getter 函数&lt;/h3>
&lt;p>编译器自动为所有 &lt;strong>public&lt;/strong> 状态变量创建 getter 函数。对于下面给出的合约，编译器会生成一个名为 &lt;code>data&lt;/code> 的函数， 该函数没有参数，返回值是一个 &lt;code>uint&lt;/code> 类型，即状态变量 &lt;code>data&lt;/code> 的值。 状态变量的初始化可以在声明时完成。&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;span class="lnt">11
&lt;/span>&lt;span class="lnt">12
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">&amp;gt;=&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">4&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">C&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="n">data&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="mi">42&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">Caller&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="n">C&lt;/span> &lt;span class="n">c&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="k">new&lt;/span> &lt;span class="n">C&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">f&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="n">local&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">c&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">data&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>getter 函数具有外部（external）可见性。如果在内部访问 getter（即没有 &lt;code>this.&lt;/code> ），它被认为一个状态变量。 如果使用外部访问（即用 &lt;code>this.&lt;/code> ），它被认作为一个函数。&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;span class="lnt">3
&lt;/span>&lt;span class="lnt">4
&lt;/span>&lt;span class="lnt">5
&lt;/span>&lt;span class="lnt">6
&lt;/span>&lt;span class="lnt">7
&lt;/span>&lt;span class="lnt">8
&lt;/span>&lt;span class="lnt">9
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">^&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">4&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">C&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">x&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="n">data&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="mi">3&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="c1">// 内部访问
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="kt">uint&lt;/span> &lt;span class="n">val&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="nb">this&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">data&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span> &lt;span class="c1">// 外部访问
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>如果你有一个数组类型的 &lt;code>public&lt;/code> 状态变量，那么你只能通过生成的 getter 函数访问数组的单个元素。 这个机制以避免返回整个数组时的高成本gas。 可以使用如 &lt;code>data(0)&lt;/code> 用于指定参数要返回的单个元素。 如果要在一次调用中返回整个数组，则需要写一个函数，例如：&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;span class="lnt">11
&lt;/span>&lt;span class="lnt">12
&lt;/span>&lt;span class="lnt">13
&lt;/span>&lt;span class="lnt">14
&lt;/span>&lt;span class="lnt">15
&lt;/span>&lt;span class="lnt">16
&lt;/span>&lt;span class="lnt">17
&lt;/span>&lt;span class="lnt">18
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">&amp;gt;=&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">4&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">arrayExample&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="c1">// public state variable
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="kt">uint&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="p">]&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="n">myArray&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="c1">// 指定生成的Getter 函数
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="cm">/*
&lt;/span>&lt;span class="cm"> function myArray(uint i) public view returns (uint) {
&lt;/span>&lt;span class="cm"> return myArray[i];
&lt;/span>&lt;span class="cm"> }
&lt;/span>&lt;span class="cm"> */&lt;/span>
&lt;span class="c1">// 返回整个数组
&lt;/span>&lt;span class="c1">&lt;/span> &lt;span class="kd">function&lt;/span> &lt;span class="n">getArray&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="kr">view&lt;/span> &lt;span class="k">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="p">]&lt;/span> &lt;span class="kr">memory&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="n">myArray&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>现在可以使用 &lt;code>getArray()&lt;/code> 获得整个数组，而 &lt;code>myArray(i)&lt;/code> 是返回单个元素。&lt;/p>
&lt;p>下一个例子稍微复杂一些：&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">^&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">4&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">Complex&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">struct&lt;/span> &lt;span class="n">Data&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kt">bytes3&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">mapping&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="o">=&amp;gt;&lt;/span> &lt;span class="kt">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="n">map&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="kd">mapping&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="o">=&amp;gt;&lt;/span> &lt;span class="kd">mapping&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">bool&lt;/span> &lt;span class="o">=&amp;gt;&lt;/span> &lt;span class="n">Data&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>这将会生成以下形式的函数&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;span class="lnt">3
&lt;/span>&lt;span class="lnt">4
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kd">function&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">arg1&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="kt">bool&lt;/span> &lt;span class="n">arg2&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="kt">uint&lt;/span> &lt;span class="n">arg3&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="k">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="kt">bytes3&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="n">a&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="n">arg1&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="n">arg2&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="n">arg3&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">a&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="n">b&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="n">data&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="n">arg1&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="n">arg2&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="n">arg3&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="n">b&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>请注意，因为没有好的方法来提供映射的键，所以结构中的映射被省略。&lt;/p>
&lt;h2 id="3-合约间调用">3. 合约间调用&lt;/h2>
&lt;p>之前的实验合约间的调用没有成功，这次就仔细地研究一下合约间地调用机制。分为两种情况&lt;/p>
&lt;ol>
&lt;li>调用者和被调用者在一个sol文件中&lt;/li>
&lt;li>调用者和被调用者在不同的sol文件中&lt;/li>
&lt;/ol>
&lt;p>本文提到的合约调用方法的实质是抽象合约的使用。&lt;/p>
&lt;h3 id="31-同sol文件的智能合约调用">3.1 同sol文件的智能合约调用&lt;/h3>
&lt;p>下面的智能合约中，Main和Add两个合约定义在一个Main.sol文件中，可以同时编译，然后逐个部署。&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;span class="lnt">11
&lt;/span>&lt;span class="lnt">12
&lt;/span>&lt;span class="lnt">13
&lt;/span>&lt;span class="lnt">14
&lt;/span>&lt;span class="lnt">15
&lt;/span>&lt;span class="lnt">16
&lt;/span>&lt;span class="lnt">17
&lt;/span>&lt;span class="lnt">18
&lt;/span>&lt;span class="lnt">19
&lt;/span>&lt;span class="lnt">20
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-js" data-lang="js">&lt;span class="nx">pragma&lt;/span> &lt;span class="nx">solidity&lt;/span> &lt;span class="o">^&lt;/span>&lt;span class="mf">0.5&lt;/span>&lt;span class="mf">.0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="nx">contract&lt;/span> &lt;span class="nx">Main&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="nx">Add&lt;/span> &lt;span class="nx">add&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="nx">constructor&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">address&lt;/span> &lt;span class="nx">_m&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="nx">add&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="nx">Add&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">_m&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="nx">Addnumber&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="nx">view&lt;/span> &lt;span class="nx">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="nx">add&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="nx">add5&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">10&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="nx">contract&lt;/span> &lt;span class="nx">Add&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="nx">add5&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span> &lt;span class="nx">s&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="nx">pure&lt;/span> &lt;span class="nx">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="mi">5&lt;/span>&lt;span class="o">+&lt;/span>&lt;span class="nx">s&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>以使用Remix为例，点击编译按钮编译Main.sol文件，将会同时编译Main和Add两个合约。&lt;/p>
&lt;p>&lt;figure>&lt;img src="https://NamiChen.github.io/svg/loading.min.svg" data-sizes="auto" data-src="https://picped-1301226557.cos.ap-beijing.myqcloud.com/YJS_20191108_68472178-e6294d00-025a-11ea-8b4b-41a53b471c18.png" alt="编译" class="lazyload">&lt;figcaption class="image-caption">编译&lt;/figcaption>&lt;/figure>&lt;/p>
&lt;p>然后首先部署Add合约，因为Main合约的部署需要Add的合约地址作为参数。切换到部署和运行选项卡，选择Add合约，点击&lt;code>Deploy&lt;/code>，成功部署后，复制合约地址。&lt;/p>
&lt;p>&lt;figure>&lt;img src="https://NamiChen.github.io/svg/loading.min.svg" data-sizes="auto" data-src="https://picped-1301226557.cos.ap-beijing.myqcloud.com/YJS_20191108_68472256-0e18b080-025b-11ea-9a24-e324c82cd7b5.png" alt="deploy simple Add" class="lazyload">&lt;figcaption class="image-caption">deploy simple Add&lt;/figcaption>&lt;/figure>&lt;/p>
&lt;p>然后重新选择Main合约，填入Add合约地址作为参数，点击部署按钮。&lt;/p>
&lt;p>&lt;figure>&lt;img src="https://NamiChen.github.io/svg/loading.min.svg" data-sizes="auto" data-src="https://picped-1301226557.cos.ap-beijing.myqcloud.com/YJS_20191108_68472285-1a047280-025b-11ea-8bb5-a1fb5c65574e.png" alt="deploy simple Main" class="lazyload">&lt;figcaption class="image-caption">deploy simple Main&lt;/figcaption>&lt;/figure>&lt;/p>
&lt;p>测试合约间调用，由合约内容可知，Main合约中的Addnumber函数调用了Add合约的add5函数，传入参数为10，得到的结果应为15。展开左侧的&lt;code>Deployed Contracts&lt;/code>，点击Addnumber进行调用，结果如下。&lt;/p>
&lt;p>&lt;figure>&lt;img src="https://NamiChen.github.io/svg/loading.min.svg" data-sizes="auto" data-src="https://picped-1301226557.cos.ap-beijing.myqcloud.com/YJS_20191108_68472220-f5a89600-025a-11ea-9d2a-b39c8e39a810.png" alt="call test" class="lazyload">&lt;figcaption class="image-caption">call test&lt;/figcaption>&lt;/figure>&lt;/p>
&lt;h3 id="32-不同sol文件的智能合约调用">3.2 不同sol文件的智能合约调用&lt;/h3>
&lt;p>这一次我们测试不同sol文件的智能合约调用，来一个复杂一点的，两个合约分别是Add.sol和Main.sol。&lt;/p>
&lt;p>Add.sol使用了一个结构体来定义数值，并通过映射定义查找表来寻找这个值。文件中定义了两个函数，numRegister用来向表中添加数值，addValue用来将从表中查到的指定值+5返回。之所以用这个结构是因为我们的项目里用到了，这里来测试一下可不可行。&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;span class="lnt">11
&lt;/span>&lt;span class="lnt">12
&lt;/span>&lt;span class="lnt">13
&lt;/span>&lt;span class="lnt">14
&lt;/span>&lt;span class="lnt">15
&lt;/span>&lt;span class="lnt">16
&lt;/span>&lt;span class="lnt">17
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-js" data-lang="js">&lt;span class="nx">pragma&lt;/span> &lt;span class="nx">solidity&lt;/span> &lt;span class="o">^&lt;/span>&lt;span class="mf">0.5&lt;/span>&lt;span class="mf">.0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="nx">contract&lt;/span> &lt;span class="nx">Add&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="nx">struct&lt;/span> &lt;span class="nx">Num&lt;/span>&lt;span class="p">{&lt;/span>
&lt;span class="nx">uint&lt;/span> &lt;span class="nx">value&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="nx">mapping&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span> &lt;span class="p">=&amp;gt;&lt;/span> &lt;span class="nx">Num&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="nx">lookupTable&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="nx">numRegister&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span> &lt;span class="nx">key&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="nx">uint&lt;/span> &lt;span class="nx">_value&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="nx">lookupTable&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="nx">key&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="nx">value&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="nx">_value&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="nx">addValue&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span> &lt;span class="nx">key&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="nx">view&lt;/span> &lt;span class="nx">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="nx">lookupTable&lt;/span>&lt;span class="p">[&lt;/span>&lt;span class="nx">key&lt;/span>&lt;span class="p">]&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="nx">value&lt;/span> &lt;span class="o">+&lt;/span> &lt;span class="mi">5&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>Main.sol没有多大变化&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt"> 1
&lt;/span>&lt;span class="lnt"> 2
&lt;/span>&lt;span class="lnt"> 3
&lt;/span>&lt;span class="lnt"> 4
&lt;/span>&lt;span class="lnt"> 5
&lt;/span>&lt;span class="lnt"> 6
&lt;/span>&lt;span class="lnt"> 7
&lt;/span>&lt;span class="lnt"> 8
&lt;/span>&lt;span class="lnt"> 9
&lt;/span>&lt;span class="lnt">10
&lt;/span>&lt;span class="lnt">11
&lt;/span>&lt;span class="lnt">12
&lt;/span>&lt;span class="lnt">13
&lt;/span>&lt;span class="lnt">14
&lt;/span>&lt;span class="lnt">15
&lt;/span>&lt;span class="lnt">16
&lt;/span>&lt;span class="lnt">17
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-js" data-lang="js">&lt;span class="nx">pragma&lt;/span> &lt;span class="nx">solidity&lt;/span> &lt;span class="o">^&lt;/span>&lt;span class="mf">0.5&lt;/span>&lt;span class="mf">.0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="nx">contract&lt;/span> &lt;span class="nx">Main&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="nx">Add&lt;/span> &lt;span class="nx">add&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="nx">constructor&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">address&lt;/span> &lt;span class="nx">_m&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="nx">add&lt;/span> &lt;span class="o">=&lt;/span> &lt;span class="nx">Add&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">_m&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="nx">Addnumber&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="nx">view&lt;/span> &lt;span class="nx">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="nx">add&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="nx">addValue&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="mi">5&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="nx">contract&lt;/span> &lt;span class="nx">Add&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="nx">addValue&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span> &lt;span class="nx">key&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="nx">view&lt;/span> &lt;span class="nx">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="nx">uint&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>仍然是先编译部署Add合约，部署后调用numRegister函数写入数值5，并调用addValue函数测试返回。&lt;/p>
&lt;p>&lt;figure>&lt;img src="https://NamiChen.github.io/svg/loading.min.svg" data-sizes="auto" data-src="https://picped-1301226557.cos.ap-beijing.myqcloud.com/YJS_20191108_68472316-2d174280-025b-11ea-96a6-51af8dd4fd4c.png" alt="deploy comlex Add" class="lazyload">&lt;figcaption class="image-caption">deploy comlex Add&lt;/figcaption>&lt;/figure>&lt;/p>
&lt;p>接着编译部署Main合约，复制Add合约地址作为初始化参数，部署后调用Addnumber函数测试&lt;/p>
&lt;p>&lt;figure>&lt;img src="https://NamiChen.github.io/svg/loading.min.svg" data-sizes="auto" data-src="https://picped-1301226557.cos.ap-beijing.myqcloud.com/YJS_20191108_68472331-399b9b00-025b-11ea-933f-8c03ff95c55a.png" alt="deploy comlex Main" class="lazyload">&lt;figcaption class="image-caption">deploy comlex Main&lt;/figcaption>&lt;/figure>&lt;/p>
&lt;h3 id="33-总结">3.3 总结&lt;/h3>
&lt;p>合约内的调用方法是相同的，都要先实例化，然后传入被调合约地址，接着才能调用。而写在不同sol文件中时，需要额外声明被调合约的抽象合约，有些文章中说使用&lt;code>call&lt;/code>，&lt;code>callcode&lt;/code>或&lt;code>delegatecall&lt;/code>，但并不建议，因为这三个函数都是非常底层的函数，破坏了类型的安全，只能作为最后的手段使用。&lt;/p>
&lt;p>详细的解释参考了&lt;a href="https://ethereum.stackexchange.com/questions/9733/calling-function-from-deployed-contract" target="_blank">StackExchange-Calling function from deployed contract&lt;/a>&lt;/p>
&lt;h2 id="4-函数修饰词pure和view">4. 函数修饰词pure和view&lt;/h2>
&lt;p>转自&lt;a href="https://learnblockchain.cn/docs/solidity/contracts.html#view" target="_blank">深入理解Solidity-函数&lt;/a>&lt;/p>
&lt;p>这两个函数修饰词的作用是告诉编译器函数是否会读取/修改状态，view 表示保证不修改状态，pure 表示保证不读取也不修改状态。Solidity v0.4.17 之前没有这两个修饰词，而是使用 constant 关键字，和 view 的含义相同，不过在 v0.5.0 之后被移除，现在只能使用这两个 view 和 pure。&lt;/p>
&lt;h3 id="41-view-视图函数">4.1 view 视图函数&lt;/h3>
&lt;p>Getter 方法会被自动标记为 &lt;code>view&lt;/code>，除此之外，一个 view 修饰的例子如下&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;span class="lnt">3
&lt;/span>&lt;span class="lnt">4
&lt;/span>&lt;span class="lnt">5
&lt;/span>&lt;span class="lnt">6
&lt;/span>&lt;span class="lnt">7
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">&amp;gt;=&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">5&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">C&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">f&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="kt">uint&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="kr">view&lt;/span> &lt;span class="k">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="n">a&lt;/span> &lt;span class="o">*&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="n">b&lt;/span> &lt;span class="o">+&lt;/span> &lt;span class="mi">42&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="o">+&lt;/span> &lt;span class="nb">now&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>view 保证函数不修改状态，以下操作会被认为是修改状态&lt;/p>
&lt;ol>
&lt;li>修改状态变量。&lt;/li>
&lt;li>产生事件。&lt;/li>
&lt;li>创建其它合约。&lt;/li>
&lt;li>使用 &lt;code>selfdestruct&lt;/code>。&lt;/li>
&lt;li>通过调用发送以太币。&lt;/li>
&lt;li>调用任何没有标记为 &lt;code>view&lt;/code> 或者 &lt;code>pure&lt;/code> 的函数。&lt;/li>
&lt;li>使用低级调用。&lt;/li>
&lt;li>使用包含特定操作码的内联汇编。&lt;/li>
&lt;/ol>
&lt;h3 id="42-pure-纯函数">4.2 pure 纯函数&lt;/h3>
&lt;p>pure 保证不读取也不修改状态，不修改的定义上面已经提到，下面的操作被认为是读取状态&lt;/p>
&lt;ol>
&lt;li>读取状态变量。&lt;/li>
&lt;li>访问 &lt;code>address(this).balance&lt;/code> 或者 &lt;code>.balance&lt;/code>。&lt;/li>
&lt;li>访问 &lt;code>block&lt;/code>，&lt;code>tx&lt;/code>， &lt;code>msg&lt;/code> 中任意成员 （除 &lt;code>msg.sig&lt;/code> 和 &lt;code>msg.data&lt;/code> 之外）。&lt;/li>
&lt;li>调用任何未标记为 &lt;code>pure&lt;/code> 的函数。&lt;/li>
&lt;li>使用包含某些操作码的内联汇编。&lt;/li>
&lt;/ol>
&lt;p>一个 pure 修饰的例子如下&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;span class="lnt">3
&lt;/span>&lt;span class="lnt">4
&lt;/span>&lt;span class="lnt">5
&lt;/span>&lt;span class="lnt">6
&lt;/span>&lt;span class="lnt">7
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-solidity" data-lang="solidity">&lt;span class="kr">pragma solidity&lt;/span> &lt;span class="o">&amp;gt;=&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">5&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span> &lt;span class="o">&amp;lt;&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">7&lt;/span>&lt;span class="p">.&lt;/span>&lt;span class="mi">0&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="kd">contract&lt;/span> &lt;span class="n">C&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="kd">function&lt;/span> &lt;span class="n">f&lt;/span>&lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span> &lt;span class="n">a&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="kt">uint&lt;/span> &lt;span class="n">b&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="kr">public&lt;/span> &lt;span class="kr">pure&lt;/span> &lt;span class="k">returns&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="kt">uint&lt;/span>&lt;span class="p">)&lt;/span> &lt;span class="p">{&lt;/span>
&lt;span class="k">return&lt;/span> &lt;span class="n">a&lt;/span> &lt;span class="o">*&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="n">b&lt;/span> &lt;span class="o">+&lt;/span> &lt;span class="mi">42&lt;/span>&lt;span class="p">)&lt;/span>&lt;span class="p">;&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;span class="p">}&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;h2 id="5-浮点数处理">5. 浮点数处理&lt;/h2>
&lt;p>首先声明，Solidity 中支持浮点数定义，但无法赋值和进行计算。文档中对其描述是「目前还不完全支持」，虽然这意味着以后可能会完全支持，但等不及了，下面记录几个可参考的资料。&lt;/p>
&lt;ol>
&lt;li>来自 &lt;a href="https://ethereum.stackexchange.com/questions/83785/what-fixed-or-float-point-math-libraries-are-available-in-solidity" target="_blank">ethereum stackexchange&lt;/a> 中的回答，介绍了一些可用的库；&lt;/li>
&lt;li>&lt;a href="https://github.com/abdk-consulting/abdk-libraries-solidity/blob/master/ABDKMathQuad.md" target="_blank">ABDK Math Quad&lt;/a>，包含两个合约库，一个支持定点数，一个支持浮点数；&lt;/li>
&lt;li>Mikhail Vladimirov 的 &lt;a href="https://medium.com/coinmonks/math-in-solidity-part-1-numbers-384c8377f26d" target="_blank">Math in Solidity&lt;/a> 系列文章，介绍如何在 Solidity 中处理各种数学运算，写的非常棒。&lt;/li>
&lt;/ol>
&lt;h2 id="6-地址类型">6. 地址类型&lt;/h2>
&lt;p>在智能合约中显式传入地址类型时，可能会出现如下错误&lt;/p>
&lt;blockquote>
&lt;p>Address checksum&lt;/p>
&lt;p>This looks like an address but has an invalid checksum. If this is not used as an address, please prepend &amp;lsquo;00&amp;rsquo;.&lt;/p>
&lt;/blockquote>
&lt;p>关于该问题的一个讨论见 &lt;a href="https://github.com/ethereum/EIPs/issues/55">https://github.com/ethereum/EIPs/issues/55&lt;/a>&lt;/p>
&lt;p>这是因为合约中现在使用地址类型必须做一个转换，不是简单的全部大写字母或小写字母，而是遵循一定的规则，这个规则见 &lt;a href="https://github.com/ethereum/EIPs/blob/master/EIPS/eip-55.md" target="_blank">ethereum/EIPs#55&lt;/a>&lt;/p>
&lt;p>但是网上提供的解决方案一般是使用JS库中的转换函数，在智能合约中无法直接解决，好在，web3提供了一个&lt;a href="https://web3-tools.netlify.com/" target="_blank">在线API接口&lt;/a>，可以调用其&lt;code>checkAddressChecksum&lt;/code>函数对地址进行转换，然后将转换后的结果直接用于合约代码。&lt;/p>
&lt;h2 id="7-gas-limit问题">7. Gas limit问题&lt;/h2>
&lt;p>在搭建的以太坊私链上进行智能合约部署时，出现了以下问题&lt;/p>
&lt;div class="highlight">&lt;div class="chroma">
&lt;table class="lntable">&lt;tr>&lt;td class="lntd">
&lt;pre class="chroma">&lt;code>&lt;span class="lnt">1
&lt;/span>&lt;span class="lnt">2
&lt;/span>&lt;/code>&lt;/pre>&lt;/td>
&lt;td class="lntd">
&lt;pre class="chroma">&lt;code class="language-js" data-lang="js">&lt;span class="nx">INFO&lt;/span> &lt;span class="p">[&lt;/span>&lt;span class="mi">03&lt;/span>&lt;span class="o">-&lt;/span>&lt;span class="mi">21&lt;/span>&lt;span class="o">|&lt;/span>&lt;span class="mi">13&lt;/span>&lt;span class="o">:&lt;/span>&lt;span class="mi">50&lt;/span>&lt;span class="o">:&lt;/span>&lt;span class="mf">11.690&lt;/span>&lt;span class="p">]&lt;/span> &lt;span class="nx">Served&lt;/span> &lt;span class="nx">eth_sendTransaction&lt;/span> &lt;span class="nx">reqid&lt;/span>&lt;span class="o">=&lt;/span>&lt;span class="mi">24&lt;/span> &lt;span class="nx">t&lt;/span>&lt;span class="o">=&lt;/span>&lt;span class="mf">684.186&lt;/span>&lt;span class="nx">µs&lt;/span> &lt;span class="nx">err&lt;/span>&lt;span class="o">=&lt;/span>&lt;span class="s2">&amp;#34;exceeds block gas limit&amp;#34;&lt;/span>
&lt;span class="nb">Error&lt;/span>&lt;span class="o">:&lt;/span> &lt;span class="nx">exceeds&lt;/span> &lt;span class="nx">block&lt;/span> &lt;span class="nx">gas&lt;/span> &lt;span class="nx">limit&lt;/span> &lt;span class="kc">undefined&lt;/span>
&lt;/code>&lt;/pre>&lt;/td>&lt;/tr>&lt;/table>
&lt;/div>
&lt;/div>&lt;p>出现该错误的原因如错误描述，是当前合约所需的gas超过了区块的最大gas。这可能与参数gasLimit有关。在创世区块的配置文件中，我们使用了默认的配置值，为&lt;code>0x2fefd8&lt;/code>，转换为10进制即&lt;code>3141592&lt;/code>。&lt;/p>
&lt;p>注：&lt;a href="http://tool.oschina.net/hexconvert/" target="_blank">在线转换工具&lt;/a>&lt;/p></description></item><item><title>算法-回溯</title><link>https://NamiChen.github.io/2020/algorithm-backtracking/</link><pubDate>Mon, 04 May 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-backtracking/</guid><description>在真实的世界中，很多问题是不存在快速解法的，只能穷尽搜索，因此一个高效的搜索技术非常重要。回溯（Backtracking）和分支限界（Bra</description></item><item><title>算法-贪心</title><link>https://NamiChen.github.io/2020/algorithm-greedu/</link><pubDate>Sun, 03 May 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-greedu/</guid><description>&lt;p>贪心是一种策略，是一种总是寻求当前最优的策略。因为贪心只关心局部的最优，因此不是总能得到全局的最优解，所以我们选择贪心解决问题时必须保证状态的独立性，即当前最优值只与当前状态有关，不会影响以后的状态。&lt;/p></description></item><item><title>算法-动态规划</title><link>https://NamiChen.github.io/2020/algorithm-dynamic-programming/</link><pubDate>Fri, 01 May 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-dynamic-programming/</guid><description>&lt;p>动态规划策略通常用于求解最优化问题。在这类问题中，可能会有许多可行解，每个解对应一个值，我们希望找到具有最优值的那个解，也就是最优解。当题目中涉及「最大」「最小」等词时，很有可能就是这类问题，要考虑是否可用动态规划求解。&lt;/p></description></item><item><title>研究记录13-添加恶意行为检测机制</title><link>https://NamiChen.github.io/2020/credit-based-mechanism/</link><pubDate>Tue, 28 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/credit-based-mechanism/</guid><description>&lt;p>吸收了一些新论文的想法，对原访问控制系统功能做了补充，添加了恶意行为检测（或者称为动态访问控制），目的是减少恶意行为，增加合法行为在区块链中得到确认的几率。所有调整总结查看 &lt;a href="#jump">附录I&lt;/a>。&lt;/p></description></item><item><title>Docker-Win10 Home安装Docker</title><link>https://NamiChen.github.io/2020/install-docker-desktop-on-windows-10-home/</link><pubDate>Thu, 23 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/install-docker-desktop-on-windows-10-home/</guid><description>Docker Desktop 是 Windows 安装 Docker 的推荐安装方式，然而系统需求是 Pro, Enterprise 或 Education 版本，Home 版不支持，因为没有 Hyper-V。 这篇文章记录网上找到的 Win10 Home 版安装 Docker Desktop 的方</description></item><item><title>Docker-使用 Docker 安装运行 mysql</title><link>https://NamiChen.github.io/2020/using-docker-installation-to-run-mysql/</link><pubDate>Thu, 23 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/using-docker-installation-to-run-mysql/</guid><description>Docker Hub 中的 mysql 镜像 地址为 https://hub.docker.com/_/mysql，安装运行过程如下。 1. 拉取镜像 1 2 3 4 5 6 $ docker pull mysql # 查看 $ docker</description></item><item><title>An Attribute-Based Distributed Access Control for Blockchain-enabled IoT</title><link>https://NamiChen.github.io/2020/an-attribute-based-distributed-access-control-for-blockchain-enabled-iot/</link><pubDate>Wed, 22 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/an-attribute-based-distributed-access-control-for-blockchain-enabled-iot/</guid><description>P. Wang, Y. Yue, W. Sun, and J. Liu, “An Attribute-Based Distributed Access Control for Blockchain-enabled IoT,” in 2019 International Conference on Wireless and Mobile Computing, Networking and Communications (WiMob), Barcelona, Spain, Oct. 2019, pp. 1–6, doi: 10.1109/WiMOB.2019.8923232. 第一作者是西电的，国家自然科学基金项目成果，研</description></item><item><title>Attribute-Based Access Control</title><link>https://NamiChen.github.io/2020/attribute-based-access-control/</link><pubDate>Wed, 22 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/attribute-based-access-control/</guid><description>V. C. Hu, D. R. Kuhn, and D. F. Ferraiolo, “Attribute-Based Access Control,” Computer, vol. 48, no. 2, pp. 85–88, Feb. 2015, doi: 10.1109/MC.2015.33. 1. 引言 传统的访问控制基于用户身份（分</description></item><item><title>Supply Chain Management Automation using Wireless Sensor Networks</title><link>https://NamiChen.github.io/2020/supply-chain-management-automation-using-wireless-sensor-networks/</link><pubDate>Mon, 20 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/supply-chain-management-automation-using-wireless-sensor-networks/</guid><description>L. Evers and P. Havinga, “Supply Chain Management Automation using Wireless Sensor Networks,” in 2007 IEEE Internatonal Conference on Mobile Adhoc and Sensor Systems, Pisa, Italy, Oct. 2007, pp. 1–3, doi: 10.1109/MOBHOC.2007.4428689. 注：插图来自原论文和网络。 1. 引言 这篇论文</description></item><item><title>Blockchain and Deep Reinforcement Learning Empowered Intelligent 5G Beyond</title><link>https://NamiChen.github.io/2020/blockchain-and-deep-reinforcement-learning-empowered-intelligent-5g-beyond/</link><pubDate>Mon, 13 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/blockchain-and-deep-reinforcement-learning-empowered-intelligent-5g-beyond/</guid><description>Day Y, Xu D, Maharjan S, 等. Blockchain and Deep Reinforcement Learning Empowered Intelligent 5G Beyond[J]. IEEE Network, 2019, 33(3): 10–17. DOI:10.1109/MNET.2019.1800376. 1. 引言 区块链和 AI 会在 6G 中扮演关键角色，前者可保证分布式网络安全，后者可用于智能资源管</description></item><item><title>算法-分治</title><link>https://NamiChen.github.io/2020/algorithm-divide-and-conquer/</link><pubDate>Mon, 13 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-divide-and-conquer/</guid><description>分治，字面意思就是分而治之，意思就是把一个复杂的问题分成两个或更多个相同或相似的子问题，解决子问题后再进行合并。典型的如归并排序和快排，都是</description></item><item><title>算法-递归</title><link>https://NamiChen.github.io/2020/algorithm-recursive/</link><pubDate>Sun, 12 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-recursive/</guid><description>&lt;p>首先简单阐述一下递归、分治、动态规划和贪心这几个东西的区别和联系。&lt;/p>
&lt;ol>
&lt;li>递归是一种编程技巧，一种解决问题的思维方式；&lt;/li>
&lt;li>分治和动态规划是建立在递归基础上的，解决更具体问题的两类算法思想（实现动态规划大都不是递归的，但是过程和思想是）；&lt;/li>
&lt;li>贪心是动态规划的一个子集，可以更高效解决一部分更特殊的问题。&lt;/li>
&lt;/ol></description></item><item><title>关于个性化广告</title><link>https://NamiChen.github.io/2020/about-personalized-advertising/</link><pubDate>Thu, 09 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/about-personalized-advertising/</guid><description>各主流平台提供了关闭个性化广告的功能，但操作一番之后发现，一是关闭入口藏的比较深给，二是我们反感的其实不是个性化广告，而是过多的广告和收集的</description></item><item><title>研究记录12-区块链与D2D内容缓存/计算卸载方向探索</title><link>https://NamiChen.github.io/2020/blockchain-for-d2d-cache-or-computing-offload/</link><pubDate>Fri, 03 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/blockchain-for-d2d-cache-or-computing-offload/</guid><description>1. 概念引入 论文1提到，一些邻近的用户设备（User Equipment, UE）组合其计算能力，服务于具有更高性能需求的应用可以叫做 ad-hoc cloud。实际应用需要解决</description></item><item><title>算法-排序</title><link>https://NamiChen.github.io/2020/algorithm-sort/</link><pubDate>Thu, 02 Apr 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-sort/</guid><description>排序算法分为内部排序（待排序记录存放在内存中进行的排序过程）和外部排序（由于待排序记录数量大，以致内存一次不能容纳全部记录，在排序过程中需要</description></item><item><title>算法-搜索</title><link>https://NamiChen.github.io/2020/algorithm-search/</link><pubDate>Sun, 29 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-search/</guid><description>&lt;p>搜索是最常用的算法之一，但线性的搜索进行介绍没有太大的意义，本文介绍搜索中一种广为使用的方法：二分查找。&lt;/p></description></item><item><title>算法-数组类问题</title><link>https://NamiChen.github.io/2020/algorithm-array/</link><pubDate>Fri, 20 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/algorithm-array/</guid><description>数组的访问时间为 $O(1)$，这是它最大的优势，但限于数组固定的大小，平常使用最多的是动态数组。在 Golang 中，其实就是[切片]^(slice)，动</description></item><item><title>触动人心的句子</title><link>https://NamiChen.github.io/2020/%E8%A7%A6%E5%8A%A8%E4%BA%BA%E5%BF%83%E7%9A%84%E5%8F%A5%E5%AD%90/</link><pubDate>Fri, 20 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/%E8%A7%A6%E5%8A%A8%E4%BA%BA%E5%BF%83%E7%9A%84%E5%8F%A5%E5%AD%90/</guid><description>记录一些触动人心的句子 1、一寸山河一寸血，十万青年十万军 2、因为不知道下辈子还能不能遇到，所以这辈子拼命给你温暖给你拥抱 3、人有贫富，但无贵</description></item><item><title>数据结构-并查集</title><link>https://NamiChen.github.io/2020/data-structure-union-find-set/</link><pubDate>Wed, 18 Mar 2020 18:44:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/data-structure-union-find-set/</guid><description>&lt;p>并查集是一种特别而实用的结构，主要作用是进行不相交集合的合并和判断两个元素是否在同一集合，时间复杂度为常数级。常见用途包括 Kruskal 算法和求最近公共祖先，本篇文章介绍该数据结构。&lt;/p></description></item><item><title>数据结构-B树与红黑树</title><link>https://NamiChen.github.io/2020/data-structure-b-tree-and-red-black-tree/</link><pubDate>Wed, 18 Mar 2020 09:21:00 +0800</pubDate><guid>https://NamiChen.github.io/2020/data-structure-b-tree-and-red-black-tree/</guid><description>&lt;p>本篇介绍B树（B-树），B+树和红黑树，参考自陈小玉，《趣学数据结构》。&lt;/p></description></item><item><title>数据结构-图</title><link>https://NamiChen.github.io/2020/data-structure-graph/</link><pubDate>Mon, 16 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/data-structure-graph/</guid><description>链表是一种一对一的关系，树是一种一对多的关系，图则是一种多对多的关系。实际上，我们可以将链表和树都看作图的一部分。 1. 图的定义 用 V(Vertex) 表示顶点的集</description></item><item><title>面对疫情区块链可以做些什么</title><link>https://NamiChen.github.io/2020/what-can-blockchain-do-during-the-covid-19/</link><pubDate>Mon, 16 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/what-can-blockchain-do-during-the-covid-19/</guid><description>这场年初爆发的疫情在国内控制住以后，反而开始在全世界其它国家蔓延，如大数据、5G等技术均在当前这场疫情中产生了自己的作用，区块链能做些什么，</description></item><item><title>数据结构-堆</title><link>https://NamiChen.github.io/2020/data-structure-heap/</link><pubDate>Wed, 11 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/data-structure-heap/</guid><description>&lt;p>普通的队列是一种先进先出的数据结构，在此基础上，还有一种叫做 &lt;strong>优先队列&lt;/strong> 的结构。顾名思义，优先队列就是具有优先级的队列，其中，元素被赋予优先级，具有最高优先级的元素将最先被访问。&lt;/p></description></item><item><title>书藏的生活周刊第 10 期 (20200306)</title><link>https://NamiChen.github.io/2020/life-weekly-10/</link><pubDate>Fri, 06 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-10/</guid><description>本周刊目的是记录生活，发现生活中的美好，当前为第十期，由于经历了图床转换，本文图片已丢失。 注：文中图片大部分来自网络，侵删。 时讯 1、新冠肺炎</description></item><item><title>波士顿犹太人屠杀纪念碑碑文</title><link>https://NamiChen.github.io/2020/engraved-in-st-pauls-church-in-1962/</link><pubDate>Fri, 06 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/engraved-in-st-pauls-church-in-1962/</guid><description>波士顿犹太人大屠杀遇难犹太人纪念碑位于该市市中心的小公园中，由六个玻璃空心塔组成，塔壁上刻有集中营囚徒代号和幸存者的语录。在玻璃空心塔的旁边</description></item><item><title>雕刀</title><link>https://NamiChen.github.io/2020/%E9%9B%95%E5%88%80/</link><pubDate>Fri, 06 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/%E9%9B%95%E5%88%80/</guid><description>纵然 你已去远 想此刻又已隔了几重山 我依然停顿在水流的中央 努力回溯 那刚刚过去的时光 想你从千里之遥奔赴到我的身边 原也只为了这一刻的低徊和缱绻 从云到</description></item><item><title>数据结构-二叉搜索树</title><link>https://NamiChen.github.io/2020/data-structure-binary-search-tree/</link><pubDate>Tue, 03 Mar 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/data-structure-binary-search-tree/</guid><description>二叉搜索树是二叉树的一种特殊形式，由于它对查找的良好特性，使用较为广泛，本篇文章我们对其进行介绍，同时也包括二叉搜索树的各种进阶，比如二叉平</description></item><item><title>书藏的生活周刊第 9 期 (20200228)</title><link>https://NamiChen.github.io/2020/life-weekly-9/</link><pubDate>Fri, 28 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-9/</guid><description>本周刊目的是记录生活，发现生活中的美好，当前为第九期，由于经历了图床转换，本文图片已丢失。 时讯 1、新冠肺炎疫情 截至2020年2月28日0:0</description></item><item><title>数据结构-二叉树</title><link>https://NamiChen.github.io/2020/data-structure-tree-and-binary-tree/</link><pubDate>Mon, 24 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/data-structure-tree-and-binary-tree/</guid><description>树是反映事物之间层次关系的一种结构，比如家谱树、硬盘目录结构树等。 使用树的原因是这种层次结构在管理上有更高的效率，以查找为例，顺序查找的时间</description></item><item><title>数据结构-队列与栈</title><link>https://NamiChen.github.io/2020/data-structure-queue-and-stack/</link><pubDate>Sat, 22 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/data-structure-queue-and-stack/</guid><description>&lt;p>队列与栈是最常使用的两种数据结构，其中，队列的核心特征是先入先出，栈的核心特征是后入先出，只要符合这两个特征，就属于队列（栈），不因实现形式的不同（数组或链表）而有差别，可以根据具体情况选择使用起来更方便的实现形式。&lt;/p>
&lt;p>在本文中，我们对队列与栈的核心功能，循环队列这种特殊结构，以及队列和栈的主要应用，尤其是广度优先搜索和深度优先搜索进行介绍。&lt;/p></description></item><item><title>书藏的生活周刊第 8 期 (20200221)</title><link>https://NamiChen.github.io/2020/life-weekly-8/</link><pubDate>Fri, 21 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-8/</guid><description>本周刊目的是记录生活，发现生活中的美好，当前为第八期，由于经历了图床转换，本文图片已丢失。 时讯 1、新冠肺炎疫情好转 截至2020年2月21日0</description></item><item><title>数据结构-链表</title><link>https://NamiChen.github.io/2020/data-structure-linkedlist/</link><pubDate>Thu, 20 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/data-structure-linkedlist/</guid><description>链表是一种最为基础的数据结构，由一系列结点组成，每个结点不仅包含值，还包含指向下一个结点（有时也包括上一个结点）的指针。相比于数组，在链表中</description></item><item><title>时间不够用怎么办</title><link>https://NamiChen.github.io/2020/how-to-do-if-no-enough-time/</link><pubDate>Mon, 17 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/how-to-do-if-no-enough-time/</guid><description>我现在面临的一个重要问题是：想做的事情太多，而时间不够用。 六千年的人类文明史，创造了一个难以想象的庞大知识体系，到现在，人类社会已经形成了一</description></item><item><title>LVChain： A Lightweight and Vote-based Blockchain for Access Control in the IoT</title><link>https://NamiChen.github.io/2020/lvchain-a-lightweight-and-vote-based-blockchain-for-access-control-in-the-iot/</link><pubDate>Fri, 14 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/lvchain-a-lightweight-and-vote-based-blockchain-for-access-control-in-the-iot/</guid><description>Yu, Yue &amp;amp; Zhang, Sheng &amp;amp; Chen, Chao &amp;amp; Zhong, Xiaoxiong. (2018). LVChain: A Lightweight and Vote-based Blockchain for Access Control in the IoT. 870-874. DOI: 10.1109/CompComm.2018.8780687 KeyWord: IoT, security, Blockchain, access authorization, BLE-based devies 注：插图经过重新绘制，照片来自原论文截图。 1. 引言 IoT与生活联系的越来</description></item><item><title>书藏的生活周刊第 7 期 (20200214)</title><link>https://NamiChen.github.io/2020/life-weekly-7/</link><pubDate>Fri, 14 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-7/</guid><description>&lt;p>本周刊目的是记录生活，发现生活中的美好，当前为第七期。由于经历了图床转换，本文图片已丢失。&lt;/p>
&lt;p>注：本文图片均已丢失&lt;/p></description></item><item><title>Efficient Distributed Authentication and Access Control System</title><link>https://NamiChen.github.io/2020/efficient-distributed-authentication-and-access-control-system/</link><pubDate>Sun, 09 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/efficient-distributed-authentication-and-access-control-system/</guid><description>Benhadj Djilali H., Tandjaoui D. (2019) Efficient Distributed Authentication and Access Control System Management for Internet of Things Using Blockchain. In: Renault É., Boumerdassi S., Leghris C., Bouzefrane S. (eds) Mobile, Secure, and Programmable Networking. MSPN 2019. Lecture Notes in Computer Science, vol 11557. Springer, Cham DOI：https://doi.org/10</description></item><item><title>书藏的生活周刊第 6 期 (20200207)</title><link>https://NamiChen.github.io/2020/life-weekly-6/</link><pubDate>Fri, 07 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-6/</guid><description>本周刊目的是记录生活，发现生活中的美好，当前为第六期。 时讯 本周疫情发展比较严重，一周内确诊人数达到近两万人，同时世界局势风云变幻，各地灾害频</description></item><item><title>A Blockchain based access control for IoT</title><link>https://NamiChen.github.io/2020/a-blockchain-based-access-control-for-iot/</link><pubDate>Thu, 06 Feb 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/a-blockchain-based-access-control-for-iot/</guid><description>Imen Riabi, Yosr Dhif, Hella Kaffel Ben Ayed, Khaled Zaatouri. A Blockchain based access control for IoT[C]. International Wireless Communications &amp;amp; Mobile Computing Conference (IWCMC), 2019. DOI: 10.1109/IWCMC.2019.8766506 Keywords: Access control, Blockchain, Smart Contract, Internet of Things 注：本文图片来自原论文。 1. 引入 作者的考虑主要基于三点 传统中心化的访</description></item><item><title>书藏的生活周刊第 5 期 (20200131)</title><link>https://NamiChen.github.io/2020/life-weekly-5/</link><pubDate>Fri, 31 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-5/</guid><description>本周刊目的是记录生活，发现生活中的美好，当前为第五期。 时讯 1、欧盟领导人正式签署英国“脱欧”协议 01.24 当地时间24日，欧洲理事会主席米歇尔与欧盟</description></item><item><title>书藏的生活周刊第 4 期 (20200124)</title><link>https://NamiChen.github.io/2020/life-weekly-4/</link><pubDate>Fri, 24 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-4/</guid><description>本周刊目的是记录生活，发现生活中的美好，当前为第四期。 时讯 1、习近平访问缅甸 01.18 应缅甸总统温敏邀请，中华人民共和国主席习近平于2020年1月1</description></item><item><title>生活技能-租房注意事项</title><link>https://NamiChen.github.io/2020/life-skills-notes-on-renting/</link><pubDate>Thu, 23 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-skills-notes-on-renting/</guid><description>租房是现在和未来几年逃不开的话题，这里总结租房时要注意的事情 找房子 可以通过熟人、网络、小区广告等了解情况，节省费用，但耗时耗力。 找中介是可以</description></item><item><title>win10效率优化5-系统功能的充分利用</title><link>https://NamiChen.github.io/2020/efficient-use-of-win10-5-system-function-use/</link><pubDate>Sun, 19 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/efficient-use-of-win10-5-system-function-use/</guid><description>作为一款成熟的商业系统，windows提供了大量实用的功能，尤其是到了win10后，很多功能的体验变得越来越好，本篇对这些功能做总结。 值得注</description></item><item><title>win10效率优化6-软件体系整理</title><link>https://NamiChen.github.io/2020/efficient-use-of-win10-6-software-collection/</link><pubDate>Sun, 19 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/efficient-use-of-win10-6-software-collection/</guid><description>对win10中使用的软件体系进行整理，在满足需要的同时，选择每一类软件中最适合的一种，同时尽量减少安装的软件数量。 1. 系统管理 1.1 火绒 抛弃腾讯和</description></item><item><title>win10效率优化4-文件管理</title><link>https://NamiChen.github.io/2020/efficient-use-of-win10-4-file-management/</link><pubDate>Fri, 17 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/efficient-use-of-win10-4-file-management/</guid><description>文件管理是效率提升、电子资料极简化的重要部分，本文探索如何有效的对win10中的文件进行管理，核心包括三部分：分类、命名和备份。 1. 分类 win</description></item><item><title>书藏的生活周刊第 3 期 (20200117)</title><link>https://NamiChen.github.io/2020/life-weekly-3/</link><pubDate>Fri, 17 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-3/</guid><description>本周刊目的是记录生活，发现生活中的美好，当前为第三期。 时讯 1、蔡英文当选台湾地区领导人 01.11 台湾地区领导人选举11日举行投票，民进党候选人蔡英文</description></item><item><title>研究记录11-新访问控制方案的实现与测试</title><link>https://NamiChen.github.io/2020/optimize-the-implementation-and-testing-of-the-system/</link><pubDate>Wed, 15 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/optimize-the-implementation-and-testing-of-the-system/</guid><description>&lt;p>根据之前几篇文章的分析，我们对优化后的新方案进行了实现，本篇介绍新方案的一些测试与验证过程。代码可以参考 BBRAC 仓库的 &lt;a href="https://github.com/shuzang/BBRAC/tree/truffle" target="_blank">truffle&lt;/a> 分支，但是该分支包括后面添加的恶意行为检测的内容，是进行了二次完善后的代码。&lt;/p></description></item><item><title>书藏的生活周刊第 2 期 (20200110)</title><link>https://NamiChen.github.io/2020/life-weekly-2/</link><pubDate>Fri, 10 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-2/</guid><description>本周刊目的是记录生活，发现生活中的美好。当前为第二期 时讯 1、伊朗高级军官在伊拉克巴格达遭遇美军空袭身亡 01.03 央视新闻持续更新中。1月3日凌晨， 美</description></item><item><title>Ubuntu中无法获得锁相关问题的解决方案</title><link>https://NamiChen.github.io/2020/ubuntu%E4%B8%AD%E6%97%A0%E6%B3%95%E8%8E%B7%E5%BE%97%E9%94%81%E7%9B%B8%E5%85%B3%E9%97%AE%E9%A2%98%E7%9A%84%E8%A7%A3%E5%86%B3%E6%96%B9%E6%A1%88/</link><pubDate>Fri, 03 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/ubuntu%E4%B8%AD%E6%97%A0%E6%B3%95%E8%8E%B7%E5%BE%97%E9%94%81%E7%9B%B8%E5%85%B3%E9%97%AE%E9%A2%98%E7%9A%84%E8%A7%A3%E5%86%B3%E6%96%B9%E6%A1%88/</guid><description>Ubuntu环境下，Unable to acquire the lock这类问题时有发生，本文对该问题的解决方案做一个总结 E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable) E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is</description></item><item><title>书藏的生活周刊第 1 期 (20200103)</title><link>https://NamiChen.github.io/2020/life-weekly-1/</link><pubDate>Fri, 03 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/life-weekly-1/</guid><description>本系列受阮一峰大神的科技爱好者周刊启发，目的是记录生活。先前博客中的读书笔记、影评、游记、接触到的新的知识、收集的文章和句子、每周计划等内容</description></item><item><title>总有些美好的事情发生</title><link>https://NamiChen.github.io/2020/%E6%80%BB%E6%9C%89%E4%BA%9B%E7%BE%8E%E5%A5%BD%E7%9A%84%E4%BA%8B%E6%83%85%E5%8F%91%E7%94%9F/</link><pubDate>Wed, 01 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/%E6%80%BB%E6%9C%89%E4%BA%9B%E7%BE%8E%E5%A5%BD%E7%9A%84%E4%BA%8B%E6%83%85%E5%8F%91%E7%94%9F/</guid><description>总有些美好的事情发生 有些美好的人活着 哪怕我不曾遇见 哪怕不发生在我身上 这样的事啊 只想一想，就不孤独</description></item><item><title>特刊：2019年阅读、观影和旅行记录</title><link>https://NamiChen.github.io/2020/special-issue-2019-reading-film-viewing-and-travel-records/</link><pubDate>Wed, 01 Jan 2020 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2020/special-issue-2019-reading-film-viewing-and-travel-records/</guid><description>1. 书籍 1、罗敷，这么慢，那么美，2019-01 2、大学全集，2019-02 3、知乎周刊，我，一个人生活，2019-02 4、琢磨先生，以幽默的</description></item><item><title>Golang语法基础12-测试</title><link>https://NamiChen.github.io/2019/golang-syntax-12-test/</link><pubDate>Sun, 22 Dec 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-12-test/</guid><description>实际开发中对代码进行测试是不可缺少的工作，在go中可以通过testing包来进行代码的测试。testing包和go test命令相互配合，能够</description></item><item><title>Golang语法基础11-错误处理</title><link>https://NamiChen.github.io/2019/golang-syntax-11-error-and-panic/</link><pubDate>Fri, 20 Dec 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-11-error-and-panic/</guid><description>&lt;p>Go中有两套错误处理的方式&lt;/p>
&lt;ul>
&lt;li>普通错误： 在函数和方法中返回错误对象作为它们的唯一或最后一个返回值 ，如果返回nil，表示没有错误&lt;/li>
&lt;li>异常：使用panic和recover&lt;/li>
&lt;/ul>
&lt;p>主调函数总是应该检查收到的错误，不要忽略，否则可能导致严重的后果。&lt;/p></description></item><item><title>linux系统时间同步</title><link>https://NamiChen.github.io/2019/linux%E7%B3%BB%E7%BB%9F%E6%97%B6%E9%97%B4%E5%90%8C%E6%AD%A5/</link><pubDate>Fri, 20 Dec 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/linux%E7%B3%BB%E7%BB%9F%E6%97%B6%E9%97%B4%E5%90%8C%E6%AD%A5/</guid><description>虚拟机长时间不开机，系统时间和当前时间不同步，导致很多操作被拒绝，这里记录如何主动同步系统的时间和网络时间 正文 设置系统时区 1 $ timedatectl set-timezone Asia/Shanghai 安装nt</description></item><item><title>Golang语法基础10-协程与通道</title><link>https://NamiChen.github.io/2019/golang-syntax-10-goroutine-and-channel/</link><pubDate>Mon, 16 Dec 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-10-goroutine-and-channel/</guid><description>首先来回顾在操作系统中学过的一些概念。进程(processes)是程序执行的基本单位，运行在一个独立的内存地址空间中；一个进程由多个线程(t</description></item><item><title>穿搭整理3-保养、收纳及旧衣处理</title><link>https://NamiChen.github.io/2019/life-skills-9-maintenance-storage-and-disposal-of-used-clothes/</link><pubDate>Sun, 08 Dec 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/life-skills-9-maintenance-storage-and-disposal-of-used-clothes/</guid><description>正确的使用和保养可以延长衣物的使用时间，并使衣物看起来整洁干净，下面就对这些步骤做整理和介绍。 1. 概述 整篇文章的思路是根据面料进行处理，但最终</description></item><item><title>研究记录10-实验场景的分析与选择</title><link>https://NamiChen.github.io/2019/analysis-and-selection-of-experimental-scenes/</link><pubDate>Fri, 06 Dec 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/analysis-and-selection-of-experimental-scenes/</guid><description>&lt;p>考虑到开题时老师给的意见和编写论文的需要，这里再分析一次场景，并选择一个合适的纳入实验。&lt;/p></description></item><item><title>穿搭整理2-服装搭配及购买</title><link>https://NamiChen.github.io/2019/clothing-style-development-and-clothing-purchase/</link><pubDate>Thu, 05 Dec 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/clothing-style-development-and-clothing-purchase/</guid><description>&lt;p>穿搭的风格有很多种，我还是喜欢简约自然一点的，而且最重要的是，是我在穿衣服，不是衣服在挑我，为什么要被风格什么的限制住呢。最近看的一本书里有一句话我觉得很有道理，想象你穿着这件衣服去做什么事、去见什么人、说什么话、会不会大笑、行走坐卧，我觉得这才是购买和搭配的时候考虑的。这篇文章里只是记录一些搭配的基本原则和购买的一些技巧。&lt;/p></description></item><item><title>穿搭整理1-面料及服装分类</title><link>https://NamiChen.github.io/2019/fabric-and-clothing-classification/</link><pubDate>Sat, 30 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/fabric-and-clothing-classification/</guid><description>&lt;p>选择了国企以后，整个人一下子就放松了下来，感觉自己突然有很多时间去做自己想做的事情。最近这段时间就在看服装相关的知识，因为突然想到虽然我们从出生开始就与衣物打交道，但这方面的知识除了相关行业从业人员真的很少去了解，面料有哪些啊，衣服种类有哪些啊，怎么搭配衣服，买衣服要注意哪些事，怎么洗衣服更干净，怎么保养和收纳衣服，都不清楚，怪不得生活乱糟糟的，这一个系列主要就是学习和记录这些东西。另外，这一系列已同步发表在少数派。&lt;/p></description></item><item><title>研究记录9-区块链用于物联网访问控制梳理</title><link>https://NamiChen.github.io/2019/blockchain-based-access-control-for-iot/</link><pubDate>Fri, 29 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/blockchain-based-access-control-for-iot/</guid><description>这篇文章是关于区块链用于物联网访问控制的总结，有两个目的，一是梳理脑子里的思路，指导接下来的研究方向，二是作为之后要完成的小论文的参考。 在开</description></item><item><title>Golang语法基础8-结构体与方法</title><link>https://NamiChen.github.io/2019/golang-syntax-8-struct-and-method/</link><pubDate>Tue, 26 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-8-struct-and-method/</guid><description>&lt;p>结构体是一种非常重要的结构，用到的地方非常多，在 Go 中，结构体还是实现面向对象编程的基础。&lt;/p></description></item><item><title>Golang语法基础9-接口与反射</title><link>https://NamiChen.github.io/2019/golang-syntax-9-interface-and-reflect/</link><pubDate>Tue, 26 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-9-interface-and-reflect/</guid><description>&lt;p>本篇介绍 Golang 中的接口与反射。&lt;/p></description></item><item><title>区块链方向有参考价值的文章收集</title><link>https://NamiChen.github.io/2019/articles-about-blockchain/</link><pubDate>Tue, 26 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/articles-about-blockchain/</guid><description>很多区块链领域极有启发性的文章或者介绍极为详细的文章都很值得保存，以前直接将文章完整的转载过来，但最近发现这种方法占用空间而且毫无意义，因此</description></item><item><title>Golang语法基础7-函数</title><link>https://NamiChen.github.io/2019/golang-syntax-7-function/</link><pubDate>Mon, 25 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-7-function/</guid><description>1. 函数声明与定义 Go中有三种类型的函数： 普通的带有名字的函数 匿名函数 方法（Methods，在结构体部分介绍） 普通函数声明的基本格式为 1 func functionName(param1 type1,</description></item><item><title>医药健康5-医保及就医</title><link>https://NamiChen.github.io/2019/medicine-and-health-5-medical-insurance-and-medical-treatment/</link><pubDate>Sat, 23 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/medicine-and-health-5-medical-insurance-and-medical-treatment/</guid><description>上一篇对五险一金的介绍中已经提到了医保，本篇继续了解医保相关知识，以及医院等级、分类和就医流程。本文基本内容来自国家医疗保障局官网和网络。 1.</description></item><item><title>Golang语法基础6-数组、切片与映射</title><link>https://NamiChen.github.io/2019/golang-syntax-6-array-slice-and-map/</link><pubDate>Mon, 18 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-6-array-slice-and-map/</guid><description>只有基本的数据类型无法适应所有的情况，当需要存储和处理大量数据时，通常会使用数组、映射、链表等数据结构，称之为容器(container)。在</description></item><item><title>hugo搭建个人博客5-博客收集</title><link>https://NamiChen.github.io/2019/hugo-blog-themes-collection/</link><pubDate>Sun, 17 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/hugo-blog-themes-collection/</guid><description>本文用来收集喜欢的主题和有参考价值的博客(使用Hexo或Hugo的)。 主题 LeaveIt KeepIt LoveIt AllinOne hexo-theme-pure hexo-theme-Chic 博客 Yearito&amp;rsquo;s Blog 深入浅出区块链 Sirice&amp;rsquo;s Blog Mogeko&amp;rsquo;s Blog Wyane&amp;rsquo;s Blog Dillon&amp;rsquo;s Blog Orianna的</description></item><item><title>An ABAC Model in RFID Systems Based on DApp for Healthcare Environments</title><link>https://NamiChen.github.io/2019/an-abac-model-in-rfid-systems-based-on-dapp-for-healthcare-environments/</link><pubDate>Mon, 11 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/an-abac-model-in-rfid-systems-based-on-dapp-for-healthcare-environments/</guid><description>Figueroa, Añorga, and Arrizabalaga, “An Attribute-Based Access Control Model in RFID Systems Based on Blockchain Decentralized Applications for Healthcare Environments,” Computers, vol. 8, no. 3, p. 57, Jul. 2019, doi: 10.3390/computers8030057. Keywords: blockchain, smart contract, RFID, ABAC, access control, IoT, healthcare 1. 引言 在医疗领域</description></item><item><title>Golang语法基础5-字符串操作与输入输出</title><link>https://NamiChen.github.io/2019/golang-syntax-5-string-input-and-output/</link><pubDate>Mon, 11 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-5-string-input-and-output/</guid><description>&lt;p>本篇介绍字符串的相关操作，涉及&lt;code>string&lt;/code>和&lt;code>strconv&lt;/code>两个标准库，以及介绍输入输出的基本方法，涉及&lt;code>fmt&lt;/code>和&lt;code>bufio&lt;/code>两个标准库。&lt;/p></description></item><item><title>经济学常识-五险一金</title><link>https://NamiChen.github.io/2019/insurances-and-public-housing-fund/</link><pubDate>Sat, 09 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/insurances-and-public-housing-fund/</guid><description>&lt;p>经济是每个人都躲不开的东西，作为普通人，搞懂一些生活中的经济常识，能帮助我们活得更明白一点，这些知识包括缴税、理财、买房、养老、生育、贷款等等，都是与每个人息息相关的。本篇学习五险一金。&lt;/p></description></item><item><title>医药健康3-急救知识</title><link>https://NamiChen.github.io/2019/medicine-and-health-3-first-aid-knowledge/</link><pubDate>Thu, 07 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/medicine-and-health-3-first-aid-knowledge/</guid><description>日常生活中会遇到不少突发事件，如运动受伤、烧伤、溺水、中毒等，掌握一些常见的急救知识，并且在意外发生时沉着冷静，及时进行处理，可以减轻自己或</description></item><item><title>医药健康4-家庭常备药和工具</title><link>https://NamiChen.github.io/2019/medicine-and-health-4-family-standing-medicines-and-tools/</link><pubDate>Thu, 07 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/medicine-and-health-4-family-standing-medicines-and-tools/</guid><description>首先要知道可以买到的药物分为两种，一种是处方药，必须看医生才能买到，一种是非处方药，非处方药的包装上一般都有一个椭圆形标志，其中写着OCT，</description></item><item><title>以太坊开发8-Truffle框架安装使用</title><link>https://NamiChen.github.io/2019/use-truffle-develop-ethereum-project/</link><pubDate>Wed, 06 Nov 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/use-truffle-develop-ethereum-project/</guid><description>Truffle和Ganache的安装使用 1. 安装Truffle 在Ubuntu18.04 下安装运行，要求Node.js版本高于v8.9.4 1 2 3</description></item><item><title>研究记录8-原始论文问题总结及优化考虑</title><link>https://NamiChen.github.io/2019/summary-of-problems-and-optimization-considerations-about-prototype-system/</link><pubDate>Thu, 31 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/summary-of-problems-and-optimization-considerations-about-prototype-system/</guid><description>本文介绍在论文复现过程中发现的一些问题和自己产生的一些想法。与原论文1设计架构的对比可以查看本文最后的对比表，点这里 直接跳转。 1. 应用场景思考</description></item><item><title>Golang语法基础4-运算符与流程控制</title><link>https://NamiChen.github.io/2019/golang-syntax-4-operators-and-flow-control/</link><pubDate>Tue, 29 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-4-operators-and-flow-control/</guid><description>&lt;p>本文介绍 Golang 中的运算符和流程控制&lt;/p></description></item><item><title>区块链学习6-IBFT共识</title><link>https://NamiChen.github.io/2019/ibft-consensus/</link><pubDate>Tue, 29 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/ibft-consensus/</guid><description>AMIS公司提出的 Istanbul Byzantine Fault Tolerance Consensus（简称IBFT或Istanbul BFT），是一个基于PBFT的交易一致性的共识。因为要考虑可能发</description></item><item><title>SEC-BlockEdge Security Threats in Blockchain-Edge based IIoT Network</title><link>https://NamiChen.github.io/2019/sec-blockedge-security-threats-in-blockchain-edge-based-iiot-network/</link><pubDate>Thu, 24 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/sec-blockedge-security-threats-in-blockchain-edge-based-iiot-network/</guid><description>Kumar, Tanesh &amp;amp; Braeken, An &amp;amp; Ramani, Vidhya &amp;amp; Ahmad, Ijaz &amp;amp; Harjula, Erkki &amp;amp; Ylianttila, Mika. (2019). SEC-BlockEdge: Security Threats in Blockchain-Edge based Industrial IoT Networks. 以一个木屋建造场景作为IIoT用例，简要介绍了一个区块链-边缘计算框架。然后以此为基础</description></item><item><title>然后，我就一个人了</title><link>https://NamiChen.github.io/2019/%E7%84%B6%E5%90%8E%E6%88%91%E5%B0%B1%E4%B8%80%E4%B8%AA%E4%BA%BA%E4%BA%86/</link><pubDate>Thu, 24 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E7%84%B6%E5%90%8E%E6%88%91%E5%B0%B1%E4%B8%80%E4%B8%AA%E4%BA%BA%E4%BA%86/</guid><description>2019.10.24 从社交平台看到有人分享的山本文绪关于一个人生活的描写，起了兴趣，遂决定读一读。 山本文绪笔下一个人的生活： 我很喜欢一个人在家喝酒。先把房间打</description></item><item><title>Win10效率优化3-桌面整理</title><link>https://NamiChen.github.io/2019/efficient-use-of-win10-3-desktop-management/</link><pubDate>Wed, 23 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/efficient-use-of-win10-3-desktop-management/</guid><description>对任何系统来讲，桌面的整理都是重中之重。有些人喜欢文件触手可及，所有东西都放在桌面。有些人喜欢极简美观，桌面一尘不染，全部通过快速搜索完成。</description></item><item><title>Golang语法基础3-常量变量与基本数据类型</title><link>https://NamiChen.github.io/2019/golang-syntax-3-constants-variables-and-elementary-types/</link><pubDate>Tue, 22 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-syntax-3-constants-variables-and-elementary-types/</guid><description>&lt;p>本文介绍 Go 中的常量、变量、基本数据类型和常用的类型转换。&lt;/p></description></item><item><title>Win10效率优化1-综述</title><link>https://NamiChen.github.io/2019/efficient-use-of-win10-1-overview/</link><pubDate>Mon, 21 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/efficient-use-of-win10-1-overview/</guid><description>得益于苹果的生态，MacOS上的优秀软件不少，因此网上存在大量介绍如何利用Mac有效率的学习、工作和生活的文章。但对于Win10来说，这方面</description></item><item><title>Win10效率优化2-锁屏与登录</title><link>https://NamiChen.github.io/2019/efficient-use-of-win10-2-lockscreen-and-login/</link><pubDate>Mon, 21 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/efficient-use-of-win10-2-lockscreen-and-login/</guid><description>Win10 系统中，锁屏是我们登录系统前看到的一个界面。它的作用是当我们暂时离开电脑时阻止别人操作，但早晨当我们打开电脑时，第一眼看到也是锁屏界面，因</description></item><item><title>医药健康2-生活中的常见疾病</title><link>https://NamiChen.github.io/2019/medicine-and-health-2-common-disease/</link><pubDate>Sun, 20 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/medicine-and-health-2-common-disease/</guid><description>对人体结构、常见疾病的了解应该是一个人的基本生活能力，之前已经对用眼、睡眠、口腔的相关知识作了了解，这里对人体结构及重要器官分布，常见疾病作</description></item><item><title>张氏帅府及沈阳金融博物馆</title><link>https://NamiChen.github.io/2019/commander-zhangs-mansion/</link><pubDate>Fri, 18 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/commander-zhangs-mansion/</guid><description>时隔五年重游大帅府，早已物是人非。18年95周年校庆的时候东大与大帅府签了合约，共庆华诞，邀请全球校友回返参观。一年之后，19年10月，东大</description></item><item><title>信仰</title><link>https://NamiChen.github.io/2019/%E4%BF%A1%E4%BB%B0/</link><pubDate>Thu, 17 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E4%BF%A1%E4%BB%B0/</guid><description>15年思修课的作业，央视纪录片《信仰》的观后感 视频地址：http://tv.cntv.cn/videoset/C38054 看完《信仰》视频后</description></item><item><title>汉谟拉比法典</title><link>https://NamiChen.github.io/2019/%E6%B1%89%E8%B0%9F%E6%8B%89%E6%AF%94%E6%B3%95%E5%85%B8/</link><pubDate>Thu, 17 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E6%B1%89%E8%B0%9F%E6%8B%89%E6%AF%94%E6%B3%95%E5%85%B8/</guid><description>这篇读书笔记同样属于思修课的作业，写于2015年1月。 拿起《汉谟拉比法典》，静静品读三千七百年前的光明与黑暗，这部刻印在黑色玄武岩柱上的最古</description></item><item><title>罪与罚</title><link>https://NamiChen.github.io/2019/%E7%BD%AA%E4%B8%8E%E7%BD%9A/</link><pubDate>Thu, 17 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E7%BD%AA%E4%B8%8E%E7%BD%9A/</guid><description>这篇读书笔记其实写于2015年1月，属于思修课的作业，今天整理文档的时候看到了，记录在此。 《罪与罚》这部小说以主人公拉斯柯尔尼科夫犯罪及犯罪</description></item><item><title>Acceleration of Anomaly Detection in Blockchain Using In-GPU Cache</title><link>https://NamiChen.github.io/2019/acceleration-of-anomaly-detection-in-blockchain-using-in-gpu-cache/</link><pubDate>Wed, 16 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/acceleration-of-anomaly-detection-in-blockchain-using-in-gpu-cache/</guid><description>Morishima S, Matsutani H. Acceleration of anomaly detection in blockchain using in-GPU Cache[C]. international conference on big data and cloud computing, 2019: 244-251. 引言 区块链的不可篡改特性带来安全性的同时，由操作失误或密钥被盗造成的欺诈交易同样无法取消，因此</description></item><item><title>EdgeChain An Edge-IoT Framework and Prototype</title><link>https://NamiChen.github.io/2019/edgechain-an-edge-iot-framework-and-prototype/</link><pubDate>Tue, 15 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/edgechain-an-edge-iot-framework-and-prototype/</guid><description>EdgeChain设计 EdgeChain的核心思想是集成一个许可区块链和内部货币系统，将边缘云资源池与每个物联网设备的账户和资源使用行为关联</description></item><item><title>研究记录7-原始论文复现</title><link>https://NamiChen.github.io/2019/access-control-prototype-system-implementation/</link><pubDate>Tue, 15 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/access-control-prototype-system-implementation/</guid><description>&lt;p>本文是在前面搭建好的区块链实验平台基础上，对 Smart contract-based access control for the internet of things&lt;sup id="fnref:1">&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref">1&lt;/a>&lt;/sup> 这篇论文提出的访问控制方案进行复现，记录整个复现和测试的过程。&lt;/p></description></item><item><title>我还是喜欢你</title><link>https://NamiChen.github.io/2019/i-still-love-you/</link><pubDate>Mon, 14 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/i-still-love-you/</guid><description>我还是很喜欢你，像风走了八千里，不问归期。 我还是很喜欢你，像日月轮回交替，不理朝夕。 我还是很喜欢你，像云漂泊九万里，不曾歇息。 我还是很喜欢你</description></item><item><title>Securing Majority-Attack in Blockchain Using Machine Learning</title><link>https://NamiChen.github.io/2019/securing-majority-attack-in-blockchain-using-machine-learning/</link><pubDate>Thu, 10 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/securing-majority-attack-in-blockchain-using-machine-learning/</guid><description>Dey S. A Proof of Work: Securing Majority-Attack in Blockchain Using Machine Learning and Algorithmic Game Theory[J]. International Journal of Wireless and Microwave Technologies, 2018, 8(5): 1-9. Abstract 多数人攻击(majority-attack)对公链网络可能不是一个威胁，但对联盟链来</description></item><item><title>医药健康1-日常生活卫生</title><link>https://NamiChen.github.io/2019/medicine-and-health-1-daily-life-hygiene/</link><pubDate>Sat, 05 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/medicine-and-health-1-daily-life-hygiene/</guid><description>收集整理一些日常生活中要注意的一些个人卫生，养成良好的习惯，注意包括口腔，眼睛和睡眠三方面。 第一部分是关于健康方面的知识，包括以下几方面 日常</description></item><item><title>When Intrusion Detection Meets Blockchain Technology A Review</title><link>https://NamiChen.github.io/2019/when-intrusion-detection-meets-blockchain-technology-a-review/</link><pubDate>Thu, 03 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/when-intrusion-detection-meets-blockchain-technology-a-review/</guid><description>Meng W, Tischhauser E, Wang Q, et al. When Intrusion Detection Meets Blockchain Technology: A Review[J]. IEEE Access, 2018: 10179-10188. Abstract：以识别网络威胁和可能的事故为目的，入侵检测系统（IDS）已被广泛用于各种计算机网络</description></item><item><title>研究记录6-Quorum区块链实验平台搭建</title><link>https://NamiChen.github.io/2019/build-quorum-private-blockchain-network/</link><pubDate>Wed, 02 Oct 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/build-quorum-private-blockchain-network/</guid><description>&lt;p>上篇文章已经确定了使用 Quorum 区块链，本文记录搭建 Quorum 私有区块链网络的过程。值得一提的是，相比于之前区块链平台搭建的尝试，本篇所述内容已经是一个完整无冗余的方案，后续对区块链平台搭建过程的优化，更多的是根据具体情况进行取舍，以及使用新出的一些更好用的工具。&lt;/p></description></item><item><title>Git深入-子模块, 徽章, 开源协议</title><link>https://NamiChen.github.io/2019/git-learning-deep-into/</link><pubDate>Mon, 30 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/git-learning-deep-into/</guid><description>&lt;p>学习一些更高级或更有趣的 Git 用法，包括子模块、徽章、开源协议选择等。&lt;/p></description></item><item><title>hugo搭建个人博客4-主题美化</title><link>https://NamiChen.github.io/2019/hugo-blog-theme-beautify/</link><pubDate>Mon, 30 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/hugo-blog-theme-beautify/</guid><description>1. 基础知识 通过一个简单的主题开发流程，理解需要的基本知识，为自己进行主题修改和美化打基础，这里参考create a new theme一文。 开发准备 U</description></item><item><title>研究记录5-区块链与异常检测方向探索</title><link>https://NamiChen.github.io/2019/blockchain-and-anomaly-detection/</link><pubDate>Fri, 27 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/blockchain-and-anomaly-detection/</guid><description>对区块链进行异常检测（Anomaly detection）也是一个重要的方向，不过有的论文中也称作侵入检测（Intrusion detectio</description></item><item><title>废名田园小说</title><link>https://NamiChen.github.io/2019/%E5%BA%9F%E5%90%8D%E7%94%B0%E5%9B%AD%E5%B0%8F%E8%AF%B4/</link><pubDate>Sat, 21 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E5%BA%9F%E5%90%8D%E7%94%B0%E5%9B%AD%E5%B0%8F%E8%AF%B4/</guid><description>读完《老舍幽默小说》后不过瘾，但又想读轻松点的，遂又找了同系列的《废名田园小说》。 废名（1901-1967），原名冯文炳，中国现代文坛著名作</description></item><item><title>Golang语法基础2-命令、包与模块</title><link>https://NamiChen.github.io/2019/golang-basic-grammer-2-command-package-module/</link><pubDate>Thu, 19 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-basic-grammer-2-command-package-module/</guid><description>本篇介绍Go中的基础命令，包和模块。 1. 命令 Go 在安装后自带一个命令行工具，名为 go，用来下载、编译、安装、测试 Go 的包和源文件，关于 Go CLI 的发展历</description></item><item><title>老舍幽默小说</title><link>https://NamiChen.github.io/2019/%E8%80%81%E8%88%8D%E5%B9%BD%E9%BB%98%E5%B0%8F%E8%AF%B4/</link><pubDate>Mon, 16 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E8%80%81%E8%88%8D%E5%B9%BD%E9%BB%98%E5%B0%8F%E8%AF%B4/</guid><description>9月8日在图书馆闲逛，找到了新文艺的《老舍幽默小说》，同系列还有不少名家的小说集，但以幽默最爱，故先看老舍的作品，至昨日，经两周，终于看完，</description></item><item><title>白塔，弥陀寺及碧霞宫</title><link>https://NamiChen.github.io/2019/scaleless-net-light-tower/</link><pubDate>Sun, 15 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/scaleless-net-light-tower/</guid><description>乘坐公交的路上，经常能看到一座古建筑风格的院落，以及白塔堡的一座白塔。这座白塔确是能做到看第一眼就让人觉得白塔此名名副其实。恰逢朋友相约，便</description></item><item><title>Golang语法基础1-背景与初探</title><link>https://NamiChen.github.io/2019/golang-basic-grammar-1-background-and-preliminary-exploration/</link><pubDate>Fri, 13 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang-basic-grammar-1-background-and-preliminary-exploration/</guid><description>1. 起源与发展 Go/Golang 起源于2007年，并于2009年正式对外发布，是一个完全开源的项目，背后的支持者是谷歌公司，核心设计者是三位著名IT工程师：K</description></item><item><title>研究记录4-利用虚拟机搭建实验平台(失败)</title><link>https://NamiChen.github.io/2019/using-virtual-machine-to-build-experimental-platform/</link><pubDate>Fri, 13 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/using-virtual-machine-to-build-experimental-platform/</guid><description>先声明结论：最后由于网络原因没有成功，这种在多台电脑中安装虚拟机来联网的方式是存在一定问题的，其次，本篇所述的搭建方法过于繁琐，稍有不慎需要</description></item><item><title>VMware虚拟机使用技巧</title><link>https://NamiChen.github.io/2019/vmware-usage/</link><pubDate>Fri, 06 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/vmware-usage/</guid><description>双系统时常折腾容易坏电脑，因此一般是在虚拟机中使用Linux系统，常用的虚拟机为VMware，本文对VMware的相关知识以及使用过程中的一</description></item><item><title>树莓派和虚拟机组网出现的问题及解决思路</title><link>https://NamiChen.github.io/2019/%E6%A0%91%E8%8E%93%E6%B4%BE%E5%92%8C%E8%99%9A%E6%8B%9F%E6%9C%BA%E7%BB%84%E7%BD%91%E5%87%BA%E7%8E%B0%E7%9A%84%E9%97%AE%E9%A2%98%E5%8F%8A%E8%A7%A3%E5%86%B3%E6%80%9D%E8%B7%AF/</link><pubDate>Fri, 06 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E6%A0%91%E8%8E%93%E6%B4%BE%E5%92%8C%E8%99%9A%E6%8B%9F%E6%9C%BA%E7%BB%84%E7%BD%91%E5%87%BA%E7%8E%B0%E7%9A%84%E9%97%AE%E9%A2%98%E5%8F%8A%E8%A7%A3%E5%86%B3%E6%80%9D%E8%B7%AF/</guid><description>小米随身WiFi拥有两种模式，网卡模式可以令电脑搜索并接入其它的WiFi，AP模式可以开启一个WiFi供别的设备加入。现在拥有一台主机，插在</description></item><item><title>树莓派使用网线直连电脑</title><link>https://NamiChen.github.io/2019/%E6%A0%91%E8%8E%93%E6%B4%BE%E4%BD%BF%E7%94%A8%E7%BD%91%E7%BA%BF%E7%9B%B4%E8%BF%9E%E7%94%B5%E8%84%91/</link><pubDate>Wed, 04 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E6%A0%91%E8%8E%93%E6%B4%BE%E4%BD%BF%E7%94%A8%E7%BD%91%E7%BA%BF%E7%9B%B4%E8%BF%9E%E7%94%B5%E8%84%91/</guid><description>树莓派刷好系统，要进行联网使用，手里没有显示屏和HDMI线，实验室没有路由器，电脑也没有无线网卡，唯一的网口也被占用。只能通过网线和USB网</description></item><item><title>树莓派常用设置</title><link>https://NamiChen.github.io/2019/%E6%A0%91%E8%8E%93%E6%B4%BE%E5%B8%B8%E7%94%A8%E8%AE%BE%E7%BD%AE/</link><pubDate>Wed, 04 Sep 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E6%A0%91%E8%8E%93%E6%B4%BE%E5%B8%B8%E7%94%A8%E8%AE%BE%E7%BD%AE/</guid><description>记录树莓派使用过程中经常使用的一些设置。 1. WiFi连接 这里指的是初次启动直连WiFi，主要是因为手里没有屏幕，因为使用的小米随身WiFi，所</description></item><item><title>一个人的朝圣</title><link>https://NamiChen.github.io/2019/%E4%B8%80%E4%B8%AA%E4%BA%BA%E7%9A%84%E6%9C%9D%E5%9C%A3/</link><pubDate>Thu, 29 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E4%B8%80%E4%B8%AA%E4%BA%BA%E7%9A%84%E6%9C%9D%E5%9C%A3/</guid><description>1个人，87天，627英里。有关爱的回归、自我发现、日常生活的信念以及万物之美。当再次看到简介中的这段字，我终于明白了这本书的意义。 哈罗德·</description></item><item><title>一禅小和尚</title><link>https://NamiChen.github.io/2019/%E4%B8%80%E7%A6%85%E5%B0%8F%E5%92%8C%E5%B0%9A/</link><pubDate>Wed, 28 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E4%B8%80%E7%A6%85%E5%B0%8F%E5%92%8C%E5%B0%9A/</guid><description>其实我是对漫画没什么兴趣的，但是在微信读书看到小和尚的第一眼，就沉沦了进去，小和尚的形象仿佛能轻易击穿人的心房。故事中的小和尚同样如此，一禅</description></item><item><title>Golang查漏补缺-bufio读取的字符串无法直接进行类型转换</title><link>https://NamiChen.github.io/2019/golang%E6%9F%A5%E6%BC%8F%E8%A1%A5%E7%BC%BA-bufio%E8%AF%BB%E5%8F%96%E7%9A%84%E5%AD%97%E7%AC%A6%E4%B8%B2%E6%97%A0%E6%B3%95%E7%9B%B4%E6%8E%A5%E8%BF%9B%E8%A1%8C%E7%B1%BB%E5%9E%8B%E8%BD%AC%E6%8D%A2/</link><pubDate>Tue, 27 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang%E6%9F%A5%E6%BC%8F%E8%A1%A5%E7%BC%BA-bufio%E8%AF%BB%E5%8F%96%E7%9A%84%E5%AD%97%E7%AC%A6%E4%B8%B2%E6%97%A0%E6%B3%95%E7%9B%B4%E6%8E%A5%E8%BF%9B%E8%A1%8C%E7%B1%BB%E5%9E%8B%E8%BD%AC%E6%8D%A2/</guid><description>如下列代码，在使用bufio包中的ReadString读取字符串之后，这个字符串无法进行类型转换，每次使用strconv.Atoi()函数返</description></item><item><title>愿</title><link>https://NamiChen.github.io/2019/i-wish-you/</link><pubDate>Mon, 26 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/i-wish-you/</guid><description>愿你三冬暖，愿你春不寒 愿你天黑有灯，下雨有伞 愿你一路上，有良人相伴 愿你所有快乐，无需假扮 愿你此生尽兴，赤诚良善 愿时光能缓，愿故人不散 愿有人陪</description></item><item><title>古生物博物馆及沈飞航空博物馆</title><link>https://NamiChen.github.io/2019/paleontological-museum-of-liaoning/</link><pubDate>Sat, 24 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/paleontological-museum-of-liaoning/</guid><description>08.24，又一个周六，从旅游软件中得知古生物博物馆周六日开馆，欣然前往，然后发现上周错过的航空博物馆竟然在路上，于是返程途中开森的进去了。</description></item><item><title>北陵公园及新乐遗址</title><link>https://NamiChen.github.io/2019/beiling-park/</link><pubDate>Sat, 17 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/beiling-park/</guid><description>08.17，周六，前往游览了北陵公园，北陵公园核心的昭陵，祭拜了公园中偶然发现的烈士陵园，最后参观了北陵附近的新乐遗址。 北陵公园 北陵公园是辽</description></item><item><title>Golang查漏补缺-对自定义类型排序</title><link>https://NamiChen.github.io/2019/golang%E6%9F%A5%E6%BC%8F%E8%A1%A5%E7%BC%BA-%E5%AF%B9%E8%87%AA%E5%AE%9A%E4%B9%89%E7%B1%BB%E5%9E%8B%E6%8E%92%E5%BA%8F/</link><pubDate>Fri, 16 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang%E6%9F%A5%E6%BC%8F%E8%A1%A5%E7%BC%BA-%E5%AF%B9%E8%87%AA%E5%AE%9A%E4%B9%89%E7%B1%BB%E5%9E%8B%E6%8E%92%E5%BA%8F/</guid><description>PAT乙级25分的题好多需要根据一个结构体类型的某个字段进行排序，第一次遇到时确实不知所措，然后查了不少解决方案，这里做个总结。 这一问题一般</description></item><item><title>Golang查漏补缺-程序执行时间优化</title><link>https://NamiChen.github.io/2019/golang%E6%9F%A5%E6%BC%8F%E8%A1%A5%E7%BC%BA-%E7%A8%8B%E5%BA%8F%E6%89%A7%E8%A1%8C%E6%97%B6%E9%97%B4%E4%BC%98%E5%8C%96/</link><pubDate>Fri, 16 Aug 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/golang%E6%9F%A5%E6%BC%8F%E8%A1%A5%E7%BC%BA-%E7%A8%8B%E5%BA%8F%E6%89%A7%E8%A1%8C%E6%97%B6%E9%97%B4%E4%BC%98%E5%8C%96/</guid><description>最近在刷PAT乙级的题，因为PAT考点一般只提供C/C++或Java环境的缘故，网上找到的90%都是C++代码，剩下的又绝大部分是Java，</description></item><item><title>研究记录3-开题确定题目</title><link>https://NamiChen.github.io/2019/research-proposal-title-select/</link><pubDate>Sun, 14 Jul 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/research-proposal-title-select/</guid><description>待选题目 基于区块链的智能工厂支撑平台研究与设计 基于区块链的智能工厂存储与安全问题研究 基于智能合约的物联网访问控制方案设计与实现 基于区块链的物</description></item><item><title>hugo搭建个人博客3-进阶设置</title><link>https://NamiChen.github.io/2019/hugo-blog-advanced-setup/</link><pubDate>Fri, 12 Jul 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/hugo-blog-advanced-setup/</guid><description>本文是 Hugo 使用记录的第二篇，介绍如何为Hugo开启更多的功能。 1. 添加菜单栏页面 我们可以自己建立新的菜单页面1 ，比如我新建life页面用作展示阅</description></item><item><title>科学精神与人文素养</title><link>https://NamiChen.github.io/2019/%E7%A7%91%E5%AD%A6%E7%B2%BE%E7%A5%9E%E4%B8%8E%E4%BA%BA%E6%96%87%E7%B4%A0%E5%85%BB/</link><pubDate>Mon, 01 Jul 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E7%A7%91%E5%AD%A6%E7%B2%BE%E7%A5%9E%E4%B8%8E%E4%BA%BA%E6%96%87%E7%B4%A0%E5%85%BB/</guid><description>该部分收集翟天临事件及其它学术不端案例 课程作业，简单的收集翟天临事件和一些其它的学术不端案例，做一些评价。 1. 案例 1.1 翟天临事件 翟天临事件的发酵</description></item><item><title>A Novel Attribute-Based Access Control Scheme Using Blockchain for IoT</title><link>https://NamiChen.github.io/2019/a-novel-attribute-based-access-control-scheme-using-blockchain-for-iot/</link><pubDate>Mon, 03 Jun 2019 15:51:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/a-novel-attribute-based-access-control-scheme-using-blockchain-for-iot/</guid><description>&lt;p>Ding, Sheng, et al. &amp;ldquo;A Novel Attribute-Based Access Control Scheme Using Blockchain for IoT.&amp;rdquo; &lt;em>IEEE Access&lt;/em> 7 (2019): 38431-38441.&lt;/p>
&lt;p>DOI: &lt;a href="https://doi-org-s.webvpn.neu.edu.cn/10.1109/ACCESS.2019.2905846" target="_blank">10.1109/ACCESS.2019.2905846&lt;/a>&lt;/p>
&lt;p>KeyWord: Access control, attribute-based access control, blockchain, consortium blockchain, IoT&lt;/p>
&lt;p>注：插图经过重新绘制，照片来自原论文截图。&lt;/p>
&lt;h2 id="1-摘要">1. 摘要&lt;/h2>
&lt;p>随着智能设备数量的急剧增加，物联网近年来得到越来越多的关注和快速发展。它通过现有的网络基础设施有效地将物理世界与Internet集成在一起，以便在智能设备之间共享数据。然而，其复杂的大规模网络结构给物联网系统带来了新的安全风险和挑战。为了保证数据的安全性，传统的访问控制技术由于其复杂的访问管理和集中性导致可靠性不足，不适合直接用于物联网系统的访问控制。本文提出了一种新的基于属性的用于物联网系统的访问控制方案，大大简化了访问管理。我们使用区块链技术来记录属性的分发，以避免单点故障和数据篡改。访问控制过程也进行了优化，以满足对物联网设备进行高效和轻量化计算的需要。安全性和性能分析表明，该方案能够有效抵御多种攻击，并能在物联网系统中得到有效的实现。&lt;/p></description></item><item><title>A Blockchain-Based Solution for Enhancing Security and Privacy in Smart Factory</title><link>https://NamiChen.github.io/2019/a-blockchain-based-solution-for-enhancing-security-and-privacy-in-smart-factory/</link><pubDate>Fri, 24 May 2019 21:18:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/a-blockchain-based-solution-for-enhancing-security-and-privacy-in-smart-factory/</guid><description>&lt;p>Wan J, Li J, Imran M, et al. A Blockchain-Based Solution for Enhancing Security and Privacy in Smart Factory[J]. IEEE Transactions on Industrial Informatics, 2019.&lt;/p>
&lt;p>被引：2次&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>通过IIoT，智能工厂进入了蓬勃发展的时期。但是，随着节点数量和网络规模的扩大，传统的IIoT架构无法再为这样庞大的系统提供有效支持。因此，我们引入了区块链。它是一种用于构建分布式网络的新兴方案，用于重塑传统的IIoT架构。首先，分析了传统IIoT架构的主要问题，总结了现有的改进。其次，我们引入了一个安全和隐私模型来帮助设计基于区块链的架构。在此基础上，我们分解并重新组织原始的IIoT架构，以形成一个新的，多中心，部分分散的架构。然后，我们引入一些相关的安全技术，以改进和优化新架构。之后，我们设计了数据交互过程和架构的算法。最后，我们使用自动生产平台来讨论具体的实现。实验结果表明，与传统架构相比，该架构提供了更好的安全性和隐私保护。因此，所提出的架构代表了原始架构的重大改进，这为IIoT开发提供了新的方向&lt;/p>
&lt;blockquote>
&lt;p>原因：节点数量和网络规模扩大，传统的IIoT架构无法再为这样庞大的系统提供有效支持。&lt;/p>
&lt;ol>
&lt;li>传统IIoT问题和现有改进（Section I）&lt;/li>
&lt;li>设计基于区块链的架构(Section II)&lt;/li>
&lt;li>安全与隐私模型(Section III)&lt;/li>
&lt;li>设计数据交互过程和算法(Section IV)&lt;/li>
&lt;li>使用自动生产平台具体实施(Section V)&lt;/li>
&lt;/ol>
&lt;/blockquote></description></item><item><title>A Review on the Application of Blockchain to the Next Generation</title><link>https://NamiChen.github.io/2019/a-review-on-the-application-of-blockchain-to-the-next-generation/</link><pubDate>Thu, 23 May 2019 17:11:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/a-review-on-the-application-of-blockchain-to-the-next-generation/</guid><description>&lt;p>Fernández-Caramés T M, Fraga-Lamas P. A Review on the Application of Blockchain for the Next Generation of Cybersecure Industry 4.0 Smart Factories[J]. arXiv preprint arXiv:1902.09604, 2019.&lt;/p>
&lt;p>DOI: &lt;a href="https://doi.org/10.1109/ACCESS.2019.2908780" target="_blank">10.1109/ACCESS.2019.2908780&lt;/a>&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>工业4.0是一个旨在通过使用一些最新技术改进现代工厂运作方式的概念，例如用于创建工业物联网（IIoT），机器人或大数据应用的技术。其中一种技术是区块链，它能够为不同的工业领域增加信任，安全性和去中心化特性。本文重点分析使用区块链和智能合约开发工业4.0应用时产生的好处和挑战。此外，本文还对工业4.0技术中最相关的基于区块链的应用进行了全面的回顾。因此，其目的是为未来的工业4.0开发人员提供详细指南，以确定区块链如何增强下一代网络工业应用的网络安全。&lt;/p></description></item><item><title>hugo搭建个人博客2-文章写作</title><link>https://NamiChen.github.io/2019/hugo-blog-article-write/</link><pubDate>Wed, 15 May 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/hugo-blog-article-write/</guid><description>本文是 Hugo 使用记录的第二篇，介绍关于文章写作的一些问题，包括分类管理、排版技巧、特殊语法等，所有语法基于 LoveIt 主题。 Hugo支持的文章格式为.md</description></item><item><title>Smart Contract-Based Access Control for the Internet of Things</title><link>https://NamiChen.github.io/2019/smart-contract-based-access-control-for-the-internet-of-things/</link><pubDate>Tue, 14 May 2019 19:10:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/smart-contract-based-access-control-for-the-internet-of-things/</guid><description>Zhang Y, Kasahara S, Shen Y, et al. Smart contract-based access control for the internet of things[J]. IEEE Internet of Things Journal, 2018. 被引：35次 Abstract 该论文调查了物联网中的访问控制问题。提出了一个基于智能合约的访问控制框架，该框架</description></item><item><title>Authentication and Authorization for the Internet of Things</title><link>https://NamiChen.github.io/2019/authentication-and-authorization-for-the-internet-of-things/</link><pubDate>Tue, 14 May 2019 15:14:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/authentication-and-authorization-for-the-internet-of-things/</guid><description>&lt;p>Kim H, Lee E A. Authentication and Authorization for the Internet of Things[J]. IT Professional, 2017, 19(5): 27-33.&lt;/p>
&lt;p>核心：locally centralized, globally distributed的认证与授权&lt;/p>
&lt;p>引入：由2016年DNS服务商Dyn受到的DDoS攻击说明物联网带来的安全挑战。由2015年乌克兰电网受到的攻击说明物联网遭受攻击的后果更具破坏性。这两者反映的是，物联网设备缺乏相应的访问控制机制，导致面对攻击不够健壮。&lt;/p></description></item><item><title>Blockchain Paradigm and Internet of Things</title><link>https://NamiChen.github.io/2019/blockchain-paradigm-and-internet-of-things/</link><pubDate>Mon, 13 May 2019 15:42:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/blockchain-paradigm-and-internet-of-things/</guid><description>&lt;p>Valentin Rakovic， Jovan Karamachoski，Vladimir Atanasovski，Liljana Gavrilovska&lt;/p>
&lt;p>Published online: 21 March 2019&lt;/p>
&lt;p>Wireless Personal Communications (2019) 106:219–235
&lt;a href="https://doi.org/10.1007/s11277-019-06270-9">https://doi.org/10.1007/s11277-019-06270-9&lt;/a>&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>区块链是在分布式网络中提供隐私和安全的分布式分类账技术，这使得它适用于具有分布式特性的物联网。然而，区块链需要高计算能力，有高带宽开销和延迟，不适合物联网场景，为了将区块链和物联网结合，许多研究旨在开发针对于特定物联网场景需求的区块链方法。本文详细介绍了物联网区块链集成的相关问题，对当前文献和相关部署测试做了全面调查，指出了当前主要的研究和面临的挑战，并讨论了未来可能的研究领域。&lt;/p></description></item><item><title>hugo搭建个人博客1-基础建站</title><link>https://NamiChen.github.io/2019/hugo-blog-build-personal-blog/</link><pubDate>Fri, 26 Apr 2019 10:45:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/hugo-blog-build-personal-blog/</guid><description>Hugo 是由 Go 语言实现的静态网站生成器，可以快速建立一个静态网站，虽然多数情况下用来搭建个人博客，但也可以用作展示在线书籍、个人简历等。在使用 Hugo 之</description></item><item><title>生命清单</title><link>https://NamiChen.github.io/2019/%E7%94%9F%E5%91%BD%E6%B8%85%E5%8D%95/</link><pubDate>Thu, 25 Apr 2019 16:05:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/%E7%94%9F%E5%91%BD%E6%B8%85%E5%8D%95/</guid><description>一开始看到这本书的时候，我以为这是一本关于梦想的书，就像是《白日梦想家》那样，描述一个人在即将去世前鼓起勇气去完成自己生命清单的事。但是我错</description></item><item><title>Industry 4.0 Development and Application of Intelligent Manufacturing</title><link>https://NamiChen.github.io/2019/industry-4.0-development-and-application-of-intelligent-manufacturing/</link><pubDate>Mon, 15 Apr 2019 14:22:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/industry-4.0-development-and-application-of-intelligent-manufacturing/</guid><description>&lt;p>Author：Guo-Jian Cheng, Li-Ting Liu, Xin-Jian Qiang, Ye Liu&lt;/p>
&lt;p>Published in：2016 International Conference on Information System and Artificial Intelligence (ISAI)&lt;/p>
&lt;p>Conference Location：Hong Kong, China&lt;/p>
&lt;p>Cited times：30&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>过去几年，工业和信息技术领域经历了深刻的变革，进入了工业4.0时代，将从嵌入式系统演变到网络物理系统（CPS）。制造业将通过互联网，整合内部和外部网络，朝着智能化方向发展。本文介绍工业4.0的发展，并以120的智慧信息技术（WIT120）为例介绍网络物理系统，然后通过数字工厂到智能工厂的例子介绍工业4.0在智能制造中的应用。最后分析工业4.0在未来的发展方向，为其在智能制造中的应用提供参考。&lt;/p></description></item><item><title>提取以太坊的区块产生时间</title><link>https://NamiChen.github.io/2019/extract-the-block-generation-time-of-ethereum/</link><pubDate>Fri, 05 Apr 2019 21:35:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/extract-the-block-generation-time-of-ethereum/</guid><description>&lt;h2 id="前言">前言&lt;/h2>
&lt;p>目的是提取以太坊的区块产生时间形成数据集，初步的思路有两种：&lt;/p>
&lt;ul>
&lt;li>爬取以太坊区块浏览器中的时间数据，然后格式化形成数据集输出&lt;/li>
&lt;li>同步以太坊的所有区块（头），利用以太坊本身提供的接口提取每个区块的时间戳信息，然后将时间戳转换为真实的日期格式形成数据集输出，&lt;a href="https://tool.lu/timestamp/" target="_blank">时间戳转换在线工具&lt;/a>&lt;/li>
&lt;/ul>
&lt;p>查询资料过程中，了解到谷歌已提供以太坊的区块信息数据集&lt;sup id="fnref:1">&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref">1&lt;/a>&lt;/sup>。虽然数据集本身没有时间信息，但可以导出时间戳进行转换，了解到谷歌使用的工具是&lt;a href="https://github.com/blockchain-etl/ethereum-etl#blockscsv" target="_blank">ethereum-etl&lt;/a>，故最终的解决方案是：使用ethereum-etl导出时间戳，编写Python程序转换时间戳并导出数据集。&lt;/p></description></item><item><title>研究记录2-区块链平台选择的思考</title><link>https://NamiChen.github.io/2019/blockchain-platform-compare-and-select/</link><pubDate>Mon, 01 Apr 2019 13:11:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/blockchain-platform-compare-and-select/</guid><description>首先我们就 Ethereum 等九个平台做分析比较，从而确定要用来作为实验平台的区块链。 1. Ethereum 关于存储 以太坊生态中的一些工具和技术是用来解决大数据量存储问题的，</description></item><item><title>Distributed Blockchain-Based Data Protection Framework for Modern Power Systems</title><link>https://NamiChen.github.io/2019/distributed-blockchain-based-data-protection-framework-for-modern-power-systems/</link><pubDate>Mon, 01 Apr 2019 11:16:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/distributed-blockchain-based-data-protection-framework-for-modern-power-systems/</guid><description>&lt;p>Author：Gaoqi Liang , Steven R. Weller, Fengji Luo , Junhua Zhao, Zhao Yang Dong&lt;/p>
&lt;p>Published in：IEEE Transactions on Smart Grid 2018(Early Access)&lt;/p>
&lt;p>期刊级别：SCI I区&lt;/p>
&lt;p>被引量：19次&lt;/p>
&lt;p>keywords：Blockchain, Modern power systems, Cyber-attacks, Distributed network, False data injection attacks&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>现代电力系统的网络安全同时吸引了学术和工业界的关注，许多针对网络攻击的检测和防御手段因此而被提出。本文提出了一种新的基于区块链的分布式保护框架，用于增强现代电力系统应对网络攻击的自抵御能力。我们对区块链技术如何用于增强电网鲁棒性和安全性做了全面的讨论，使用电表作为分布式网络的节点，将电表的测量数据打包为区块。所提出方案的有效性通过基于IEEE-118节点系统的仿真实验来说明。&lt;/p></description></item><item><title>秦皇求仙入海处及孟姜女庙</title><link>https://NamiChen.github.io/2019/meng-jiangnu-temple/</link><pubDate>Sat, 30 Mar 2019 20:51:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/meng-jiangnu-temple/</guid><description>2019年3月30日，自上周去过箭馆射箭之后，本周按原定计划前往秦皇求仙入海处及港口博物馆。 秦皇求仙入海处 由31路转8路抵达求仙入海处正门，</description></item><item><title>以太坊开发7-swarm存储网络使用</title><link>https://NamiChen.github.io/2019/swarm-storage-network-using/</link><pubDate>Thu, 28 Mar 2019 19:59:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/swarm-storage-network-using/</guid><description>&lt;p>说实话，swarm的资料比较难找，倒是IPFS的比较多一点。最后只在&lt;a href="http://medium.com/" target="_blank">Medium&lt;/a>找到了一些，本篇文章就是在实践其中的一些项目，并通过这样来学习swarm。&lt;/p>
&lt;p>参考链接：&lt;a href="https://swarm-gateways.net/bzz:/theswarm.eth/" target="_blank">swarm官网&lt;/a>，&lt;a href="https://swarm-guide.readthedocs.io/en/latest/introduction.html" target="_blank">swarm文档&lt;/a>，&lt;a href="https://github.com/ethersphere" target="_blank">github项目&lt;/a>&lt;/p>
&lt;p>还有一些帮助理解的资料：&lt;/p>
&lt;ul>
&lt;li>
&lt;p>&lt;a href="https://ethereum.stackexchange.com/questions/55027/swarm-in-a-private-network" target="_blank">关于swarm的三个理解上的问题&lt;/a>&lt;/p>
&lt;/li>
&lt;li>
&lt;p>&lt;a href="https://github.com/ethersphere/go-ethereum/wiki/IPFS-&amp;amp;-SWARM" target="_blank">swarm和ipfs的比较&lt;/a>&lt;/p>
&lt;/li>
&lt;/ul></description></item><item><title>树莓派项目构想-扫地机器人</title><link>https://NamiChen.github.io/2019/raspberry-project-sweeping-robot/</link><pubDate>Tue, 26 Mar 2019 19:40:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/raspberry-project-sweeping-robot/</guid><description>&lt;h2 id="前言">前言&lt;/h2>
&lt;p>本文是创新创业的结课报告，结课报告的题目要求如下：&lt;/p>
&lt;ul>
&lt;li>通过课程学习、课下查阅网络与图文资料，了解和掌握树莓派的功能、扩展性与应用领域（树莓派的典型和非典型应用）&lt;/li>
&lt;li>深入分析某一个具体行业或工作的工作特点，找到痛点难点，并分析树莓派的适用性（树莓派的什么特点使其适合用于解决这一问题）&lt;/li>
&lt;li>基于树莓派的功能，讨论如何通过增加相应的软硬件（传感器、软件模块、算法库……等），满足所关注的问题&lt;/li>
&lt;li>以“开发产品原型并吸引风投”为目标，完成一份创业项目计划书&lt;/li>
&lt;/ul>
&lt;p>注：不要求完成实际作品，而是强调基于技术的创意、运用工具和所学知识解决实际问题的能力、分析评价项目商业价值的能力&lt;/p></description></item><item><title>A Case Study for Blockchain in Manufacturing “FabRec”</title><link>https://NamiChen.github.io/2019/a-case-study-for-blockchain-in-manufacturing-fabrec/</link><pubDate>Mon, 25 Mar 2019 10:13:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/a-case-study-for-blockchain-in-manufacturing-fabrec/</guid><description>&lt;p>Author：Atin Angrisha, Benjamin Cravera, Mahmud Hasana, Binil Starly&lt;/p>
&lt;p>Published in：46th SME North American Manufacturing Research Conference, NAMRC 46, Texas, USA&lt;/p>
&lt;p>被引量：7次&lt;/p>
&lt;p>keywords：blockchain; cyber-physical systems; smart contracts; ethereum; decentralized networks; shareable databases&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>随着产品定制成为新的商机，制造商必须找到在无信任网络中进行协作和实现信息共享的方法。在本文中，我们提出“FabRec”：一种用于处理由各制造商使用区块链技术产生的制造信息的方法。其中，制造机器和计算节点构成去中心化网络来实现制造过程的自动化与透明化，基于对历史记录的审计实现对制造过程的第三方验证，使用智能合约实现参与者之间无纸化合同。同时，系统将与制造相关的信息分类，并使其在P2P网络上可用，以通过可验证的审计跟踪确保透明度和数据来源。我们通过组合制造机器，片上系统（SoC, System on chip）和计算节点来建立测试平台，以展示组成联盟的不同制造商可以通过分布式网络进行通信的机制。我们的测试平台原型展示了驻留在分布式网络上的计算机代码的价值：用于验证区块链的信息以及在物理世界中自动启动操作的方式。本文旨在通过测试平台揭示系统组成，为更大规模的测试做准备，并讨论区块链在制造业的未来潜力。&lt;/p></description></item><item><title>LightChain:A Lightweight Blockchain System for Industrial Internet of Things</title><link>https://NamiChen.github.io/2019/lightchaina-lightweight-blockchain-system-for-industrial-internet-of-things/</link><pubDate>Tue, 19 Mar 2019 11:00:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/lightchaina-lightweight-blockchain-system-for-industrial-internet-of-things/</guid><description>&lt;p>Author： Yinqiu Liu, Kun Wang, Yun Lin, and Wenyao Xu&lt;/p>
&lt;p>Published in：IEEE Transactions on Industrial Informatics&lt;/p>
&lt;p>State：Early Access&lt;/p>
&lt;p>Index Terms：Blockchain, Industrial Internet of Things, Distributed System, Consensus Mechanism, Data Filter.&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>虽然区块链和IIoT之间的结合得到了广泛的关注，但区块链的高资源需求和IIoT设备的有限性能之间的矛盾还无法较好的解决。一方面，由于公钥结构、默克尔树和PoW等数学概念的引入，部署区块链需要巨大的算力；另一方面，全节点应该能同步大量的区块数据和处理P2P网络中的大量交易。IIoT设备难以承受其对存储容量和带宽的占用。本文中，我们提出了名为&lt;strong>LightChain&lt;/strong>的轻量级区块链使其适用于IIoT场景，提出了一个名为**Synergistic Multiple Proof（SMP）&lt;strong>的共识机制来促进IIoT设备间的合作，提出了一种称为&lt;/strong>LightBlock（LB）**的轻量级数据结构，用于简化广播内容。此外，还设计了一种 **Unrelated Block Offloading Filter (UBOF)**以避免分类帐的无限增长，同时不影响区块链的可追溯性。实验表明，LightChain可以将计算成本降低39.32％，将块生成速度提高74.06％。在存储和网络使用方面，降幅分别为43.35％和90.55％。&lt;/p></description></item><item><title>研究记录1-区块链的数据存储问题</title><link>https://NamiChen.github.io/2019/data-storage-in-blockchain/</link><pubDate>Sat, 16 Mar 2019 09:11:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/data-storage-in-blockchain/</guid><description>区块链的本质是一个只增数据库，这就意味着其中存储的数据会随着时间的推移不断增加，而区块链分布式的特性要求节点需要存储区块链的整个副本，因此，</description></item><item><title>利用树莓派作为服务器建立动态博客</title><link>https://NamiChen.github.io/2019/using-virtual-machine-as-raspberry-pi-server-to-build-dynamic-blog/</link><pubDate>Wed, 13 Mar 2019 14:32:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/using-virtual-machine-as-raspberry-pi-server-to-build-dynamic-blog/</guid><description>1. 前言 该工作为课程作业，主要目标为利用树莓派作为服务器，完成wordpress的配置，建立动态博客网站。详细的作业要求如下： 制作raspbi</description></item><item><title>以太坊开发6-Docker搭建以太坊私链</title><link>https://NamiChen.github.io/2019/use-docker-to-build-ethereum-private-chain/</link><pubDate>Tue, 12 Mar 2019 11:24:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/use-docker-to-build-ethereum-private-chain/</guid><description>&lt;p>在以太坊github的&lt;a href="https://github.com/ethereum/go-ethereum" target="_blank">官方项目地址&lt;/a>发现其支持Docker启动，同时因为Docker相对于虚拟机的易用性，决定尝试使用Docker搭建以太坊联盟链&lt;/p>
&lt;p>Docker安装部分查看自官方说明，搭建过程主要参考&lt;a href="https://www.jianshu.com/p/7994db7a2b89?from=singlemessage" target="_blank">简书-使用Docker搭建以太坊私有链并部署合约&lt;/a>&lt;/p>
&lt;h2 id="一docker安装">一、Docker安装&lt;/h2>
&lt;p>OS环境：Ubuntu 18.04 LTS(bionic)&lt;/p>
&lt;p>内核版本：4.18.0-16-generic&lt;/p>
&lt;p>处理器架构：amd64&lt;/p>
&lt;p>官方的安装说明位于：&lt;a href="https://docs.docker.com/install/linux/docker-ce/ubuntu/" target="_blank">Get Docker CE for Ubuntu&lt;/a>&lt;/p></description></item><item><title>以太坊开发5-以太坊节点连接到网络的几种方式</title><link>https://NamiChen.github.io/2019/the-way-to-connect-to-the-network-about-ethereum-node/</link><pubDate>Tue, 12 Mar 2019 08:33:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/the-way-to-connect-to-the-network-about-ethereum-node/</guid><description>文章翻译自：Connecting to the network 如何寻找对等节点 在初始化时，geth会使用一组记录在源码中的bootstrap节点来连接。要指定这些节</description></item><item><title>以太坊开发4-geth console命令</title><link>https://NamiChen.github.io/2019/geth-console-command/</link><pubDate>Fri, 08 Mar 2019 10:27:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/geth-console-command/</guid><description>&lt;p>Geth Console是一个交互式的JavaScript执行环境，其中&lt;code>&amp;gt;&lt;/code>是命令提示符。在这个环境里也内置了一些用来操作以太坊的JavaScript对象，可以直接使用这些对象。这些对象主要包括：&lt;/p>
&lt;ul>
&lt;li>eth：包含一些跟操作区块链相关的方法；&lt;/li>
&lt;li>net：包含一些查看p2p网络状态的方法；&lt;/li>
&lt;li>admin：包含一些与管理节点相关的方法；&lt;/li>
&lt;li>miner：包含启动&amp;amp;停止挖矿的一些方法；&lt;/li>
&lt;li>personal：主要包含一些管理账户的方法；&lt;/li>
&lt;li>txpool：包含一些查看交易内存池的方法；&lt;/li>
&lt;li>web3：包含了以上对象，还包含一些单位换算的方法。&lt;/li>
&lt;/ul></description></item><item><title>以太坊开发3-geth客户端命令</title><link>https://NamiChen.github.io/2019/geth-client-use/</link><pubDate>Fri, 08 Mar 2019 09:26:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/geth-client-use/</guid><description>Geth是以太坊智能合约开发工具，是一个命令行工具，所以熟悉其命令参数有助于提高开发效率。本文是geth help的翻译，基于geth 1.8.</description></item><item><title>以太坊开发2-创世区块文件genesis.json</title><link>https://NamiChen.github.io/2019/%E4%BB%A5%E5%A4%AA%E5%9D%8A%E5%BC%80%E5%8F%912-%E5%88%9B%E4%B8%96%E5%8C%BA%E5%9D%97%E6%96%87%E4%BB%B6genesis.json/</link><pubDate>Thu, 07 Mar 2019 19:48:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/%E4%BB%A5%E5%A4%AA%E5%9D%8A%E5%BC%80%E5%8F%912-%E5%88%9B%E4%B8%96%E5%8C%BA%E5%9D%97%E6%96%87%E4%BB%B6genesis.json/</guid><description>文件说明 关于genesis.json的官方说明位于两处 Private network Connecting to the network 每条区块链都以创世区块开头，而genesis.json正是创世区块的配置文</description></item><item><title>以太坊开发1-虚拟机搭建以太坊私链</title><link>https://NamiChen.github.io/2019/use-virtual-machine-builds-ethereum-private-chain/</link><pubDate>Thu, 07 Mar 2019 14:53:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/use-virtual-machine-builds-ethereum-private-chain/</guid><description>一、单虚拟机 最简单的方式是使用一个虚拟机，这也是在条件有限的情况下的最好选择。方法是在一台虚拟机上启用多个终端，每个终端使用不同的端口通信。</description></item><item><title>Blockchain-Based Platform Architecture for Industrial IoT</title><link>https://NamiChen.github.io/2019/blockchain-based-platform-architecture-for-industrial-iot/</link><pubDate>Thu, 28 Feb 2019 10:50:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/blockchain-based-platform-architecture-for-industrial-iot/</guid><description>&lt;p>Author：Nikolay Teslya; Igor Ryabchikov&lt;/p>
&lt;p>Published in：2017 21st Conference of Open Innovations Association(FRUCT)&lt;/p>
&lt;p>Date of Conference: 6-10 Nov. &lt;strong>2017&lt;/strong>&lt;/p>
&lt;p>会议举办地：Helsinki, Finland&lt;/p>
&lt;p>被引量：11次&lt;/p>
&lt;h2 id="摘要">摘要&lt;/h2>
&lt;p>机器人技术，物联网概念，大数据处理技术，自动化和分布式数字分类账技术的发展引发了第四次工业革命。新工业的主要问题之一是基于物联网的智能工厂内部组件以及工厂之间的互操作。这种互操作应该提供物联网参与者之间的信任;控制资源的分配（如维护时间，能源等）和成品。本文描述了集成物联网和区块链技术以解决这些问题的可能方法之一。为此，开发了一种结合了Smart-M3信息共享平台和区块链平台的架构。所提出的体系结构的一个主要特征是使用智能合约来处理和存储与智能空间组件之间的交互相关的信息。&lt;/p></description></item><item><title>Blockchain Platforms Overview for Industrial IoT Purpose</title><link>https://NamiChen.github.io/2019/blockchain-platforms-overview-for-industrial-iot-purpose/</link><pubDate>Wed, 27 Feb 2019 11:11:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/blockchain-platforms-overview-for-industrial-iot-purpose/</guid><description>&lt;p>Author：Nikolay Teslya; Igor Ryabchikov&lt;/p>
&lt;p>Published in：2018 22nd Conference of Open Innovations Association(FRUCT)&lt;/p>
&lt;p>Date of Conference: 15-18 May &lt;strong>2018&lt;/strong>&lt;/p>
&lt;p>会议举办地：Jyvaskyla, Finland&lt;/p>
&lt;p>被引量：1次&lt;/p>
&lt;h2 id="abstract">Abstract&lt;/h2>
&lt;p>如今已有很多可用区块链平台存在。但要集成到工业物联网的智能空间中，区块链平台不仅应支持代币交易，还应支持智能合约、容错共识机制，以及参与者创建和实施新区块和智能合约的地位的平等。本文分析了最常用的共识机制，公共（无权限）和私有（有权限）区块链的具体特征。还描述了满足IIoT平台开发要求的区块链平台。通过分析所得结果，可选择平台和特定模块来实现用于IIoT平台的区块链。&lt;/p></description></item><item><title>Decentralizing Privacy：Using Blockchain to Protect Personal Data</title><link>https://NamiChen.github.io/2019/decentralizing-privacyusing-blockchain-to-protect-personal-data/</link><pubDate>Thu, 14 Feb 2019 09:50:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/decentralizing-privacyusing-blockchain-to-protect-personal-data/</guid><description>&lt;p>Zyskind G, Nathan O, Pentland A, et al. Decentralizing Privacy: Using Blockchain to Protect Personal Data[C]. ieee symposium on security and privacy, 2015: 180-184.&lt;/p>
&lt;p>DOI: &lt;a href="https://doi.org/10.1109/SPW.2015.27" target="_blank">10.1109/SPW.2015.27&lt;/a>&lt;/p>
&lt;p>KeyWord: Protocols, Privacy, Data privacy, Online banking, Encryption, Compounds.&lt;/p>
&lt;p>注：部分插图经过重新绘制，部分来自原论文截图。&lt;/p>
&lt;h2 id="摘要">摘要&lt;/h2>
&lt;p>当前的商业模式下，第三方收集和控制了大量的个人隐私，损害了用户权益，越来愈多的安全事件使得这一模式开始受到质疑。比特币证明了通过一个分布式的公有分类账在金融领域进行可信和可审计的计算是可行的。因此，本文提出了一种基于区块链的分布式个人数据管理系统，用于保证用户对个人数据的所有权和控制权。与比特币不同的是，本文提出的系统中，区块链交易不是金融交易，而是用于携带指令，如存储、查询和共享数据等，在文章的最后也会讨论区块链未来可能的发展。&lt;/p></description></item><item><title>文献综述-区块链用于 IoT/IIoT：智能工厂案例</title><link>https://NamiChen.github.io/2019/blockchain-for-iot/iiota-smart-factory-case-study/</link><pubDate>Tue, 05 Feb 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/blockchain-for-iot/iiota-smart-factory-case-study/</guid><description>随着物联网的高速发展，越来越多的智能设备接入到了人们的日常生活和工业生产当中。尤其在智能工厂领域，物联网设备的使用大幅提高了工厂自动化程度，</description></item><item><title>大学全文</title><link>https://NamiChen.github.io/2019/the-great-learning/</link><pubDate>Tue, 22 Jan 2019 15:40:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/the-great-learning/</guid><description>大学章句 右经一章，盖孔子之言，而曾子述之。其传十章，则曾子之意而门人记之也。旧本颇有错简，今因程子所定，而更考经文，别为序次如左。 《大学》之</description></item><item><title>越简单越美好</title><link>https://NamiChen.github.io/2019/%E8%B6%8A%E7%AE%80%E5%8D%95%E8%B6%8A%E7%BE%8E%E5%A5%BD/</link><pubDate>Mon, 21 Jan 2019 09:37:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/%E8%B6%8A%E7%AE%80%E5%8D%95%E8%B6%8A%E7%BE%8E%E5%A5%BD/</guid><description>&lt;p>人生最贵重的，就是通过不断地学习，将你经历过的事、遇到过的人、读过的书、走过的路，揉碎吸收之后，用这些养分供养你，成就一个只属于你自己的人生，然后，让你不断超越昨天的你。&lt;/p>
&lt;h3 id="关于生活">关于生活&lt;/h3>
&lt;p>简约不等于清贫，而是懂得取舍&lt;/p>
&lt;p>如果18℃能让我们保暖，我们为什么一定要21℃的奢侈呢？&lt;/p>
&lt;p>我们吃的、住的，原本是为了让我们生活得更舒适，但有一天这些东西打扰到你的清净，分散你的精力，让你花时间保养它们，不得不时常打扫它们，保持房子的清洁。稍有不慎，甚至会让你受到伤害。那时我就考虑：我的生活里，真的需要这么多东西吗？&lt;/p>
&lt;p>拒收礼物，每一件未经计划来到我身边的东西都是多余的。&lt;/p>
&lt;p>有时候，让人累的不是有计划的生活，而是没有计划的生活！别人一个电话你就到，或者随便地应约，又随便地爽约，这样你在朋友那里是得不到尊重的。随心所欲的生活看似自由，其实极大地消耗着人地时间和精力，你连自己每天要做什么都不清楚，每天上班不敢拒绝加班，下班后懒懒的往沙发上一躺。你以为你为生活少奋斗了，其实你没有。那些看似严谨约束地计划里，实则藏着你想要地自由与梦想！只有当你有能力掌控你的生活之后，你的生活，才是你的！&lt;/p></description></item><item><title>Internet of Smart Things-IoST</title><link>https://NamiChen.github.io/2019/internet-of-smart-things-iost/</link><pubDate>Thu, 17 Jan 2019 10:06:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/internet-of-smart-things-iost/</guid><description>&lt;p>Author：Mayra Samaniego, Ralph Deters&lt;/p>
&lt;p>Published in：2017 IEEE International Conference on Cognitive Computing (ICCC)&lt;/p>
&lt;p>Date of Conference: 25-30 June 2017&lt;/p>
&lt;p>会议级别：不知道&lt;/p>
&lt;p>被引量：11次&lt;/p>
&lt;p>keywords：IoT; Management; Blockchain; Multichain;Smart Things; Autonomy;Self-inferencing; Self-monitoring;Fog; Edge.&lt;/p>
&lt;br/>
&lt;h3 id="摘要">摘要&lt;/h3>
&lt;p>构成物联网的大量异构设备需要有效的资源管理。随着雾计算的出现，一些管理任务可以下移到物联网的边缘，更靠近物理设备。建立在雾网络上的区块链可以处理一些物联网的管理任务，如通信、存储和身份验证。这种情况下，以及超越了原来对物联网中Things的定义，可以称之为“Smart Things&amp;rdquo;。Smart Things提供基于CLIPS编程语言的人工智能（AI）功能，以实现自我推理和自我监控。这项工作使用私链构建工具Multichain通过读写块中信息来达成Smart Things之间的通信。本文评估了Edison Arduino板上部署的Smart Things以及雾网络上部署的的Multichain网络。&lt;/p></description></item><item><title>区块链学习5-ETC和ETH</title><link>https://NamiChen.github.io/2019/ethereum-and-ethereum-classic/</link><pubDate>Wed, 16 Jan 2019 10:48:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/ethereum-and-ethereum-classic/</guid><description>最近ETC遭受疑似51%攻击的影响很大，虽然最后的结果还没出来，仍不确定是真的遭受了51%攻击，还是之前官方所称的ASIC矿机测试带来的问题</description></item><item><title>BlockChain：A Distributed Solution to Automotive Security and Privacy</title><link>https://NamiChen.github.io/2019/blockchaina-distributed-solution-to-automotive-security-and-privacy/</link><pubDate>Tue, 15 Jan 2019 19:40:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/blockchaina-distributed-solution-to-automotive-security-and-privacy/</guid><description>Abstract 智能车辆互联提供了一系列先进的服务，这有益于车主、运输当局、车辆制造商和其它服务提供者。但这也可能把智能汽车暴露在一系列安全和隐私威胁之下</description></item><item><title>背景调查4-区块链与智能工厂</title><link>https://NamiChen.github.io/2019/blockchain-for-smart-factory/</link><pubDate>Tue, 15 Jan 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/blockchain-for-smart-factory/</guid><description>1. 背景 传统工厂向智能工厂转变是为了提高生产和管理效率，并高度灵活地适应不断变化的生产要求1。这一目的的达成部分依赖于大量来自于制造设备，工业</description></item><item><title>Blockchain in Internet of Things:Challenges and Solutions</title><link>https://NamiChen.github.io/2019/blockchain-in-internet-of-thingschallenges-and-solutions/</link><pubDate>Wed, 09 Jan 2019 09:50:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/blockchain-in-internet-of-thingschallenges-and-solutions/</guid><description>&lt;p>Author：Ali Dorri, Salil S. Kanhere, and Raja Jurdak&lt;/p>
&lt;p>arXiv预印（非正式发表）&lt;/p>
&lt;p>2016.08&lt;/p>
&lt;h3 id="abstract">Abstract&lt;/h3>
&lt;p>物联网产业在快速发展，但安全和隐私的问题始终没有解决。由于物联网分布式的拓扑结构和资源有限的设备，传统的安全和隐私方法不适用于物联网。区块链能用于保证和物联网具有相同拓扑的P2P网络的安全与隐私，因此应也能用于物联网，然后，BC是计算密集型的，需要较高带宽且延迟较高，并不适合物联网。本文提出一种基于BC技术的安全、私有和轻量级的架构，去除了BC的缺点，同时保留了其安全和隐私特性，使其适用于物联网。利用智能家居场景为例做了描述，整个架构分为智能家居层、覆盖网络层、云存储层三层。在各层使用了不同类型的BC，并对常见的安全威胁做了定性分析，证明了其保证物联网安全与隐私的有效性。&lt;/p></description></item><item><title>Blockchain for IoT Security and Privacy:The Case Study of a Smart Home</title><link>https://NamiChen.github.io/2019/blockchain-for-iot-security-and-privacythe-case-study-of-a-smart-home/</link><pubDate>Mon, 07 Jan 2019 14:55:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/blockchain-for-iot-security-and-privacythe-case-study-of-a-smart-home/</guid><description>&lt;p>Dorri, Ali &amp;amp; Kanhere, Salil &amp;amp; Jurdak, Raja &amp;amp; Gauravaram, Praveen. (2017). Blockchain for IoT Security and Privacy: The Case Study of a Smart Home. 10.1109/PERCOMW.2017.7917634.&lt;/p>
&lt;h3 id="abstract">Abstract&lt;/h3>
&lt;p>由于物联网网络大规模和分布式的特性，物联网（IoT）安全和隐私仍然是一个主要的挑战。基于区块链的方法可以提供分布式的安全性和隐私性，但会带来显著的能量、延迟和计算开销，不适合大多数资源受限的IoT设备。在我们之前的工作中，我们通过去除PoW（Proof of Work, 工作量证明）和货币（coins）的概念，提出了一个适用于物联网的BC（Blockchain, 区块链）的轻量级实例。我们的方法在智能家居环境中进行了验证，主要包括三层：云存储，overlay和智能家居。在本文中，我们深入研究并概述了智能家居层的各种核心组件和功能。每个智能家居都配备了一个永远在线的高资源设备，称为“miner”，负责处理家庭内外的所有通信。该miner还维护一个私有BC，用于控制和审计通信。我们通过彻底分析其在机密性，完整性和可用性的基本安全目标，表明我们提出的基于BC的智能家居框架是安全的。最后，我们利用仿真结果证明我们的方法引入的开销（在流量，处理时间和能耗方面）相对于其安全性和隐私性增益而言是微不足道的。&lt;/p></description></item><item><title>Bubbles of Trust：a decentralized Blockchain-based authentication system for IoT</title><link>https://NamiChen.github.io/2019/bubbles-of-trusta-decentralized-blockchain-based-authentication-system-for-iot/</link><pubDate>Thu, 03 Jan 2019 19:26:00 +0800</pubDate><guid>https://NamiChen.github.io/2019/bubbles-of-trusta-decentralized-blockchain-based-authentication-system-for-iot/</guid><description>Author：Mohamed Tahar Hammi, Badis Hammi, Patrick Bellot, Ahmed Serhrouchni Published in: Computers &amp;amp; Security(2018.6) SCI期刊分区：3区 Abstract 我们使用的许多东西都配备了电子设备和协议，以使它们互连和连接到互</description></item><item><title>凡心所向，素履以往</title><link>https://NamiChen.github.io/2019/%E5%87%A1%E5%BF%83%E6%89%80%E5%90%91%E7%B4%A0%E5%B1%A5%E4%BB%A5%E5%BE%80/</link><pubDate>Wed, 02 Jan 2019 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2019/%E5%87%A1%E5%BF%83%E6%89%80%E5%90%91%E7%B4%A0%E5%B1%A5%E4%BB%A5%E5%BE%80/</guid><description>凡心所向，素履以往，生如逆旅，一苇以航。 三月桃花，四月欢唱，两人一马，明日故乡。 流浪陌路，暖然绯凉，写意人生，相识一场。 不关此世，不负己心，</description></item><item><title>Blockchain Meets IoT：An Architecture for Scalable Access Management in IoT</title><link>https://NamiChen.github.io/2018/blockchain-meets-iotan-architecture-for-scalable-access-management-in-iot/</link><pubDate>Fri, 28 Dec 2018 15:42:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/blockchain-meets-iotan-architecture-for-scalable-access-management-in-iot/</guid><description>Novo O. Blockchain Meets IoT: An Architecture for Scalable Access Management in IoT[J]. IEEE Internet of Things Journal, 2018, 5(2): 1184-1195. DOI: 10.1109/JIOT.2018.2812239 keywords: Access control, Blockchain, IoT, smart contracts 摘要 物联网所面临的一个问题是部署在全球的数十亿的设备如何去管理，现有的访问管理技</description></item><item><title>Block Chain based Intelligent Industrial Network (DSDIN)</title><link>https://NamiChen.github.io/2018/block-chain-based-intelligent-industrial-network-dsdin/</link><pubDate>Fri, 14 Dec 2018 08:37:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/block-chain-based-intelligent-industrial-network-dsdin/</guid><description>&lt;p>Author：Barco You, Matthias Hub, Mengzhe You, Bo Xu, Mingzhi Yu and Ican Uemlianin&lt;/p>
&lt;p>Published in：eprint arXiv:1809.06551(1809意为18年9月)&lt;/p>
&lt;p>SCI期刊分区：在arXic上，不算正式发表&lt;/p>
&lt;p>keywords：IIoT, BC, Artificial Intelligence, Industry 4.0, Intelligent Manufacturing, Edge Computing.&lt;/p>
&lt;p>&lt;strong>主题&lt;/strong>：如何为IIoT构建一个全球范围的分布式工业网络&lt;/p>
&lt;p>&lt;strong>主要工作&lt;/strong>：&lt;/p>
&lt;ol>
&lt;li>综述。从工业互联网讲到工业物联网，最后讲到基于区块链的工业物联网&lt;/li>
&lt;li>详细描述了所构建的基于区块链的智能工业网络DSDIN的各部分组成&lt;/li>
&lt;li>介绍了一些可以高效的运行在DSDIN上的应用&lt;/li>
&lt;li>介绍了维持整个体系健康运行的激励机制&lt;/li>
&lt;/ol>
&lt;p>&lt;strong>Abstract&lt;/strong>：过去由于技术限制，制造业是“中央集权”的，工厂（特别是大型制造商）垄断了几乎所有的制造资源，包括：技术，原材料，设备，工人，市场信息等。但是，这种集中生产成本高、效率低并且不灵活，难以应对快速变化，多样化和个性化的用户需求。本文介绍了一个智能工业网络（DSDIN），它提供了一个完全分布式的制造网络，每个人都可以参与制造，因为权力下放而没有中间环节，人们能够快速获得他们想要的产品或服务，获得授权并通过努力（例如提供创意，设计或设备，原材料等）以一种低成本的方式获得回报。DSDIN实际上是一个平台，由DSDIN形成的智能网络，制造中心不再是工厂，实际上没有制造中心。DSDIN为人和物（包括原材料，设备，成品/半成品等）提供多参与的点对点网络。通过网络传输的信息称为智能服务算法（ISA）。用户可以通过ISA将过程模型，公式或控制参数发送到设备，DSDIN中的每个事务都是由ISA定义的智能服务。&lt;/p>
&lt;p>&lt;em>&lt;font size = 2>注：要构建一个全球范围的分布式工业网络，做的是基于区块链技术的工业物联网平台，和以太坊很相似，从文中也可以看到，大量借鉴了以太坊的思路，但是根据工业物联网的特性做了调整。&lt;/font>&lt;/em>&lt;/p></description></item><item><title>Consortium Blockchain for Secure Energy Trading in Industrial Internet of Things</title><link>https://NamiChen.github.io/2018/consortium-blockchain-for-secure-energy-trading-in-industrial-internet-of-things/</link><pubDate>Thu, 13 Dec 2018 17:14:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/consortium-blockchain-for-secure-energy-trading-in-industrial-internet-of-things/</guid><description>&lt;p>&lt;strong>主题&lt;/strong>：用联盟链解决工业物联网的能量交易问题&lt;/p>
&lt;p>&lt;strong>主要工作&lt;/strong>：&lt;/p>
&lt;ol>
&lt;li>针对工业物联网(IIoT)里能量交易的安全与隐私问题，提出能量区块链(energy blockchain)&lt;/li>
&lt;li>为了减少由交易确认的延迟造成的交易限制，提出一个基于信用的支付方案，以支持快速和频繁的能源限制&lt;/li>
&lt;li>在体系里构建了一个能量银行，并使用Stackelberg 博弈进行基于信用贷款的最优定价&lt;/li>
&lt;li>对能量区块链解决的安全问题，能量区块链的性能，基于信用的支付方案的性能做分析&lt;/li>
&lt;/ol></description></item><item><title>区块链学习4-以太坊基础知识</title><link>https://NamiChen.github.io/2018/ethereum-instruction/</link><pubDate>Tue, 11 Dec 2018 20:34:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/ethereum-instruction/</guid><description>1. 基本知识 基本知识需要了解两部分 第一部分是以太坊版本演进过程：白皮书——&amp;gt;黄皮书——&amp;gt;Frontier版本——&amp;gt;Homes</description></item><item><title>背景调查3-区块链与物联网</title><link>https://NamiChen.github.io/2018/blockchain-for-iot/</link><pubDate>Tue, 11 Dec 2018 14:55:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/blockchain-for-iot/</guid><description>&lt;p>和老师商量着定了大方向是物联网和区块链的结合，这篇文章是这段时间以来对该方向调查的总结。&lt;/p></description></item><item><title>所罗门之匙的启示</title><link>https://NamiChen.github.io/2018/%E6%89%80%E7%BD%97%E9%97%A8%E4%B9%8B%E5%8C%99%E7%9A%84%E5%90%AF%E7%A4%BA/</link><pubDate>Fri, 07 Dec 2018 16:41:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/%E6%89%80%E7%BD%97%E9%97%A8%E4%B9%8B%E5%8C%99%E7%9A%84%E5%90%AF%E7%A4%BA/</guid><description>所罗门之匙一书中，所罗门囚禁魔神，将魔神的力量赋予他的学徒，从而一举将他的学徒们，变成了堪比神魔的法师。那些门徒们，很多之前都没有接触过魔法</description></item><item><title>区块链学习3-区块链领域概况</title><link>https://NamiChen.github.io/2018/overview-of-blockchain/</link><pubDate>Tue, 20 Nov 2018 14:25:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/overview-of-blockchain/</guid><description>&lt;p>本篇结束区块链领域概况，包括一些常见名词、核心技术、应用场景和学习区块链需要掌握的基础知识。&lt;/p></description></item><item><title>背景调查2-近三年区块链方向论文发表情况总结</title><link>https://NamiChen.github.io/2018/analysis-of-papers-published-in-blockchain-field/</link><pubDate>Sat, 17 Nov 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/analysis-of-papers-published-in-blockchain-field/</guid><description>原始的目的是统计一下国内区块链研究现状，但开始这一工作时决定顺便把其它的统计数据也一并记录下来。数据来自 Web of Science核心合集，即SCI</description></item><item><title>背景调查1-区块链方向的期刊、会议和基金收集</title><link>https://NamiChen.github.io/2018/conference-journal-and-foundation-information-in-blockchain-field/</link><pubDate>Wed, 14 Nov 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/conference-journal-and-foundation-information-in-blockchain-field/</guid><description>如题，本文只关注重点的几方面 收录区块链的期刊、会议列表（将中国的单独分离） 期刊专题和会议的征稿通知，从中发现当前热点研究领域 基金项目信息中的</description></item><item><title>区块链学习2-比特币基本原理</title><link>https://NamiChen.github.io/2018/bitcoin-fundamentals/</link><pubDate>Mon, 12 Nov 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/bitcoin-fundamentals/</guid><description>&lt;p>区块链里最基本也是最重要的几个概念是&lt;strong>地址&lt;/strong>、&lt;strong>交易&lt;/strong>、&lt;strong>区块&lt;/strong>、&lt;strong>网络&lt;/strong>。比特币用地址来标识一笔交易的支出方和接收方。所有的交易最终需要被记到统一的账本（也就是区块链）上，而这个账本是通过区块确认并完成的。每一个新区块的产生，都会被打上时间戳（区块头里的一个字段，是真的时间，后面详细介绍），最终生成按照时间前后排列并加以记录的电子交易证明。每个独立节点之间又通过比特币网络来建立联系，这样就组成了一个去中心化、分布式的电子交易记录时间戳服务器系统。比特币通过构造这个分布式时间戳服务器来解决&lt;a href="https://baike.baidu.com/item/%E5%8F%8C%E9%87%8D%E6%94%AF%E4%BB%98/7046722?fr=aladdin" target="_blank">双重支付&lt;/a>问题。&lt;/p></description></item><item><title>科研基础2-文献管理工具 Zotero 学习指南</title><link>https://NamiChen.github.io/2018/introduction-to-zotero/</link><pubDate>Sun, 11 Nov 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/introduction-to-zotero/</guid><description>在文献管理方面的需求包括： 文献可以方便地导入工具中并提取准确丰富地文献信息 工作和学习时，可以快速在工具中找到自己想要的文献 在写作时，可以方便</description></item><item><title>科研基础1-文献检索常识</title><link>https://NamiChen.github.io/2018/academic-basic-knowledge/</link><pubDate>Fri, 09 Nov 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/academic-basic-knowledge/</guid><description>1. 常用名词 与学术研究和论文相关的，有许多常用的名词，本节对这些名词作解释和区分。 会议组织者：可能是某个学校或某个组织，为了学术或经济利益举办</description></item><item><title>区块链学习1-比特币的诞生</title><link>https://NamiChen.github.io/2018/the-birth-of-bitcoin/</link><pubDate>Fri, 02 Nov 2018 14:02:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/the-birth-of-bitcoin/</guid><description>&lt;p>区块链作为比特币背后的技术架构，是随着比特币的出现而诞生的。因此，要讲区块链的诞生，我们就不得不从比特币的历史说起。&lt;/p></description></item><item><title>Blockchain and the Internet of Things in the Industrial Sector</title><link>https://NamiChen.github.io/2018/blockchain-and-the-internet-of-things-in-the-industrial-sector/</link><pubDate>Wed, 24 Oct 2018 12:25:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/blockchain-and-the-internet-of-things-in-the-industrial-sector/</guid><description>说明：三个工业物联网和区块链结合的场景 供应链 货物在供应链各环节流通时，装运信息缺乏可见性，并且拥有装运延迟，这种延迟通常是由于一个流通的批准</description></item><item><title>Work-in-Progress Integrating Low-Power IoT devices to</title><link>https://NamiChen.github.io/2018/work-in-progress-integrating-low-power-iot-devices-to/</link><pubDate>Tue, 23 Oct 2018 11:22:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/work-in-progress-integrating-low-power-iot-devices-to/</guid><description>Özyılmaz, Kazım Rıfat, and Arda Yurdakul. &amp;ldquo;Work-in-Progress: Integrating low-power IoT devices to a blockchain-based infrastructure.&amp;rdquo; 2017 International Conference on Embedded Software (EMSOFT). IEEE, 2017. 说明：关于物联网和区块链结合，节点资源有限的一种解决方案 Introduction</description></item><item><title>Blockchains and Smart Contracts for the Internet of Things</title><link>https://NamiChen.github.io/2018/blockchains-and-smart-contracts-for-the-internet-of-things/</link><pubDate>Mon, 22 Oct 2018 10:19:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/blockchains-and-smart-contracts-for-the-internet-of-things/</guid><description>&lt;h2 id="introduction">Introduction&lt;/h2>
&lt;p>缺失可信中介使交易双方之间的协调更快&lt;/p>
&lt;p>密码学的大量使用为网络中的所有交互带来了权威性&lt;/p>
&lt;p>智能合约允许分布式的，高度自动化的工作流程&lt;/p>
&lt;h2 id="blockchains-and-iot">Blockchains and IoT&lt;/h2>
&lt;p>目前的中心化模型中，制造商维护以百万计的设备的软件更新代价是高昂的&lt;/p>
&lt;p>用户缺乏对应用从后台是否私自获取数据的信任，需要一个透明度保障的方法&lt;/p>
&lt;p>区块链技术可以解决这些问题&lt;/p>
&lt;p>制造商的所有物联网设备都在同一个区块链网络上运行，制造商部署智能合约并允许它们在区块链网络上存储最新固件更新的哈希值，这些设备要么将智能合约的地址附加到它们的区块链客户端，要么通过发现服务找到它。然后，它们可以查询合约，了解新的固件更新，并通过分式对等文件系统请求更新并通过哈希验证更新正确性，对该文件的第一次请求由制造商自己的节点（该节点也加入区块链网络）提供服务，但更新文件传播到足够的节点后，制造商的节点可以停止提供服务，由已获得更新的设备向未获得更新的设备提供服务，一切自动进行，没有用户交互。&lt;/p></description></item><item><title>人工智能管理世界</title><link>https://NamiChen.github.io/2018/%E4%BA%BA%E5%B7%A5%E6%99%BA%E8%83%BD%E7%AE%A1%E7%90%86%E4%B8%96%E7%95%8C/</link><pubDate>Fri, 12 Oct 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/%E4%BA%BA%E5%B7%A5%E6%99%BA%E8%83%BD%E7%AE%A1%E7%90%86%E4%B8%96%E7%95%8C/</guid><description>2017年5月，AlphaGo战胜顶尖围棋选手柯洁，同年10月，汉森公司的机器人索菲亚获得沙特阿拉伯公民身份。这两个去年曾轰动一时的新闻似乎</description></item><item><title>计算机网络-ICMP协议</title><link>https://NamiChen.github.io/2018/internet-control-message-protocol/</link><pubDate>Mon, 01 Oct 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/internet-control-message-protocol/</guid><description>&lt;p>网络层除了主要的 IP 协议外，还有 ICMP（Internet Control Message Protocol） 协议，ping 和 traceroute 都会用到它，本文进行介绍。&lt;/p></description></item><item><title>自然辩证法</title><link>https://NamiChen.github.io/2018/%E8%87%AA%E7%84%B6%E8%BE%A9%E8%AF%81%E6%B3%95/</link><pubDate>Wed, 19 Sep 2018 22:26:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/%E8%87%AA%E7%84%B6%E8%BE%A9%E8%AF%81%E6%B3%95/</guid><description>&lt;p>被称为“科技哲学”的自然辩证法，是对以科学技术为中介和手段的人与自然、社会的相互关系的概括和总结。由于其学科性质，天生便与科学技术有着密不可分的关系，尤其是对科学技术发展的历史的研究，更是课堂上所讲的各种理论的佐证。而作为这门学科的体系化开端，恩格斯的《自然辨证法》自然而然地散发着一种迷人的魅力，吸引着对这门学科有着兴趣的我。我从这本文集中选择了《导言》、《神灵世界中的自然科学》两篇论文和其它几篇札记做了阅读，以下是我的一些心得。&lt;/p></description></item><item><title>工程与伦理</title><link>https://NamiChen.github.io/2018/%E5%B7%A5%E7%A8%8B%E4%B8%8E%E4%BC%A6%E7%90%86/</link><pubDate>Sat, 15 Sep 2018 08:52:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/%E5%B7%A5%E7%A8%8B%E4%B8%8E%E4%BC%A6%E7%90%86/</guid><description>工程伦理问题涉及对工程行为正当性的思考和价值判断，往往需要在价值冲突中做出正确的价值选择。了解它的必要性有三个： 提升工程师的伦理素养，加强工</description></item><item><title>如果度过研究生阶段</title><link>https://NamiChen.github.io/2018/what-should-be-done-in-master-three-years/</link><pubDate>Wed, 05 Sep 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/what-should-be-done-in-master-three-years/</guid><description>&lt;p>研三重新来写这篇文章，感触更多，也许当初明白这些，会有不同的选择，可惜，世上没有如果。&lt;/p></description></item><item><title>1692年镌刻于巴尔的摩圣保罗教堂</title><link>https://NamiChen.github.io/2018/engraved-in-st-pauls-church-in-1962/</link><pubDate>Wed, 22 Aug 2018 16:33:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/engraved-in-st-pauls-church-in-1962/</guid><description>在喧闹而奔忙的世界中平静地往前走 这是多么和平，安宁 你要与周围的所有的人友好相处 尽可能不要放弃这种努力和追求 你要轻轻但清晰地说出自己的真实思想</description></item><item><title>Markdown使用探索</title><link>https://NamiChen.github.io/2018/markdown-usage/</link><pubDate>Sun, 01 Jul 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/markdown-usage/</guid><description>前言 Markdown用习惯之后，就会不管什么事都想用它来做，因为真的太好用了。本篇文章就是一些尝试，因为往往“不堪大用”，所以给这篇文章起了</description></item><item><title>Markdown语法</title><link>https://NamiChen.github.io/2018/markdown-syntax/</link><pubDate>Sat, 30 Jun 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/markdown-syntax/</guid><description>Markdown由Aaron Swartz和John Gruber共同设计 Aaron Swartz的博客：http://www.aaronsw.com/ John</description></item><item><title>Git提高-分支管理, 多人协作, 标签管理, gitignore, commit信息</title><link>https://NamiChen.github.io/2018/git-learning-improvement/</link><pubDate>Sun, 22 Apr 2018 10:21:16 +0800</pubDate><guid>https://NamiChen.github.io/2018/git-learning-improvement/</guid><description>上一篇我们学习了Git的基本知识，包括仓库创建，提交、修改、推送、回退等等操作，本篇学习一些高级的功能。转自 廖雪峰的官方网站-git教程。 1.</description></item><item><title>Git入门-基本概念, 基本原理, 安装使用</title><link>https://NamiChen.github.io/2018/git-learning-getting-started/</link><pubDate>Fri, 20 Apr 2018 19:06:20 +0800</pubDate><guid>https://NamiChen.github.io/2018/git-learning-getting-started/</guid><description>&lt;p>版本控制系统在代码开发过程中必不可缺，本系列学习 Git 的使用，版本托管服务则是 Github。以廖雪峰大神 &lt;a href="https://www.liaoxuefeng.com/wiki/896043488029600" target="_blank">git教程&lt;/a> 为主体，辅以使用过程中遇到的问题和心得。&lt;/p></description></item><item><title>编程语言选择</title><link>https://NamiChen.github.io/2018/%E7%BC%96%E7%A8%8B%E8%AF%AD%E8%A8%80%E9%80%89%E6%8B%A9/</link><pubDate>Wed, 18 Apr 2018 20:06:18 +0800</pubDate><guid>https://NamiChen.github.io/2018/%E7%BC%96%E7%A8%8B%E8%AF%AD%E8%A8%80%E9%80%89%E6%8B%A9/</guid><description>从大学期间教授的C、C++、Java，到自己接触的python、js，以及耳熟能详的PHP、C#、Ruby，甚至其它众多听过的没听过的语言。</description></item><item><title>Hexo 搭建个人博客</title><link>https://NamiChen.github.io/2018/using-hexo-build-persoanl-blog/</link><pubDate>Tue, 17 Apr 2018 20:30:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/using-hexo-build-persoanl-blog/</guid><description>Hexo是一款快速、简洁且高效的静态博客框架，使用Markdown渲染引擎解析文章，拥有着丰富的主题社区，可以帮助我们快速建立自己的博客，正</description></item><item><title>愿世界和平</title><link>https://NamiChen.github.io/2018/war/</link><pubDate>Tue, 17 Apr 2018 16:47:35 +0800</pubDate><guid>https://NamiChen.github.io/2018/war/</guid><description>我的梦想是世界和平这句话常被人们作为玩笑，但对与战争比邻而居的人们来说，这是心底最真诚而热切的渴望。偶然看到了这组图片，是叙利亚的战后情景，</description></item><item><title>极简主义</title><link>https://NamiChen.github.io/2018/minimalism/</link><pubDate>Sat, 14 Apr 2018 22:25:00 +0800</pubDate><guid>https://NamiChen.github.io/2018/minimalism/</guid><description>极简主义是一种理念，当我第一次接触到这个概念时就被它所吸引，并竭力往这个目标靠近。今天在人民日报官博看到了关于极简理念的分享，正巧刚建好博客</description></item><item><title>系统移植1-移植相关知识</title><link>https://NamiChen.github.io/2018/migration-related-knowledge/</link><pubDate>Wed, 11 Apr 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/migration-related-knowledge/</guid><description>1. Linux 操作系统组成 Linux 操作系统由 Linux 内核、shell 命令解释器和应用程序3部分构成 1.1 shell Linux的内核不能直接接受来自终端的用户命令，shell 为</description></item><item><title>系统移植2-Debian系统的移植</title><link>https://NamiChen.github.io/2018/migration-of-debian-system/</link><pubDate>Wed, 11 Apr 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/migration-of-debian-system/</guid><description>Debian 系统的移植总分四部分：u-boot的编译与烧录，Linux内核的编译与烧录，Debian 基本根文件系统的制作、配置与烧录，开发板设置。 1. u</description></item><item><title>系统移植3-Android系统移植</title><link>https://NamiChen.github.io/2018/android-system-migration/</link><pubDate>Wed, 11 Apr 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/android-system-migration/</guid><description>采用Android6.0（棉花糖），编译环境为Ubuntu14.04和opoenjdk-7-jdk 1. 获取源码 首先参阅Android网站sou</description></item><item><title>系统移植4-内核配置</title><link>https://NamiChen.github.io/2018/linux-lernel-configuration/</link><pubDate>Wed, 11 Apr 2018 00:00:00 +0000</pubDate><guid>https://NamiChen.github.io/2018/linux-lernel-configuration/</guid><description>内核配置的目的主要是裁剪掉不必要的文件和目录，获得一个最适用的操作系统。可通过执行下面的命令进入配置窗口 1 $ make menuconfig 执行完毕后显示一个基于文本的</description></item></channel></rss>