spherocylinder

This function draws a spherocylinder/capsule for a given orientation.
ダウンロード: 77
更新 2018/4/13

ライセンスの表示

This script draws spherocylinder/capsule of any aspect ratio for a given centre coordinate and orientation. The input parameters are:
pos - Centre of the spherocylinder
vec - Orientation vector
totalLength - Total length of the spherocylinder including the hemispherical ends.
AR - Aspect ratio of the spherocylinder. AR=1 implies a sphere.

Since the code is developed for a multi-spherocylinder system, lighting effects are not included in the code. Include the following commands for the lighting (or after the "end" of the "for loop" for a multiparticle system):

set(gca,'CameraPosition',[1 1 1]);
box on;
daspect([1,1,1]);
camlight('left');

引用

Sathish Sanjeevi (2026). spherocylinder (https://jp.mathworks.com/matlabcentral/fileexchange/66904-spherocylinder), MATLAB Central File Exchange. 取得日: .

MATLAB リリースの互換性
作成: R2016b
すべてのリリースと互換性あり
プラットフォームの互換性
Windows macOS Linux
カテゴリ
Help Center および MATLAB AnswersLighting, Transparency, and Shading についてさらに検索
タグ タグを追加
バージョン 公開済み リリース ノート
1.0.0.0

headline.
comments

Formatting.
Formatting