Skip to content
Snippets Groups Projects
Commit a29f8ac3 authored by Wouter Deconinck's avatar Wouter Deconinck
Browse files

tan -> sin

parent 412c5a12
No related branches found
No related tags found
1 merge request!99Material scans: allow for cylindrical instead of spherical scans
This commit is part of merge request !99. Comments created here will be created in the context of that merge request.
...@@ -65,7 +65,7 @@ void materialScan( ...@@ -65,7 +65,7 @@ void materialScan(
double rho = min(rmax * cos(theta), rhomax); double rho = min(rmax * cos(theta), rhomax);
double x = rho * cos(phi); double x = rho * cos(phi);
double y = rho * sin(phi); double y = rho * sin(phi);
double z = (eta > 0? min(zpmax, rho * tan(theta)): max(-znmax, rho * tan(theta))); double z = (eta > 0? min(zpmax, rho * sin(theta)): max(-znmax, rho * sin(theta)));
std::cout << eta << ": " << x << ", " << y << ", " << z << std::endl; std::cout << eta << ": " << x << ", " << y << ", " << z << std::endl;
scan.emplace_back(gMaterialScan->scan(x0,y0,z0,x,y,z)); scan.emplace_back(gMaterialScan->scan(x0,y0,z0,x,y,z));
total += scan.back().size(); total += scan.back().size();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment