24小时热门版块排行榜    

Znn3bq.jpeg
查看: 349  |  回复: 0

浪漫的枯

新虫 (初入文坛)

[求助] 关于MATLAB编程的小问题,求解答

前段时间刚开学,老师让我简单编写个小程序,可是我MATLAB实在是有够烂的,搞不出来,急死了,希望有大神随便动下鼠标帮我一下。
      下面是老师给我的小作业指示:
The file (P02560.7) is the raw data acquired on a 3T scanner, with single-slice. It has a header of 61464 at the front. After the header, it contains the k-space data of a 256x256 single image. The raw data is in complex short integer.
1) Please read the P02560.7 file using fopen, fseek, fread, fclose functions in MATLAB. Using imshow and abs function to show the k-space data.
2)You can use reshape, zeros and ifft2, ifftshift functions to reconstruct the brain image.Using imshow ,abs and angle functions to show the magnitude and phase of the reconstructed image.
3) Please use help documents to find the details of these functions.

这个P02560.7是个K空间数据文件,我没有上传,只想知道该怎么编写代码,有好多指令都不熟,下面是一个师兄帮我随便写的,,虽然图像出来了,好像还是不太对,求万能的jrs搭救:fid=fopen('P02560.7','r+');
status=fseek(fid,61465,'bof');
A=fread(fid,[256,256],'int16');
A=double(A);
K=A/(max(max((abs(A)))));
figure,imshow(abs(K),[]);
data = 1/sqrt(length(K())*ifftshift(ifft2(fftshift(K)));
figure,imshow(abs(data),[]);
IG=ifftshift(fft2(ifftshift(data)));
figure,imshow(abs(IG),[]);


顺便问下,加下划线的这3句为什么这样用?
ps:http://pan.baidu.com/s/1mg5LxVi,,这是P02560.7 文件的链接。
回复此楼

» 猜你喜欢

情场浪子女见愁
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

智能机器人

Robot (super robot)

我们都爱小木虫

找到一些相关的精华帖子,希望有用哦~

科研从小木虫开始,人人为我,我为人人
相关版块跳转 我要订阅楼主 浪漫的枯 的主题更新
最具人气热帖推荐 [查看全部] 作者 回/看 最后发表
[考研] 0854求调剂 +13 门路摸摸 2026-04-15 14/700 2026-04-16 06:51 by fenglj492
[考研] 一志愿A区211,22408 321求调剂 +6 随心所欲☆ 2026-04-15 7/350 2026-04-15 21:45 by lbsjt
[考研] 22408 312求调剂 +20 门路摸摸 2026-04-14 21/1050 2026-04-15 20:39 by cuisz
[考研] 材料299专硕求调剂 +17 +21 2026-04-09 17/850 2026-04-15 17:20 by zs92450
[考研] 297,工科调剂?河南农业大学本科 +11 河南农业大学-能 2026-04-14 11/550 2026-04-15 15:03 by 学员JpLReM
[考研] 310求调剂 +16 666真好 2026-04-11 18/900 2026-04-15 13:28 by 黑科技矿业
[考研] 305求调剂 +8 玛卡巴卡boom 2026-04-11 8/400 2026-04-14 09:04 by pengliang8036
[考研] 085404 298分求调剂 +11 呼啦呼啦呼呼呼 2026-04-10 12/600 2026-04-14 08:38 by wfj257
[考研] 考研求调剂 +12 子木呐 2026-04-12 13/650 2026-04-14 01:19 by 王珺璞
[考研] 一志愿华南理工大学331分材料求调剂 +10 天下ww 2026-04-09 11/550 2026-04-13 23:25 by pies112
[考研] 332求调剂 +15 蕉蕉123 2026-04-10 15/750 2026-04-13 23:12 by pies112
[考研] 297工科,求调剂? +13 河南农业大学-能 2026-04-12 13/650 2026-04-13 14:12 by dingyanbo1
[考研] 344 材料专业 求调剂211 无地域要求 +8 hualkop 2026-04-11 8/400 2026-04-12 22:24 by fqwang
[教师之家] 山东双非院校考核超级无底线,领导幸灾乐祸,教师遭殃恐 +3 qut2026 2026-04-11 7/350 2026-04-12 20:24 by qut2026
[考研] 中药学调剂 初试324 +4 洋甘菊、 2026-04-10 6/300 2026-04-11 09:41 by gong120082
[考研] 一志愿东北大学控制工程085406数二英二385,求调剂 +8 Ezra_Zhang 2026-04-09 8/400 2026-04-11 09:15 by 猪会飞
[考研] 22408 366分,本科211,一志愿西工大 +4 Rubt 2026-04-09 4/200 2026-04-10 19:51 by chemisry
[考研] 本9 一志愿西工大085601 324求调剂 +5 wysyjs25 2026-04-10 5/250 2026-04-10 16:57 by luoyongfeng
[考研] 344求调剂 +7 丶风雪夜归人丶 2026-04-09 7/350 2026-04-10 12:05 by pengliang8036
[考研] 材料专硕初试分332一志愿西北工业大学, +12 故人?? 2026-04-09 12/600 2026-04-09 18:34 by Ccclqqq
信息提示
请填处理意见