function [ x, w ] = rule10 ( n )

%*****************************************************************************80
%
%% RULE10 returns the rule of degree 10.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    09 July 2014
%
%  Author:
%
%    Original FORTRAN77 version by Hong Xiao, Zydrunas Gimbutas.
%    This MATLAB version by John Burkardt.
%
%  Reference:
%
%    Hong Xiao, Zydrunas Gimbutas,
%    A numerical algorithm for the construction of efficient quadrature
%    rules in two and higher dimensions,
%    Computers and Mathematics with Applications,
%    Volume 59, 2010, pages 663-676.
%
%  Parameters:
%
%    Input, integer N, the number of nodes.
%
%    Output, real X(3,N), the coordinates of the nodes.
%
%    Output, real W(N), the weights.
%
  xs = [ ...
    0.4135441926108436,0.6920344574148628E-02, ...
    -.4204645371849727,0.1212827019050737, ...
    0.2550746585402268,-.3763573604446380, ...
    -.4793578815415788E-03,-.9545817212686222E-01, ...
    0.9593753000785579E-01,0.3126301401176562, ...
    -.6029042538437952,0.2902741137267026, ...
    0.1793124962974703,-.3341633308670676, ...
    0.1548508345696874,0.4006666604011494, ...
    -.3875674230187136,-.1309923738259358E-01, ...
    -.1159749898125322,-.6294076737424348, ...
    0.7453826635553922,-.1465165887848432, ...
    -.4643141868299223,0.6108307756147643, ...
    0.1526773226986329,-.6092465369941313, ...
    0.4565692142952937,-.2349836288652037, ...
    0.5557206177695652,-.3207369889038079, ...
    0.2617190792164227,-.2353754650695125, ...
    -.2634361414712093E-01,-.1518707842414898, ...
    -.2491539125596758,0.4010246968008866, ...
    0.2108318943729519,0.7968056612120857E-02, ...
    -.2187999509850842,-.6451845341149960, ...
    0.5779406907458116,0.6724384336957467E-01, ...
    -.1117027003111241,-.2717471055583957, ...
    0.3834498058697393,0.2353864631064914, ...
    0.1649339445101810,-.4003204076167762, ...
    0.7813866474350551,0.1310349087707534E-02, ...
    -.7826969965232643,-.1446486485942199, ...
    -.1795841794748884E-02,0.1464444903888344, ...
    0.5662897411515679,0.1839447497576211E-02, ...
    -.5681291886496517,0.1959958820407995E-02, ...
    -.3041697942355038,0.3022098354145521, ...
    -.7138061627291874E-01,-.3075192230121023, ...
    0.3788998392856530,-.3187848524903898E-01, ...
    -.9081742825948123,0.9400527678433584, ...
    0.9976676831438748E-01,-.8701982408315725, ...
    0.7704314725177221,-.8207757778140335D-14, ...
    -.3478417597234231D-12,0.4790952016774938D-12, ...
    0.1374787712765062D-12,0.1420358457394610D-12 ];
  ys = [ ...
    -.2467507765313092,0.4815151646539115, ...
    -.2347643881227681,-.3645574461360758, ...
    0.2873126239566789,0.7724482217897545E-01, ...
    0.1105023601492690,-.5566631617759855E-01, ...
    -.5483604397160680E-01,0.5156767709512212, ...
    0.1290725785546668E-01,-.5285840288063388, ...
    0.2823324600522004,0.1412294698335291E-01, ...
    -.2964554070359728,0.2161993077800489, ...
    0.2388878524669672,-.4550871602470489, ...
    0.7937355713187059,-.4973050730407310, ...
    -.2964304982776649,0.6207352334853357, ...
    -.4372547047061620,-.1834805287791172, ...
    0.6153490109135903,-.1754520654179484, ...
    -.4398969454955785,-.5060230351463111, ...
    0.4950972550220373E-01,0.4565133096445042, ...
    0.1206845953990400,0.1663130735568127, ...
    -.2869976689562073,0.3753807951356096, ...
    -.3192143548135662,-.5616644032198326E-01, ...
    -.1309245702301312,0.2480480615696827, ...
    -.1171234913398124,-.2948509623067830, ...
    -.4113207155193597,0.7061716778256595, ...
    0.3782781131850991,-.2858764327334718, ...
    -.9240168045211911E-01,-.3263497523611192, ...
    0.3670255329377183,-.4067578057659137E-01, ...
    -.4526468520348789,0.9030241128745099, ...
    -.4503772608395989,0.8558659569093126E-01, ...
    -.1680627021511816,0.8247610646027727E-01, ...
    -.3290715455089481,0.6549570744945620, ...
    -.3258855289855604,0.3500934424096372, ...
    -.1733493470760727,-.1767440953334651, ...
    0.3963042303943790,-.2599695422276034, ...
    -.1363346881672204,0.1067074385094486D+01, ...
    -.5611447706066169,-.5059296144870963, ...
    0.9472180066426262,-.3872084475068061, ...
    -.5600095591352807,-.1466739111569232D-12, ...
    0.2419854376387837D-13,-.1552488340937713D-12, ...
    -.2306323605219641D-12,-.1706174368865759D-12 ];
  zs = [ ...
    -.2246678712539802E-01,-.2246678712556187E-01, ...
    -.2246678712549978E-01,-.3674985430672734, ...
    -.3674985430672704,-.3674985430673924, ...
    0.9168884763080956,0.9168884763077307, ...
    0.9168884763085783,-.3553336558198409, ...
    -.3553336558198190,-.3553336558198354, ...
    -.1983165808272536,-.1983165808275630, ...
    -.1983165808272446,-.1447858405450569, ...
    -.1447858405451866,-.1447858405451966, ...
    -.3542393281108072,-.3542393281107521, ...
    -.3542393281107588,-.1251511927365907, ...
    -.1251511927364737,-.1251511927364298, ...
    -.1387177797398434,-.1387177797398834, ...
    -.1387177797396668,-.3549137865746493, ...
    -.3549137865746083,-.3549137865746373, ...
    0.8659130596210637E-01,0.8659130596171444E-01, ...
    0.8659130596207916E-01,0.2597687530320102, ...
    0.2597687530321350,0.2597687530322305, ...
    0.2630632081142404,0.2630632081143893, ...
    0.2630632081144756,-.3453833089184027, ...
    -.3453833089183551,-.3453833089183527, ...
    -.2327889534298980,-.2327889534297419, ...
    -.2327889534296802,0.2415268120578684, ...
    0.2415268120576211,0.2415268120576665, ...
    -.2133068003220094,-.2133068003224423, ...
    -.2133068003227821,0.6055816506735499, ...
    0.6055816506736809,0.6055816506737702, ...
    0.1414131684170811,0.1414131684165572, ...
    0.1414131684162387,0.5593538346997974, ...
    0.5593538346994973,0.5593538347003276, ...
    -.3961007879024273,-.3961007879023746, ...
    -.3961007879023505,-.3950741090480416, ...
    -.3950741090482457,-.3950741090476022, ...
    -.3779492208572051,-.3779492208572193, ...
    -.3779492208571862,-.3464548867786856E-01, ...
    0.1201009856985286D+01,0.4068123865912653, ...
    -.3341407786078385,0.5699475205900819 ];
  ws = [ ...
    0.2007080596188233E-01,0.2007080596192337E-01, ...
    0.2007080596192014E-01,0.1202850982705908E-01, ...
    0.1202850982706234E-01,0.1202850982703673E-01, ...
    0.6428246923028596E-02,0.6428246923032827E-02, ...
    0.6428246923025550E-02,0.5961017737373873E-02, ...
    0.5961017737376429E-02,0.5961017737354793E-02, ...
    0.2466985253776778E-01,0.2466985253776116E-01, ...
    0.2466985253775616E-01,0.1220343371669821E-01, ...
    0.1220343371668563E-01,0.1220343371666686E-01, ...
    0.6782282187245643E-02,0.6782282187250343E-02, ...
    0.6782282187251558E-02,0.1276699476009991E-01, ...
    0.1276699476009263E-01,0.1276699476009060E-01, ...
    0.1330898468041284E-01,0.1330898468040929E-01, ...
    0.1330898468040468E-01,0.8872828138103311E-02, ...
    0.8872828138107657E-02,0.8872828138112581E-02, ...
    0.2604852195750169E-01,0.2604852195750782E-01, ...
    0.2604852195751094E-01,0.1091598279364878E-01, ...
    0.1091598279363667E-01,0.1091598279364397E-01, ...
    0.2727741583607240E-01,0.2727741583609616E-01, ...
    0.2727741583610115E-01,0.1214067234472188E-01, ...
    0.1214067234470734E-01,0.1214067234471387E-01, ...
    0.2653047387010774E-01,0.2653047387011107E-01, ...
    0.2653047387012045E-01,0.1147407678956960E-01, ...
    0.1147407678960903E-01,0.1147407678957783E-01, ...
    0.6941339438094368E-02,0.6941339438087489E-02, ...
    0.6941339438089641E-02,0.1618088676127407E-01, ...
    0.1618088676125095E-01,0.1618088676125473E-01, ...
    0.9879744049167588E-02,0.9879744049174469E-02, ...
    0.9879744049169482E-02,0.1106165676903961E-01, ...
    0.1106165676903509E-01,0.1106165676904102E-01, ...
    0.7973762810133187E-02,0.7973762810143904E-02, ...
    0.7973762810145713E-02,0.7671732380845806E-03, ...
    0.7671732380905287E-03,0.7671732380951896E-03, ...
    0.1643453575966134E-02,0.1643453575957693E-02, ...
    0.1643453575955291E-02,0.4522697832344839E-01, ...
    0.3708344580879497E-03,0.1141401437229523E-01, ...
    0.2710167289616961E-01,0.1108569325544364E-01 ];

  x(1,1:n) = xs(1:n);
  x(2,1:n) = ys(1:n);
  x(3,1:n) = zs(1:n);
  w(1:n) = ws(1:n);

  return
end
