Skip to content

Instantly share code, notes, and snippets.

View FantasyVR's full-sized avatar
🎯
Focusing

pengyu FantasyVR

🎯
Focusing
  • Taichi Graphics
  • Beijing
View GitHub Profile
@FantasyVR
FantasyVR / 毕设记录.md
Last active June 18, 2017 11:04
关于毕设,浏览记录

这是我去年北航计算机考研经验

不定时更新,配图有2015的不过都差不多

日程:

  • 每天:英语的学习放在平时,背单词,做阅读理解什么的
  • 开学到放假:数学书全部复习完,并做完课后习题
  • 暑假:看专业课和复习全书
  • 开学:重新开始复习全书,全面复习(政治9月份买买买)

#Hadoop安装过程

##Java Jdk的安装

  1. 根据Ubuntu下载对应的Jdk.看清Linux是64位还是32位
  2. 设置Jdk环境变量。
  sudo vi /etc/profile

在profile文件里添加如下代码设置环境变量

@FantasyVR
FantasyVR / FromeTwoVector.cc
Last active June 18, 2017 11:08
Two vectors A and B. how to get a quaternion representing the rotation from A to B?
Template typename<T>
struct quaternion{
T w,x,y,z;
};
struct _vec3{
T x,y,z;
};
typedef quaternion quat ;
typedef _vec3 vec3;

在描述命令行参数的时候, 对其格式有些约定俗成的写法, 各系统之间也有差别. 一般采用的格式如下:

命令 <必选参数1|必选参数2> [-option {必选参数1|必选参数2|必选参数3}] [可选参数...] {(默认参数)|参数|参数}

命令格式中常用的几个符号含义如下:

  1. 尖括号< >:必选参数, 实际使用时应将其替换为所需要的参数.
  2. 大括号{ }:必选参数, 内部使用, 包含此处允许使用的参数.
  3. 方括号[ ]:可选参数, 在命令中根据需要加以取舍.
  4. 小括号( ):指明参数的默认值, 只用于{ }中
@FantasyVR
FantasyVR / PositionBasedCosseratRods.cpp
Created June 26, 2017 03:04
This is the code fragment
bool PositionBasedCosseratRods::solve_StretchShearConstraint(
const glm::vec3& p0, float invMass0,
const glm::vec3& p1, float invMass1,
const glm::quat& q0, float invMassq0,
const glm::vec3& stretchingAndShearingKs,
const float restLength,
glm::vec3& corr0, glm::vec3& corr1, glm::quat& corrq0)
{
glm::vec3 d3; //third director d3 = q0 * e_3 * q0_conjugate
d3[0] = 2.0 * (q0.x * q0.z + q0.w * q0.y);
@FantasyVR
FantasyVR / CG_2017.md
Created July 6, 2017 08:55
The conference information of computer graphic in 2017
@FantasyVR
FantasyVR / zip.bat
Created October 27, 2017 08:38
Windows上批量压缩文件的脚本
```
@echo off
call :treeProcess
goto :eof
:treeProcess
rem Do whatever you want here over the files of this subdir, for example:
for %%f in (*.mp4) do echo %%f
for /D %%d in (*) do (
cd %%d
@FantasyVR
FantasyVR / XPBDRod.cpp
Last active September 24, 2020 03:24
This is the Pseudo code of Direct Position-Based Solver for Stiff Rods
// Eqations are in paper: Direct Position-Based Solver for Stiff Rods, Crispin Deul et.al. 2018
Real m_rodYoungModulus; //in Equation 5
Real m_rodRadius; //in Equation 6
Real m_rodInvZeroStretchStiffness;//in Equation 24: zero-stretch compliance \sigma^{-1}
Real m_rodDensity; //in Equation 28
Vector6r m_complianceVector; //Equation 24: Diagonal compliance matrix \alpha is representd as a 6x1 vector
Real timestep = 0.005;
void init()
{
m_rodYoungModulus = 1.0e3;

一个句子的成分

汉语和英语 每个句子都由下面这几个成分构成: 主语,谓语,宾语,定语,状语,补语。 英语里还多一个特殊的概念:表语

Be动词后面的名词就是表语

主谓宾

首先需要明白的是一句话的主干,就像一颗树的枝干:主语谓语宾语(主谓宾),比如 什么人干了什么事。

什么人就是主语
>“干”就是谓语