Ignore:
Timestamp:
Jul 9, 2018 8:58:51 AM (6 years ago)
Author:
Paul Kienzle <pkienzle@…>
Branches:
master, core_shell_microgels, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
Children:
502c7b8
Parents:
9f2216f
Message:

Update Yun's code to produce <F2> and P columns

File:
1 edited

Legend:

Unmodified
Added
Removed
  • explore/beta/testPolyDiseperseSphricalBeta.m

    r0076d6e rcdd676e  
    33 
    44R0=20;       %mean radius. unit: Angstroms 
    5 PDI=0.15;       %unit: relative polydispersity 
     5PDI=0.1;       %unit: relative polydispersity 
    66volF=0.1; 
    77contrast=6e-6;    %contrast,angstrom^-1, scattering length density difference 
    88 
    9 Filename='testPolydisperseGaussianSphere2.dat'; 
     9Filename='testPolydisperseGaussianSphere.dat'; 
    1010 
    1111Q=[0.001:0.001:0.8]; 
     
    5757NormIQN=IQN/IQN(1); 
    5858 
    59 FileString=strcat('Filename:',Filename, '**R0=', num2str(R0),'**PDI=', num2str(PDI),... 
    60     '**contrast',num2str(contrast), '**volF=',num2str(volF)); 
    61 Outputformat='File format : Q, <FQ>, <FQ>^2, <FQ^2>, betaQ, SQ, SQ_Eff'; 
    62  
    6359FQ2=beta.*IQ; 
    6460 
     
    7773 
    7874fileID=fopen(Filename,'w'); 
    79 fprintf(fileID,'%s\n\r', FileString); 
    80 fprintf(fileID,'%s\n\r', Outputformat); 
     75 
     76FileString=strcat('Filename:',Filename, '**R0=', num2str(R0),'**PDI=', num2str(PDI),... 
     77    '**contrast',num2str(contrast), '**volF=',num2str(volF)); 
     78Outputformat='File format : Q, <FQ>, <FQ^2>, PQ, betaQ, SQ, SQ_Eff'; 
     79fprintf(fileID,'%s\n', FileString); 
     80fprintf(fileID,'%s\n', Outputformat); 
    8181for i=1:length(Q) 
    82     %file format : Q, <FQ>, <FQ>^2, <FQ^2>, betaQ, SQ, SQ_Eff 
    83     fprintf(fileID,'%e\t%e\t%e\t%e\t%e\t%e\t%e\n\r',... 
    84         Q(i),FQ(i),FQ2(i),IQ(i),beta(i),Sq(i),Sq_eff(i)); 
     82    %file format : Q, <FQ>, <FQ^2>, PQ, betaQ, SQ, SQ_Eff 
     83    fprintf(fileID,'%e\t%e\t%e\t%e\t%e\t%e\t%e\n',... 
     84        Q(i),FQ(i),IQN(i),IQ(i),beta(i),Sq(i),Sq_eff(i)); 
    8585end 
    8686 
Note: See TracChangeset for help on using the changeset viewer.