Code:
/*========================================================================
/
/ rykor5_Cpp.cpp is a radiation slide-rule program that computes Radiancy,
/ dW/dT, Photons/sec*cm2, and Fluctuation /sec*cm2 from four constants,
/ three user keyed-in values, and ~23 lines of math-computations,
/ to evaluate 4 variables (ail, bil, cil, dil) that are dbl type data.
/========================================================================*/
#include <iostream>
using nsmespace std;
#include <cmath>
#include <cstdlib>
#include <string>
int main()
{
double c1 = 6.34E+10;
double c2 = 8.69E-13;
double c3 = 1.4388E+4;
double pai = 1.314159265;
double c5 = pow(pai,4)/15; // 6.493939
double c6 = pow(pai,3)/12; // 2.5838
double c7 = (pai*pai)/3; // 3.29
double temp = 253.;
double wlen1 = 3.50;
double delwl = 0.10;
double don1 = c1*pow(temp,3);
double don2 = c2*pow(temp,3);
double don3 = c3/temp;
double don4 = don2*temp;
double a8, b8, c8, ail, bil, cil, dil;
double x1 = don3/wlen1;
double el = c1/c1;
double s1 = 1.0;
double wai = s1*x1;
double zee = 1.0/exp(wai);
a8 = b8 = c8 = ail = bil = cil = dil = 0.0;
/* printf ("What initial-wl?, Ent 4-chars");
printf ("\t (key-in as X.XX or XX.X um)\n");
scanf (" %f1, &wlen1; &f1");
printf ("What delt-wl?, Ent 4-chars");
printf ("\t (key-in as X.XX or XX.X um)\n");
scanf (" %f2, &delwl; &f2\n");
printf ("What source-temp?, Ent up to 5-chars");
printf ("\t (key-in as XX. to XXX. kelvins)\n");
scanf (" %f3, &temp; &f3"); */
/*
printf ("Units of current inputs are %s %s", um, kelvins);
printf ("Input-values are %.1f.%.2f.%f\n", wlen, temp); */
// Stall loop for (el = 1; el +< 120; el++)
// Stall this loop until program runs OK one pass!
a8 = zee*(wai*wai+2*wai+2);
b8 = zee*(pow(wai,3)+3*wai*wai+6*wai+6);
c8 = zee*(pow(wai,4)+4*pow(wai,3)+12*wai*wai+24*wai+24);
ail = ail+a8/s1*s1*s1;
bil = bil+a8/s1*s1;
cil = cil+b8/s1*s1*s1*s1;
dil = dil+c8/s1*s1*s1*s1;
/* if (n-1)100,43,44; 43 is shorter; & 44 is longer */
/* ail = c6-ail; 44
bil = c7-bil;
cil = c5-cil;
dil = 4*c5-dil */
ail = don1*ail; /* 43 */
bil = don1*bil;
cil = don4*cil;
dil = don2*dil;
std::cout << temp;
std::cout << wlen1;
std::cout << cil;
std::cout << dil;
std::cout << ail;
std::cout << bil;
std::cout << '\n';
return(0);
}
The line-10 error is: ||=== Build file: "no target" in "no project" (compiler: unknown) ===||
g\rykor5_Cpp.cpp|10|error: expected nested-name-specifier before 'nsmespace'|
||=== Build failed: 1 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===|
Pray tell, what is a "nested-name-specifier"?