|
|
|
@ -53,12 +53,12 @@ structure_fp32_t* make_structures(const unsigned int amount)
|
|
|
|
|
|
|
|
|
|
|
|
void print_versor_fp32(const BgcVersorFP32* versor)
|
|
|
|
void print_versor_fp32(const BgcVersorFP32* versor)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
printf("Versor (%f, %f, %f, %f)\n", versor->s0, versor->x1, versor->x2, versor->x3);
|
|
|
|
printf("Versor (s0 = %0.12f, x1 = %0.12f, x2 = %0.12f, x3 = %0.12f)\n", versor->s0, versor->x1, versor->x2, versor->x3);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void print_versor_fp64(const BgcVersorFP64* versor)
|
|
|
|
void print_versor_fp64(const BgcVersorFP64* versor)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
printf("Versor (%lf, %lf, %lf, %lf)\n", versor->s0, versor->x1, versor->x2, versor->x3);
|
|
|
|
printf("Versor (s0 = %0.20f, x1 = %0.20f, x2 = %0.20f, x3 = %0.20f)\n", versor->s0, versor->x1, versor->x2, versor->x3);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void print_vector_fp32(const BgcVector3FP32* vector)
|
|
|
|
void print_vector_fp32(const BgcVector3FP32* vector)
|
|
|
|
@ -79,7 +79,7 @@ void list_work(const uint_fast32_t amount, structure_fp32_t* list)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/*
|
|
|
|
int main()
|
|
|
|
int main()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
const unsigned int amount = 1000000;
|
|
|
|
const unsigned int amount = 1000000;
|
|
|
|
@ -121,3 +121,369 @@ int main()
|
|
|
|
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
|
|
|
int main() {
|
|
|
|
|
|
|
|
BgcComplexFP32 complex, exponent, result;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
bgc_complex_set_values_fp32(0, 1, &complex);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
bgc_complex_set_values_fp32(4, 0, &exponent);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
bgc_complex_get_exponation_fp32(&complex, exponent.real, exponent.imaginary, &result);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
printf("(%f, %f) ^ (%f, %f) = (%f, %f)\n", complex.real, complex.imaginary, exponent.real, exponent.imaginary, result.real, result.imaginary);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
|
|
|
int main() {
|
|
|
|
|
|
|
|
BgcVersorFP32 start = { 1.0f, 0.0f, 0.0f, 0.0f };
|
|
|
|
|
|
|
|
BgcVersorFP32 end = { 0.0f, 1.0f, 0.0f, 0.0f };
|
|
|
|
|
|
|
|
BgcVersorFP32 result;
|
|
|
|
|
|
|
|
bgc_versor_spherical_interpolation_fp32(&start, &end, 0.5f, &result);
|
|
|
|
|
|
|
|
printf("Result: %0.12f, %0.12f, %0.12f, %0.12f\n", result.s0, result.x1, result.x2, result.x3);
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void test_basis_difference_fp32()
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
BgcVector3FP32 initial_primary, initial_auxiliary;
|
|
|
|
|
|
|
|
BgcVector3FP32 final_primary, final_auxiliary;
|
|
|
|
|
|
|
|
BgcVersorFP32 turn;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// No turn
|
|
|
|
|
|
|
|
bgc_vector3_set_values_fp32(1.0f, 0.0f, 0.0f, &initial_primary);
|
Internal server error - Personal Git Server: Beyond coding. We Forge.
500
Internal server error
Forgejo version: 11.0.1+gitea-1.22.0